OFFSET
0,2
COMMENTS
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..2500
Michael Somos, Introduction to Ramanujan theta functions
Eric Weisstein's World of Mathematics, Ramanujan Theta Functions
FORMULA
Euler transform of period 20 sequence [ 2, 2, 0, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 0, 2, 2, 0, ...].
Expansion of (f(x, -x^4) / f(-x^2, -x^2))^2 = (f(x^2, x^8) / f(-x, -x^4))^2 in powers of x where f(, ) is Ramanujan's general theta function.
G.f.: (Sum_{k>=0} x^(k^2 + k) / ((1 - x) * (1 - x^2) * ... * (1 - x^(2*k+1))))^2.
a(n) = - A147699(5*n + 2).
Convolution square of A122135.
EXAMPLE
G.f. = 1 + 2*x + 5*x^2 + 8*x^3 + 14*x^4 + 22*x^5 + 36*x^6 + 54*x^7 + ...
G.f. = q^9 + 2*q^29 + 5*q^49 + 8*q^69 + 14*q^89 + 22*q^109 + 36*q^129 + ...
MATHEMATICA
a[ n_] := SeriesCoefficient[ (QPochhammer[ x, x^2] QPochhammer[ x^2, -x^5] QPochhammer[ -x^3, -x^5])^-2, {x, 0, n}];
a[ n_] := SeriesCoefficient[ Product[ (1 - x^k)^-{2, 2, 0, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 0, 2, 2, 0}[[Mod[k, 20, 1]]], {k, n}], {x, 0, n}];
PROG
(PARI) {a(n) = if( n<0, 0, polcoeff( prod(k=1, n, (1 - x^k + x * O(x^n))^-[ 0, 2, 2, 0, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 2, 2, 0, 0, 2, 2][k%20 + 1]), n))};
(PARI) {a(n) = if( n<0, 0, polcoeff( sum(k=0, (sqrtint(4*n + 1) - 1)\2, x^(k^2 + k)/ prod(i=1, 2*k+1, 1 - x^i, 1 + x * O(x^(n - k^2-k))))^2, n))};
CROSSREFS
KEYWORD
nonn
AUTHOR
Michael Somos, Sep 03 2015
STATUS
approved