cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A161516 Expansion of 1 + 2*Sum_{n >= 1} (-q)^n*(1 + q^2)*(1 + q^4)*...*(1 + q^(2*k - 2))/ ((1 - q)*(1 - q^3)*...*(1 - q^(2*n - 1))).

This page as a plain text file.
%I A161516 #30 Jun 02 2025 01:44:05
%S A161516 1,-2,0,-2,2,0,2,0,2,-2,2,0,0,-2,0,-4,2,0,0,-2,0,-2,2,0,2,-2,2,0,2,0,
%T A161516 2,0,0,-2,2,-2,4,0,0,-2,0,0,0,-4,0,-2,2,0,2,-4,0,0,0,-2,2,-2,0,0,2,0,
%U A161516 2,-2,0,-2,4,0,4,0,0,0,0,-2,2,0,0,-2,2,0,4,-2
%N A161516 Expansion of 1 + 2*Sum_{n >= 1} (-q)^n*(1 + q^2)*(1 + q^4)*...*(1 + q^(2*k - 2))/ ((1 - q)*(1 - q^3)*...*(1 - q^(2*n - 1))).
%C A161516 (-1)^n*a(n) is the number of inequivalent elements of norm 8*n-1 in Z[sqrt(2)].
%H A161516 G. C. Greubel, <a href="/A161516/b161516.txt">Table of n, a(n) for n = 0..1000</a>
%H A161516 Daniel Corson, David Favero, Kate Liesinger, Sarah Zubairy, <a href="https://doi.org/10.1016/j.jnt.2004.03.002">Characters and q-series in Q(sqrt(2))</a>, J. Number Theory, 107 (2004), 392-405.
%H A161516 Jeremy Lovejoy, <a href="https://doi.org/10.1016/j.jnt.2003.12.014">Overpartitions and real quadratic fields</a>, J. Number Theory, 106 (2004), 178-186.
%t A161516 With[{m=80}, CoefficientList[Series[1+2*Sum[(-q)^n*QPochhammer[q^4, q^4]*QPochhammer[q^(2*n+1), q]/((1+q^(2*n))*QPochhammer[q^(4*n+4), q^4]*QPochhammer[q, q]), {n, 1, m}], {q, 0, m}], q]] (* _G. C. Greubel_, Dec 04 2018 *)
%o A161516 (PARI) m=80; my(q='q+O('q^m)); Vec(1 + 2*sum(n=1,m, ((-q)^n/(1+q^(2*n) ))*prod(k=1,n, (1-q^(4*k))/((1-q^(2*k))*(1-q^(2*k-1)))) )) \\ _G. C. Greubel_, Dec 04 2018
%o A161516 (Magma) m:=80; R<q>:=PowerSeriesRing(Integers(), m); [1] cat Coefficients(R!( 2*(&+[((-q)^n/(1+q^(2*n)))*(&*[(1-q^(4*k))/((1-q^(2*k))*(1-q^(2*k-1))): k in [1..n]]): n in [1..m]]) )); // _G. C. Greubel_, Dec 04 2018
%o A161516 (Sage)
%o A161516 from sage.combinat.q_analogues import q_pochhammer
%o A161516 prec = 80
%o A161516 R = PowerSeriesRing(ZZ, 'x')
%o A161516 x = R.gen().O(prec)
%o A161516 s = 1+2*sum( (-x)^n*q_pochhammer(n, x^4, x^4)/((1+x^(2*n))* q_pochhammer(2*n, x, x)) for n in (1..prec))
%o A161516 print(s.coefficients()) # _G. C. Greubel_, Dec 04 2018
%K A161516 sign
%O A161516 0,2
%A A161516 _Jeremy Lovejoy_, Jun 12 2009