|
| |
|
|
A004018
|
|
Theta series of square lattice (or number of ways of writing n as a sum of 2 squares).
(Formerly M3218)
|
|
40
| |
|
|
1, 4, 4, 0, 4, 8, 0, 0, 4, 4, 8, 0, 0, 8, 0, 0, 4, 8, 4, 0, 8, 0, 0, 0, 0, 12, 8, 0, 0, 8, 0, 0, 4, 0, 8, 0, 4, 8, 0, 0, 8, 8, 0, 0, 0, 8, 0, 0, 0, 4, 12, 0, 8, 8, 0, 0, 0, 0, 8, 0, 0, 8, 0, 0, 4, 16, 0, 0, 8, 0, 0, 0, 4, 8, 8, 0, 0, 0, 0, 0, 8, 4, 8, 0, 0, 16, 0, 0, 0, 8, 8, 0, 0, 0, 0, 0, 0, 8, 4, 0, 12, 8
(list; graph; refs; listen; history; internal format)
|
|
|
|
OFFSET
| 0,2
|
|
|
COMMENTS
| Number of points in square lattice on the circle of radius sqrt(n).
Often denoted by r(n) or r_2(n).
Let b(n)=A004403(n), then sum(k=1..n, a(k)*b(n-k) ) = 1 - John W. Layman
Theta series of D_2 lattice.
Let s = 16*q*(E1*E4^2/E2^3)^8 where Ek = prod(n>=1, 1-q^(k*n) ) (s=k^2 where k is elliptic k), then the g.f. is hypergeom([+1/2, +1/2], [+1], s) (expansion of 2/Pi*elliptic_K(k) in powers of q). [Joerg Arndt, Aug 15 2011]
Ramanujan theta functions: f(q) (see A121373), phi(q) (A000122), psi(q) (A010054), chi(q) (A000700).
|
|
|
REFERENCES
| G. E. Andrews, R. Lewis and Z.-G. Liu, An identity relating a theta series to a sum of Lambert series, Bull. London Math. Soc., 33 (2001), 25-31.
L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 162, #16 (7), r(n).
J. H. Conway and N. J. A. Sloane, "Sphere Packings, Lattices and Groups", Springer-Verlag, p. 106.
N. J. Fine, Basic Hypergeometric Series and Applications, Amer. Math. Soc., 1988; p. 78, Eq. (32.23).
E. Grosswald, Representations of Integers as Sums of Squares. Springer-Verlag, NY, 1985.
G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, p. 240, r(n).
M. D. Hirschhorn, The number of representations of a number by various forms, Discr. Math., 298 (2005), 205-211.
C. D. Olds, A. Lax and G. P. Davidoff, The Geometry of Numbers, Math. Assoc. Amer., 2000, p. 51.
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
|
|
|
LINKS
| T. D. Noe, Table of n, a(n) for n=0..10000
H. H. Chan and C. Krattenthaler, Recent progress in the study of representations of integers as sums of squares
S. Cooper and M. Hirschhorn, A combinatorial proof of a result from number theory, Integers 4 (2004), #A09.
Michael Gilleland, Some Self-Similar Integer Sequences
M. D. Hirschhorn, Jacobi's Two-Square Theorem and Related Identities
M. D. Hirschhorn, Arithmetic Consequences of Jacobi's Two-Squares Theorem
G. Nebe and N. J. A. Sloane, Home page for this lattice
F. Richman, Counting Gaussian integers in a disk
M. Somos, Introduction to Ramanujan theta functions
G. Villemin, SOMMES DE 2 CARRES
Eric Weisstein's World of Mathematics, Barnes-Wall Lattice
Eric Weisstein's World of Mathematics, Moebius Transform
Eric Weisstein's World of Mathematics, Ramanujan Theta Functions
Eric Weisstein's World of Mathematics, Sum of Squares Function
Eric Weisstein's World of Mathematics, Theta Series
G. Xiao, Two squares
Index entries for sequences related to sums of squares
Index entries for "core" sequences
|
|
|
FORMULA
| Expansion of theta_3(q)^2 = sum(n=-inf..+inf, q^(n^2) )^2 = prod(m>=1, (1-q^(2*m))^2 * (1+q^(2*m-1))^4 ).
Factor n as n = p1^a1 * p2^a2 * ... * q1^b1 * q2^b2 * ... * 2^c, where the p's are primes == 1 mod 4 and the q's are primes == 3 mod 4. Then a(n) = 0 if any b is odd, otherwise a(n) = 4*(1 + a1)*(1 + a2)*...
G.f. = s(2)^10/(s(1)^4*s(4)^4), where s(k) := subs(q=q^k, eta(q)) and eta(q) is Dedekind's function, cf. A010815. [Fine]
Expansion of eta(q^2)^10 / ( eta(q) * eta(q^4) )^4 in powers of q. - Michael Somos, Jul 19 2004
Expansion of ( phi(q)^2 + phi(-q)^2 ) / 2 in powers of q^2 where phi() = theta3() is a Ramanujan theta function.
G.f. A(x) satisfies 0 = f(A(x), A(x^2), A(x^4)) where f(u, v, w) = (u - v)^2 - (v - w) * 4 * w. - Michael Somos, Jul 19 2004
Euler transform of period 4 sequence [ 4, -6, 4, -2, ...]. - Michael Somos, Jul 19 2004
Moebius transform is period 4 sequence [ 4, 0, -4, 0, ...]. - Michael Somos, Sep 17 2007
G.f. is a period 1 Fourier series which satisfies f(-1/(4*t)) = 2*(t/i)*f(t) where q = exp(2*Pi*i*t).
The constant sqrt(Pi)/GAMMA(3/4)^2 produces the first 324 terms of the sequence when expanded in base exp(Pi), 450 digits of the constant are necessary. Simon Plouffe, March 3 2011.
a(n) = A004531(4*n). a(n) = 2*A105673(n), if n>0.
|
|
|
EXAMPLE
| 1 + 4*q + 4*q^2 + 4*q^4 + 8*q^5 + 4*q^8 + 4*q^9 + 8*q^10 + 8*q^13 + 4*q^16 + 8*q^17 + 4*q^18 + 8*q^20 + 12*q^25 + 8*q^26 + 8*q^29 + 4*q^32 + 8*q^34 + 4*q^36 + 8*q^37 + 8*q^40 + 8*q^41 + 8*q^45 + 4*q^49 + 12*q^50 + 8*q^52 + 8*q^53 + 8*q^58 + 8*q^61 + 4*q^64 + 16*q^65 + 8*q^68 + 4*q^72 + 8*q^73 + 8*q^74 + 8*q^80 + 4*q^81 + 8*q^82 + 16*q^85 + 8*q^89 + 8*q^90 + 8*q^97 + 4*q^98 + 12*q^100 + 8*q^101 + 8*q^104 + 8*q^106 + 8*q^109 + 8*q^113 + ... (from John Cannon, Dec 30 2006)
|
|
|
MAPLE
| (sum(x^(m^2), m=-10..10))^2;
|
|
|
MATHEMATICA
| a[ n_] := SquaresR[ 2, n] (* Michael Somos, Nov 15 2011 *)
a[ n_] := SeriesCoefficient[ EllipticTheta[ 3, 0, x]^2, {x, 0, n}] (* Michael Somos, Nov 15 2011 *)
SquaresR[2, Range[0, 110]] (* From Harvey P. Dale, Oct 10 2011 *)
|
|
|
PROG
| (PARI) {a(n) = if( n<0, 0, polcoeff( 1 + 4 * sum( k=1, n, x^k / (1 + x^(2*k)), x * O(x^n)), n))}
(PARI) {a(n) = if( n<1, n==0, 4 * sumdiv( n, d, (d%4==1) - (d%4==3)))} /* Michael Somos, Jul 19 2004 */
(PARI) {a(n) = if( n<1, n==0, 2 *qfrep([ 1, 0; 0, 1], n)[n])} /* Michael Somos, May 13 2005 */
|
|
|
CROSSREFS
| Cf. A001481, A004020, A005883, A057655 (partial sums), A057961, A057962. Except for first term, A004018(n)=4*A002654(n). Partial sums - 1 give A014198.
Cf. A104271, A105673.
Cf. A071385 gives records; A071383 gives where records occur.
Sequence in context: A155836 A164613 A104794 * A028658 A169784 A028642
Adjacent sequences: A004015 A004016 A004017 * A004019 A004020 A004021
|
|
|
KEYWORD
| nonn,easy,nice,core
|
|
|
AUTHOR
| N. J. A. Sloane (njas(AT)research.att.com).
|
|
|
EXTENSIONS
| More terms from James A. Sellers (sellersj(AT)math.psu.edu), Aug 22 2000
Villemin link fixed by Robert Munafo (mrob27(AT)gmail.com), Dec 14 2009
|
| |
|
|