login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Number of partitions of n into 3 parts with at least 1 prime part.
0

%I #11 Nov 10 2021 16:59:25

%S 0,0,0,0,1,2,2,4,4,6,7,8,10,12,13,17,17,19,22,25,26,31,31,36,37,42,43,

%T 49,49,56,56,64,63,72,70,80,79,87,87,99,94,107,105,116,114,126,123,

%U 139,134,148,145,158,155,173,166,184,178,195,189,211,202,222,215,236,226,250,242

%N Number of partitions of n into 3 parts with at least 1 prime part.

%H <a href="/index/Par#part">Index entries for sequences related to partitions</a>

%F a(n) = Sum_{j=1..floor(n/3)} Sum_{i=j..floor((n-j)/2)} sign(c(i) + c(j) + c(n-i-j)), where c is the prime characteristic (A010051).

%p b:= proc(n, i, t) option remember; series(

%p `if`(n=0, t, `if`(i<1, 0, expand(x*b(n-i, min(n-i, i),

%p `if`(isprime(i), 1, t)))+b(n, i-1, t))), x, 4)

%p end:

%p a:= n-> coeff(b(n$2, 0), x, 3):

%p seq(a(n), n=0..66); # _Alois P. Heinz_, Oct 24 2021

%t Table[Length@Select[IntegerPartitions[k,{3}],Or@@PrimeQ@#&],{k,0,66}] (* _Giorgos Kalogeropoulos_, Oct 24 2021 *)

%Y Cf. A010051, A068307, A235945, A340572.

%K nonn

%O 0,6

%A _Wesley Ivan Hurt_, Oct 24 2021