cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A294023 Sum of the differences of the larger and smaller parts in the partitions of n into two parts with the smaller part prime.

This page as a plain text file.
%I A294023 #32 Nov 25 2019 02:57:22
%S A294023 0,0,0,0,1,2,4,6,8,10,13,16,19,22,26,30,34,38,42,46,50,54,59,64,69,74,
%T A294023 80,86,92,98,104,110,116,122,129,136,143,150,158,166,174,182,190,198,
%U A294023 206,214,223,232,241,250,259,268,277,286,295,304,313,322,332
%N A294023 Sum of the differences of the larger and smaller parts in the partitions of n into two parts with the smaller part prime.
%C A294023 Sum of the slopes of the tangent lines along the left side of the parabola b(x) = n*x-x^2 at prime values of x for x in 0 < x <= floor(n/2). For example, d/dx n*x-x^2 = n-2x. So for a(11), x=2,3,5 and so 11-2*2 + 11-2*3 + 11-2*5 = 7 + 5 + 1 = 13. - _Wesley Ivan Hurt_, Mar 24 2018
%H A294023 <a href="/index/Par#part">Index entries for sequences related to partitions</a>
%F A294023 a(n) = Sum_{i=1..floor(n/2)} (n - 2i)*A010051(i).
%F A294023 First differences are A056172. - _David A. Corneth_, Apr 06 2018
%F A294023 a(n) = Sum_{i=1..n-1} pi(floor(i/2)), where pi(n) = A000720(n). - _Ridouane Oudra_, Nov 24 2019
%e A294023 The partitions of n = 11 into a number and a smaller prime number are 9 + 2, 8 + 3, and 6 + 5, so a(11) = (9 - 2) + (8 - 3) + (6 - 5) = 13. - _Michael B. Porter_, Apr 06 2018
%p A294023 with(numtheory): seq(add(pi(floor(i/2)), i=1..n-1), n=1..100); # _Ridouane Oudra_, Nov 24 2019
%t A294023 Table[Sum[(n - 2 i) (PrimePi[i] - PrimePi[i - 1]), {i, Floor[n/2]}], {n, 60}]
%o A294023 (PARI) a(n) = sum(i=1, n\2, (n - 2*i)*isprime(i)); \\ _Michel Marcus_, Mar 24 2018
%o A294023 (PARI) a(n) = my(res = 0); forprime(p = 2, n >> 1, res += (n - p << 1)); res \\ _David A. Corneth_, Apr 06 2018
%Y A294023 Cf. A010051, A056172, A294022, A000720.
%K A294023 nonn,easy
%O A294023 1,6
%A A294023 _Wesley Ivan Hurt_, Oct 21 2017