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”).

A194545
Total sum of nonprime parts in all partitions of n.
5
0, 1, 2, 4, 11, 16, 33, 48, 89, 134, 214, 305, 478, 663, 976, 1356, 1934, 2617, 3654, 4877, 6652, 8808, 11772, 15386, 20329, 26308, 34249, 43987, 56651, 72079, 92008, 116171, 146967, 184381, 231399, 288398, 359581, 445426, 551721, 679868, 837238, 1026256
OFFSET
0,3
LINKS
FORMULA
a(n) = A066186(n) - A073118(n).
EXAMPLE
For n = 6 we have:
--------------------------------------
. Sum of
Partitions nonprime parts
--------------------------------------
6 .......................... 6
3 + 3 ...................... 0
4 + 2 ...................... 4
2 + 2 + 2 .................. 0
5 + 1 ...................... 1
3 + 2 + 1 .................. 1
4 + 1 + 1 .................. 6
2 + 2 + 1 + 1 .............. 2
3 + 1 + 1 + 1 .............. 3
2 + 1 + 1 + 1 + 1 .......... 4
1 + 1 + 1 + 1 + 1 + 1 ...... 6
--------------------------------------
Total ..................... 33
So a(6) = 33.
MAPLE
b:= proc(n, i) option remember; local h, j, t;
if n<0 then [0, 0]
elif n=0 then [1, 0]
elif i<1 then [0, 0]
else h:= [0, 0];
for j from 0 to iquo(n, i) do
t:= b(n-i*j, i-1);
h:= [h[1]+t[1], h[2]+t[2]+`if`(isprime(i), 0, t[1]*i*j)]
od; h
fi
end:
a:= n-> b(n, n)[2]:
seq(a(n), n=0..50); # Alois P. Heinz, Nov 20 2011
MATHEMATICA
b[n_, i_] := b[n, i] = Module[{h, j, t}, Which[n<0, {0, 0}, n==0, {1, 0}, i < 1, {0, 0}, True, h = {0, 0}; For[j = 0, j <= Quotient[n, i], j++, t = b[n-i*j, i-1]; h = {h[[1]] + t[[1]], h[[2]] + t[[2]] + If[PrimeQ[i], 0, t[[1]]*i*j]}]; h]]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Nov 03 2015, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Omar E. Pol, Nov 20 2011
EXTENSIONS
More terms from Alois P. Heinz, Nov 20 2011
STATUS
approved