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”).
%I #8 Mar 12 2021 22:24:48
%S 1,1,0,-2,1,0,-2,0,0,2,-2,0,1,1,0,-2,0,0,-2,-2,0,2,0,0,3,0,0,0,2,0,-2,
%T -2,0,2,0,0,2,1,0,-2,1,0,0,0,0,4,-2,0,2,0,0,-2,0,0,-2,-2,0,0,-2,0,1,0,
%U 0,-2,2,0,-4,0,0,2,0,0,0,3,0,-2,0,0,-2,0,0
%N Expansion of phi(-x^6) * psi(x^4) + x * phi(-x^2) * psi(x^12) in powers of x where phi(), psi() are Ramanujan theta functions.
%C Ramanujan theta functions: f(q) (see A121373), phi(q) (A000122), psi(q) (A010054), chi(q) (A000700).
%H Antti Karttunen, <a href="/A262780/b262780.txt">Table of n, a(n) for n = 0..10000</a>
%H Michael Somos, <a href="/A010815/a010815.txt">Introduction to Ramanujan theta functions</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/RamanujanThetaFunctions.html">Ramanujan Theta Functions</a>
%F a(n) = b(2*n + 1) where b() is multiplicative with b(2^e) = 0^e, b(3^e) = 1, b(p^e) = e+1 if p == 1, 19 (mod 24), b(p^e) = (-1)^e * (e+1) if p == 7, 13 (mod 24), b(p^e) = (1 + (-1)^e) / 2 if p == 5 (mod 6).
%F a(2*n) = A262774(n). a(2*n + 1) = A262726(n).
%F abs(a(n)) = A033762(n).
%e G.f. = 1 + x - 2*x^3 + x^4 - 2*x^6 + 2*x^9 - 2*x^10 + x^12 + x^13 + ...
%e G.f. = q + q^3 - 2*q^7 + q^9 - 2*q^13 + 2*q^19 - 2*q^21 + q^25 + ...
%t a[ n_] := If[ n < 0, 0, {1, 1, -1, 1, 1, -1, -1, 1, 1, -1, 1, 1}[[Mod[n, 12, 1]]] DivisorSum[ 2 n + 1, KroneckerSymbol[ -3, #] &]];
%t a[ n_] := SeriesCoefficient[ (EllipticTheta[ 4, 0, x^6] EllipticTheta[ 2, 0, x^2] + EllipticTheta[ 4, 0, x^2] EllipticTheta[ 2, 0, x^6]) / (2 x^(1/2)), {x, 0, n}];
%t a[ n_] := If[ n < 0, 0, Times @@ (Which[ # < 5, Mod[#, 2], Mod[#, 6] == 5, 1 - Mod[#2, 2], True, (#2 + 1) KroneckerSymbol[ 6, #]^#2] & @@@ FactorInteger @ (2 n + 1))];
%o (PARI) {a(n) = my(A, p, e); if( n<0, 0, A = factor(2*n + 1); prod(k=1, matsize(A)[1], [p, e] = A[k, ]; if( p<5, p%2, p%6 == 1, (e+1) * if( p%24 == 1 || p%24 == 19, 1, (-1)^e), 1-e%2 )))};
%Y Cf. A033762, A262726, A262774.
%K sign
%O 0,4
%A _Michael Somos_, Oct 01 2015