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.
%I A045849 #33 Aug 26 2019 08:05:15 %S A045849 1,7,21,35,42,63,112,141,126,154,259,315,280,308,462,567,497,462,693, %T A045849 910,798,749,1078,1281,1092,1043,1407,1715,1576,1449,1946,2422,2016, %U A045849 1687,2429,3045,2604,2345,3066 %N A045849 Number of nonnegative solutions of x1^2 + x2^2 + ... + x7^2 = n. %H A045849 Seiichi Manyama, <a href="/A045849/b045849.txt">Table of n, a(n) for n = 0..10000</a> (terms 0..2000 from T. D. Noe) %H A045849 <a href="/index/Su#ssq">Index entries for sequences related to sums of squares</a> %F A045849 Coefficient of q^n in (1 + q + q^4 + q^9 + q^16 + q^25 + q^36 + q^49 + q^64 + ...)^7. %F A045849 G.f.: (1 + theta_3(q))^7/128, where theta_3() is the Jacobi theta function. - _Ilya Gutkovskiy_, Aug 08 2018 %t A045849 (1 + EllipticTheta[3, 0, q])^7/128 + O[q]^50 // CoefficientList[#, q]& (* _Jean-François Alcover_, Aug 26 2019 *) %o A045849 (PARI) seq(n)=Vec((sum(k=0, sqrtint(n), x^(k^2)) + O(x*x^n))^7) \\ _Andrew Howroyd_, Aug 08 2018 %o A045849 (Ruby) %o A045849 def mul(f_ary, b_ary, m) %o A045849 s1, s2 = f_ary.size, b_ary.size %o A045849 ary = Array.new(s1 + s2 - 1, 0) %o A045849 (0..s1 - 1).each{|i| %o A045849 (0..s2 - 1).each{|j| %o A045849 ary[i + j] += f_ary[i] * b_ary[j] %o A045849 } %o A045849 } %o A045849 ary[0..m] %o A045849 end %o A045849 def power(ary, n, m) %o A045849 if n == 0 %o A045849 a = Array.new(m + 1, 0) %o A045849 a[0] = 1 %o A045849 return a %o A045849 end %o A045849 k = power(ary, n >> 1, m) %o A045849 k = mul(k, k, m) %o A045849 return k if n & 1 == 0 %o A045849 return mul(k, ary, m) %o A045849 end %o A045849 def A(k, n) %o A045849 ary = Array.new(n + 1, 0) %o A045849 (0..Math.sqrt(n).to_i).each{|i| ary[i * i] = 1} %o A045849 power(ary, k, n) %o A045849 end %o A045849 p A(7, 100) # _Seiichi Manyama_, May 28 2017 %Y A045849 Cf. A010052, A038671, A045847. %K A045849 nonn %O A045849 0,2 %A A045849 _N. J. A. Sloane_