OFFSET
1,2
FORMULA
G.f.: x*(1+x^2)/((1-x)*(1-x^2)*Product_{m>0} (1-x^m)). Euler transform of 2,3,1,0,1,1,1,1,1,... .
a(n) ~ sqrt(3) * exp(Pi*sqrt(2*n/3)) / (2*Pi^2). - Vaclav Kotesovec, May 29 2018
EXAMPLE
a(5)=22: the partitions of 5 are 1+1+1+1+1 (1 distinct part), 1+1+1+2 (2 d.p.), 1+2+2 (2 d.p.), 1+1+3 (2 d.p.), 2+3 (2 d.p.), 1+4 (2 d.p.) and 5 (1. d.p.). The sum of the squares of the number of distinct parts is 1 +2^2 +2^2 +2^2 +2^2 +2^2 +1^2= 22. - R. J. Mathar, Mar 12 2023
MAPLE
A135348 := proc(n)
local gf, m ;
gf := x*(1+x^2)/(1-x)/(1-x^2) ;
for m from 1 to n do
gf := taylor(gf/(1-x^m), x=0, n+1)
od:
coeftayl(gf, x=0, n) ;
end:
seq(A135348(n), n=1..80) ; # R. J. Mathar, Feb 19 2008
MATHEMATICA
nmax = 50; Rest[CoefficientList[Series[x*(1 + x^2)/((1 - x)*(1 - x^2)) * Product[1/(1 - x^k), {k, 1, nmax}], {x, 0, nmax}], x]] (* Vaclav Kotesovec, May 29 2018 *)
PROG
(PARI) A135348(N, x='x)=Vec((1+x^2)/prod(m=1, N-1, 1-x^m, (1-x+O(x^N))*(1-x^2))) \\ M. F. Hasler, May 13 2018
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Vladeta Jovovic, Feb 16 2008
EXTENSIONS
More terms from R. J. Mathar, Feb 19 2008
STATUS
approved