The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A294113 Sum of the smaller parts of the partitions of 2n into two parts with larger part prime. 2
 0, 3, 4, 4, 8, 6, 11, 8, 13, 20, 28, 24, 32, 25, 32, 41, 51, 42, 51, 40, 49, 60, 72, 60, 72, 84, 97, 111, 125, 109, 124, 107, 121, 136, 152, 169, 188, 169, 187, 206, 226, 204, 224, 199, 218, 238, 258, 229, 248, 268, 289, 312, 336, 306, 331, 357, 384, 412 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 LINKS Robert Israel, Table of n, a(n) for n = 1..10000 Index entries for sequences related to partitions FORMULA a(n) = Sum_{i=1..n} i * A010051(2n-i). a(n) = 2*n*(A000720(2*n)-A000720(n-1)) - A034387(2*n) + A034387(n-1) for n >= 2. - Robert Israel, Mar 13 2018 EXAMPLE For n=7, 2n = 14 can be partitioned into two parts with the larger part prime as 13 + 1, 11 + 3, and 7 + 7. So a(7) = 1 + 3 + 7 = 11. - Michael B. Porter, Mar 14 2018 MAPLE N:= 1000: # to get a(1)..a(n) P:= select(isprime, [2, seq(i, i=3..2*N, 2)]): S:= ListTools:-PartialSums(P): f:= proc(n) local k1, k2; k1:= numtheory:-pi(2*n); k2:= numtheory:-pi(n-1); 2*n*(k1-k2) - S[k1] + S[k2] end proc: f(1):= 0: seq(f(n), n=1..N); # Robert Israel, Mar 13 2018 MATHEMATICA Table[Sum[i (PrimePi[2 n - i] - PrimePi[2 n - i - 1]), {i, n}], {n, 80}] PROG (PARI) a(n) = sum(k=1, n, k*isprime(2*n-k)); \\ Michel Marcus, Oct 24 2017 (PARI) a(n) = my(res = 0); forprime(p = n, 2*n, res+=(2*n - p)); res \\ David A. Corneth, Oct 24 2017 CROSSREFS Cf. A000720, A010051, A034387, A294114. Sequence in context: A021033 A269714 A146944 * A339827 A240875 A127735 Adjacent sequences: A294110 A294111 A294112 * A294114 A294115 A294116 KEYWORD nonn,easy AUTHOR Wesley Ivan Hurt, Oct 22 2017 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified August 9 05:47 EDT 2024. Contains 375027 sequences. (Running on oeis4.)