# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a303665 Showing 1-1 of 1 %I A303665 #6 Apr 28 2018 17:13:59 %S A303665 1,1,2,3,4,7,9,15,21,31,47,67,102,148,220,325,477,709,1041,1542,2274, %T A303665 3355,4959,7311,10804,15940,23535,34747,51281,75723,111762,165005, %U A303665 243578,359567,530831,783585,1156799,1707662,2520913,3721467,5493674,8110012,11972133,17673686 %N A303665 Expansion of 1/((1 - x)*(1 - Sum_{k>=1} x^prime(k))). %C A303665 Partial sums of A023360. %H A303665 Index entries for sequences related to compositions %p A303665 b:= proc(n) option remember; `if`(n=0, 1, %p A303665 add(`if`(isprime(j), b(n-j), 0), j=2..n)) %p A303665 end: %p A303665 a:= proc(n) option remember; %p A303665 `if`(n<0, 0, b(n)+a(n-1)) %p A303665 end: %p A303665 seq(a(n), n=0..50); # _Alois P. Heinz_, Apr 28 2018 %t A303665 nmax = 43; CoefficientList[Series[1/((1 - x) (1 - Sum[x^Prime[k], {k, 1, nmax}])), {x, 0, nmax}], x] %t A303665 a[0] = 1; a[n_] := a[n] = Sum[Boole[PrimeQ[k]] a[n - k], {k, 1, n}]; Accumulate[Table[a[n], {n, 0, 43}]] %Y A303665 Cf. A000040, A010051, A023360, A034891. %K A303665 nonn %O A303665 0,3 %A A303665 _Ilya Gutkovskiy_, Apr 28 2018 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE