A008451 Number of ways of writing n as a sum of 7 squares.
1, 14, 84, 280, 574, 840, 1288, 2368, 3444, 3542, 4424, 7560, 9240, 8456, 11088, 16576, 18494, 17808, 19740, 27720, 34440, 29456, 31304, 49728, 52808, 43414, 52248, 68320, 74048, 68376, 71120, 99456, 110964, 89936, 94864, 136080, 145222
Offset: 0
Keywords
References
- E. Grosswald, Representations of Integers as Sums of Squares. Springer-Verlag, NY, 1985, p. 121.
- G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers. 3rd ed., Oxford Univ. Press, 1954, p. 314.
Links
- T. D. Noe, Table of n, a(n) for n = 0..10000
- Philippe A. J. G. Chevalier, On the discrete geometry of physical quantities, 2013
- P. A. J. G. Chevalier, A "table of Mendeleev" for physical quantities?, Slides from a talk, May 14 2014, Leuven, Belgium.
- Shi-Chao Chen, Congruences for rs(n), Journal of Number Theory, Volume 130, Issue 9, September 2010, Pages 2028-2032.
- S. C. Milne, Infinite families of exact sums of squares formulas, Jacobi elliptic functions, continued fractions and Schur functions, Ramanujan J., 6 (2002), 7-149.
- Index entries for sequences related to sums of squares
Programs
-
Maple
series((sum(x^(m^2),m=-10..10))^7, x, 101); # Alternative #(requires at least Maple 17, and only works as long as a(n) <= 10^16 or so): N:= 1000: # to get a(0) to a(N) with(SignalProcessing): A:= Vector(N+1,datatype=float[8],i-> piecewise(i=1,1,issqr(i-1),2,0)): A2:= Convolution(A,A)[1..N+1]: A4:= Convolution(A2,A2)[1..N+1]: A5:= Convolution(A,A4)[1..N+1]; A7:= Convolution(A2,A5)[1..N+1]; map(round,convert(A7,list)); # Robert Israel, Jul 16 2014 # Alternative A008451list := proc(len) series(JacobiTheta3(0, x)^7, x, len+1); seq(coeff(%,x,j), j=0..len-1) end: A008451list(37); # Peter Luschny, Oct 02 2018
-
Mathematica
Table[SquaresR[7, n], {n, 0, 36}] (* Ray Chandler, Nov 28 2006 *) SquaresR[7,Range[0,50]] (* Harvey P. Dale, Aug 26 2011 *)
-
Python
# uses Python code from A000141 from math import isqrt def A008451(n): return A000141(n)+(sum(A000141(n-k**2) for k in range(1,isqrt(n)+1))<<1) # Chai Wah Wu, Jun 23 2024
-
Sage
Q = DiagonalQuadraticForm(ZZ, [1]*7) Q.representation_number_list(37) # Peter Luschny, Jun 20 2014
Formula
G.f.: theta_3(0,x)^7, where theta_3 is the third Jacobi theta function. - Robert Israel, Jul 16 2014
a(n) = (14/n)*Sum_{k=1..n} A186690(k)*a(n-k), a(0) = 1. - Seiichi Manyama, May 27 2017
Extensions
Extended by Ray Chandler, Nov 28 2006