The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation. Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A033716 Number of integer solutions to the equation x^2 + 3y^2 = n. 17
 1, 2, 0, 2, 6, 0, 0, 4, 0, 2, 0, 0, 6, 4, 0, 0, 6, 0, 0, 4, 0, 4, 0, 0, 0, 2, 0, 2, 12, 0, 0, 4, 0, 0, 0, 0, 6, 4, 0, 4, 0, 0, 0, 4, 0, 0, 0, 0, 6, 6, 0, 0, 12, 0, 0, 0, 0, 4, 0, 0, 0, 4, 0, 4, 6, 0, 0, 4, 0, 0, 0, 0, 0, 4, 0, 2, 12, 0, 0, 4, 0, 2, 0, 0, 12, 0, 0, 0, 0, 0, 0, 8, 0, 4, 0, 0, 0, 4, 0, 0, 6, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 0,2 COMMENTS The cubic modular equation for k is equivalent to theta_4(q) * theta_4(q^3) + theta_2(q)* theta_2(q^3) = theta_3(q) * theta_3(q^3). - Michael Somos, Feb 17 2003 The number of nonnegative solutions is given by A119395. - Max Alekseyev, May 16 2006 Fermat used infinite descent to prove "That there is no number, less by a unit than a multiple of 3, which is composed of a square and the triple of another square". [Yves Hellegouarch, "Invitation to the Mathematics of Fermat-Wiles", Academic Press, 2002, page 4]. - Michael Somos, Sep 03 2016 REFERENCES J. M. Borwein, P. B. Borwein, Pi and the AGM, Wiley, 1987, p. 110. J. H. Conway and N. J. A. Sloane, "Sphere Packings, Lattices and Groups", Springer-Verlag, p 102 eq 9. N. J. Fine, Basic Hypergeometric Series and Applications, Amer. Math. Soc., 1988; p. 78, Eq. (32.25). LINKS Antti Karttunen, Table of n, a(n) for n = 0..65537 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. Michael Gilleland, Some Self-Similar Integer Sequences M. D. Hirschhorn, Three classical results on representations of a number, Séminaire Lotharingien de Combinatoire, B42f (1999), 8 pp. M. D. Hirschhorn, The number of representations of a number by various forms, Discrete Mathematics 298 (2005), 205-211. H Movasati, Y Nikdelan, Gauss-Manin Connection in Disguise: Dwork Family, arXiv preprint arXiv:1603.09411, 2016. N. J. A. Sloane et al., Binary Quadratic Forms and OEIS (Index to related sequences, programs, references) FORMULA Fine gives an explicit formula for a(n) in terms of the divisors of n. Coefficients in expansion of Sum_{ i, j = -inf .. inf } q^(i^2+3*j^2). G.f.: s(2)^5*s(6)^5/(s(1)^2*s(3)^2*s(4)^2*s(12)^2), where s(k) := subs(q=q^k, eta(q)), where eta(q) is Dedekind's function, cf. A010815. [Fine] Euler transform of period 12 sequence [ 2, -3, 4, -1, 2, -6, 2, -1, 4, -3, 2, -2, ...]. - Michael Somos, Feb 17 2003 G.f. A(x) satisfies 0 = f(A(x), A(x^3), A(x^9)) where f(u1, u3, u9) = (u1*u9) * (u1^2 - 3*u1*u3 + 3*u3^2) * (u3^2 - 3*u3*u9 + 3*u9^2) - u3^6. - Michael Somos, Sep 05 2005 G.f.: theta_3(q) * theta_3(q^3) = (Sum_{k in Z} x^(k^2)) * (Sum_{k in Z} x^(3k^2)). - Michael Somos, Sep 05 2005 Let n=3^d*p1^(2*b1)*...*pm^(2*bm)*q1^c1*...*qk^ck be a prime factorization of n where pi are primes of the form 3t+2 and qj are primes of the form 3t+1. Let B=(c1+1)*...*(ck+1). Then a(n)=0 if either of bi is a half-integer; a(n)=6B if n is a multiple of 4; and a(n)=2B otherwise. - Max Alekseyev, May 16 2006 a(n) = 2 * A096936(n). a(3*n + 2) = 0. a(3*n) = a(n). a(3*n + 1) = 2 * A129576(n). - Michael Somos, Sep 03 2016 EXAMPLE G.f. = 1 + 2*q + 2*q^3 + 6*q^4 + 4*q^7 + 2*q^9 + 6*q^12 + 4*q^13 + 6*q^16 + ... MATHEMATICA a[n_] := With[{r = Reduce[x^2 + 3*y^2 == n, {x, y}, Integers]}, Which[r === False, 0, Head[r] === And, 1, True, Length[r]]]; Table[a[n], {n, 0, 101}] (* Jean-François Alcover, Jan 10 2014 *) QP = QPochhammer; s = (QP[q^2] * QP[q^6])^5 / (QP[q] * QP[q^3] * QP[q^4] * QP[q^12])^2 + O[q]^100; CoefficientList[s, q] (* Jean-François Alcover, Nov 09 2015 *) a[ n_] := Length @ FindInstance[ x^2 + 3 y^2 == n, {x, y}, Integers, 10^9]; (* Michael Somos, Sep 03 2016 *) a[ n_] := SeriesCoefficient[ EllipticTheta[ 3, 0, q] EllipticTheta[ 3, 0, q^3], {q, 0, n}]; (* Michael Somos, Sep 03 2016 *) PROG (PARI) {a(n) = if( n<1, n==0, qfrep([1, 0; 0, 3], n)[n] * 2)}; /* Michael Somos, Jun 05 2005 */ (PARI) {a(n) = my(A); if( n<0, 0, A = x * O(x^n); polcoeff( (eta(x^2 + A) * eta(x^6 + A))^5 / (eta(x + A) * eta(x^3 + A) * eta(x^4 + A) * eta(x^12 + A))^2, n))}; /* Michael Somos, Jun 05 2005 */ (PARI) { a(n) = local(f, B); f=factorint(n); B=1; for(i=1, matsize(f), if(f[i, 1]%3==1, B*=f[i, 2]+1); if(f[i, 1]%3==2, if(f[i, 2]%2, return(0)))); if(n%4, 2*B, 6*B) } \\ Max Alekseyev, May 16 2006 (PARI) first(n) = {my(res = vector(n + 1)); for(i = 0, sqrtint(n \ 3), for(j = 0, sqrtint(n - 3*i^2), res[3*i^2 + j^2 + 1] += (1<<(!!i + !!j)))); res} \\ David A. Corneth, Nov 20 2017 CROSSREFS Cf. A096936, A119395, A129576. Sequence in context: A243159 A258144 A113772 * A115978 A033751 A033745 Adjacent sequences:  A033713 A033714 A033715 * A033717 A033718 A033719 KEYWORD nonn,easy AUTHOR STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified March 30 18:46 EDT 2020. Contains 333127 sequences. (Running on oeis4.)