login
Expansion of Sum_{p prime, k>=1} x^(p^k)*(1 - x)^2/(1 - 2*x)^2.
2

%I #15 Aug 07 2019 17:17:49

%S 0,1,3,8,20,47,110,251,564,1251,2750,5994,12978,27934,59825,127565,

%T 270959,573575,1210466,2547562,5348385,11203292,23419629,48865346,

%U 101782870,211670094,439548898,911515214,1887865266,3905400206,8070139762,16658958223,34355273843

%N Expansion of Sum_{p prime, k>=1} x^(p^k)*(1 - x)^2/(1 - 2*x)^2.

%C Total number of prime power parts (1 excluded) in all compositions (ordered partitions) of n.

%H Alois P. Heinz, <a href="/A284943/b284943.txt">Table of n, a(n) for n = 1..3313</a>

%H <a href="/index/Com#comp">Index entries for sequences related to compositions</a>

%F G.f.: Sum_{p prime, k>=1} x^(p^k)*(1 - x)^2/(1 - 2*x)^2.

%e a(5) = 20 because we have [5], [4, 1], [3, 2], [3, 1, 1], [2, 3], [2, 2, 1], [2, 1, 2], [2, 1, 1, 1], [1, 4], [1, 3, 1], [1, 2, 2], [1, 2, 1, 1], [1, 1, 3], [1, 1, 2, 1], [1, 1, 1, 2], [1, 1, 1, 1, 1] and 1 + 1 + 2 + 1 + 2 + 2 + 2 + 1 + 1 + 1 + 2 + 1 + 1 + 1 + 1 + 0 = 20.

%p b:= proc(n) option remember; nops(ifactors(n)[2])=1 end:

%p a:= proc(n) option remember; `if`(n=0, 0, add(a(n-j)+

%p `if`(b(j), ceil(2^(n-j-1)), 0), j=1..n))

%p end:

%p seq(a(n), n=1..33); # _Alois P. Heinz_, Aug 07 2019

%t nmax = 33; Rest[CoefficientList[Series[Sum[Floor[1/PrimeNu[k]] x^k (1 - x)^2/(1 - 2 x)^2, {k, 2, nmax}], {x, 0, nmax}], x]]

%o (PARI) x='x+O('x^34); concat([0], Vec(sum(k=2, 34, (1\omega(k))*x^k*(1 - x)^2/(1 - 2*x)^2))) \\ _Indranil Ghosh_, Apr 06 2017

%Y Cf. A011782, A059570, A073335, A097941, A097979, A102291, A246655, A284942.

%K nonn

%O 1,3

%A _Ilya Gutkovskiy_, Apr 06 2017