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.

Showing 1-10 of 13 results. Next

A224212 Number of nonnegative solutions to x^2 + y^2 <= n.

Original entry on oeis.org

1, 3, 4, 4, 6, 8, 8, 8, 9, 11, 13, 13, 13, 15, 15, 15, 17, 19, 20, 20, 22, 22, 22, 22, 22, 26, 28, 28, 28, 30, 30, 30, 31, 31, 33, 33, 35, 37, 37, 37, 39, 41, 41, 41, 41, 43, 43, 43, 43, 45, 48, 48, 50, 52, 52, 52, 52, 52, 54, 54, 54, 56, 56, 56, 58, 62, 62, 62, 64
Offset: 0

Views

Author

Alex Ratushnyak, Apr 01 2013

Keywords

Crossrefs

Cf. A000925 (first differences).
Cf. A000606 (number of nonnegative solutions to x^2 + y^2 + z^2 <= n).
Cf. A057655 (number of integer solutions to x^2 + y^2 <= n).

Programs

  • Mathematica
    nn = 68; t = Table[0, {nn}]; Do[d = x^2 + y^2; If[0 < d <= nn, t[[d]]++], {x, 0, nn}, {y, 0, nn}]; Accumulate[Join[{1}, t]] (* T. D. Noe, Apr 01 2013 *)
  • Python
    for n in range(99):
      k = 0
      for x in range(99):
        s = x*x
        if s>n: break
        for y in range(99):
            sy = s + y*y
            if sy>n: break
            k+=1
      print(str(k), end=', ')

Formula

G.f.: (1/(1 - x))*(Sum_{k>=0} x^(k^2))^2. - Ilya Gutkovskiy, Mar 14 2017

A002102 Number of nonnegative solutions to x^2 + y^2 + z^2 = n.

Original entry on oeis.org

1, 3, 3, 1, 3, 6, 3, 0, 3, 6, 6, 3, 1, 6, 6, 0, 3, 9, 6, 3, 6, 6, 3, 0, 3, 9, 12, 4, 0, 12, 6, 0, 3, 6, 9, 6, 6, 6, 9, 0, 6, 15, 6, 3, 3, 12, 6, 0, 1, 9, 15, 6, 6, 12, 12, 0, 6, 6, 6, 9, 0, 12, 12, 0, 3, 18, 12, 3, 9, 12, 6, 0, 6, 9, 18, 7, 3, 12, 6, 0, 6, 15, 9, 9, 6, 12, 15, 0, 3, 21, 18, 6, 0, 6
Offset: 0

Views

Author

Keywords

References

  • A. Das and A. C. Melissinos, Quantum Mechanics: A Modern Introduction, Gordon and Breach, 1986, p. 48.
  • H. Gupta, A Table of Values of N_3(t), Proc. National Institute of Sciences of India, 13 (1947), 35-63.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

First differences of A000606.

Programs

  • Mathematica
    a[n_] := Module[{x, y, z, c}, For[x=c=0, x^2<=n, x++, For[y=0, x^2+y^2<=n, y++, If[IntegerQ[Sqrt[n-x^2-y^2]], c++ ]]]; c]
    CoefficientList[Series[Sum[q^n^2, {n, 0, 12}], {q, 0, 150}]^3, q]
  • PARI
    Vec(sum(k=0,9,x^(k^2),O(x^100))^3) \\ Charles R Greathouse IV, Jun 13 2012

Formula

Coefficient of q^k in (1/8)*(1 + theta_3(0, q))^3, or coefficient of q^n in (1 + q + q^4 + q^9 + q^16 + q^25 + q^36 + q^49 + q^64 + ...)^3.

Extensions

More terms from Dean Hickerson, Oct 07 2001

A224213 Number of nonnegative solutions to x^2 + y^2 + z^2 + u^2 <= n.

Original entry on oeis.org

1, 5, 11, 15, 20, 32, 44, 48, 54, 70, 88, 100, 108, 124, 148, 160, 165, 189, 219, 235, 253, 281, 305, 317, 329, 357, 399, 427, 439, 475, 523, 539, 545, 581, 623, 659, 688, 716, 764, 792, 810, 858, 918, 946, 970, 1030, 1078, 1102, 1110, 1154, 1226, 1274, 1304, 1352
Offset: 0

Views

Author

Alex Ratushnyak, Apr 01 2013

Keywords

Crossrefs

Cf. A014110 (first differences).
Cf. A224212 (number of nonnegative solutions to x^2 + y^2 <= n).
Cf. A000606 (number of nonnegative solutions to x^2 + y^2 + z^2 <= n).
Cf. A046895 (number of integer solutions to x^2 + y^2 + z^2 + u^2 <= n).

Programs

  • Mathematica
    nn = 50; t = Table[0, {nn}]; Do[d = x^2 + y^2 + z^2 + u^2; If[0 < d <= nn, t[[d]]++], {x, 0, nn}, {y, 0, nn}, {z, 0, nn}, {u, 0, nn}]; Accumulate[Join[{1}, t]] (* T. D. Noe, Apr 01 2013 *)
  • Python
    for n in range(99):
      k = 0
      for x in range(99):
        s = x*x
        if s>n: break
        for y in range(99):
            sy = s + y*y
            if sy>n: break
            for z in range(99):
                sz = sy + z*z
                if sz>n: break
                for u in range(99):
                  su = sz + u*u
                  if su>n: break
                  k+=1
      print(str(k), end=', ')

Formula

G.f.: (1/(1 - x))*(Sum_{k>=0} x^(k^2))^4. - Ilya Gutkovskiy, Mar 14 2017

A000604 Number of nonnegative solutions to x^2 + y^2 + z^2 <= n^2.

Original entry on oeis.org

1, 4, 11, 29, 54, 99, 163, 239, 344, 486, 648, 847, 1069, 1355, 1680, 2046, 2446, 2911, 3443, 4022, 4662, 5395, 6145, 6998, 7913, 8913, 10006, 11194, 12437, 13751, 15216, 16710, 18361, 20123, 21950, 23919, 25956, 28150, 30415, 32876, 35385, 38049, 40876
Offset: 0

Views

Author

Keywords

References

  • H. Gupta, A Table of Values of N_3(t), Proc. National Institute of Sciences of India, 13 (1947), 35-63.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Column k=3 of A302998.
Cf. A000606.

Programs

  • Mathematica
    a[n_] := Sum[Boole[x^2 + y^2 + z^2 <= n^2], {x, 0, n}, {y, 0, Sqrt[n^2 - x^2]}, {z, 0, Sqrt[n^2 - x^2 - y^2]}]; A000604 = Table[an = a[n]; Print["a(", n, ") = ", an]; an, {n, 0, 100}] (* Jean-François Alcover, Feb 10 2016 *)

Formula

a(n) = [x^(n^2)] (1 + theta_3(x))^3/(8*(1 - x)), where theta_3() is the Jacobi theta function. - Ilya Gutkovskiy, Apr 15 2018

Extensions

More terms from David W. Wilson, May 22 2000

A302862 a(n) = [x^n] (1 + theta_3(x))^n/(2^n*(1 - x)), where theta_3() is the Jacobi theta function.

Original entry on oeis.org

1, 2, 4, 8, 20, 57, 160, 422, 1076, 2780, 7449, 20462, 56348, 153909, 418268, 1139703, 3126068, 8618611, 23801146, 65708424, 181391905, 501296216, 1387834518, 3848187985, 10680579812, 29660831057, 82415406493, 229156296047, 637659848888, 1775648562970, 4947475298595
Offset: 0

Views

Author

Ilya Gutkovskiy, Apr 14 2018

Keywords

Comments

a(n) = number of nonnegative solutions to (x_1)^2 + (x_2)^2 + ... + (x_n)^2 <= n.

Crossrefs

Programs

  • Mathematica
    Table[SeriesCoefficient[(1 + EllipticTheta[3, 0, x])^n/(2^n (1 - x)), {x, 0, n}], {n, 0, 30}]
    Table[SeriesCoefficient[1/(1 - x) Sum[x^k^2, {k, 0, n}]^n, {x, 0, n}], {n, 0, 30}]

A341400 Number of nonnegative solutions to (x_1)^2 + (x_2)^2 + ... + (x_5)^2 <= n.

Original entry on oeis.org

1, 6, 16, 26, 36, 57, 87, 107, 122, 157, 207, 247, 277, 322, 392, 452, 482, 537, 637, 717, 773, 863, 973, 1053, 1113, 1203, 1343, 1473, 1553, 1668, 1858, 1998, 2053, 2173, 2373, 2543, 2673, 2818, 3018, 3218, 3338, 3483, 3753, 3973, 4113, 4344, 4634, 4834, 4944, 5139, 5449
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 10 2021

Keywords

Comments

Partial sums of A038671.

Crossrefs

Programs

  • Maple
    b:= proc(n, k) option remember; `if`(n=0, 1, `if`(n<0 or k<1, 0,
          b(n, k-1)+add(b(n-j^2, k-1), j=1..isqrt(n))))
        end:
    a:= proc(n) option remember; b(n, 5)+`if`(n>0, a(n-1), 0) end:
    seq(a(n), n=0..50);  # Alois P. Heinz, Feb 10 2021
  • Mathematica
    nmax = 50; CoefficientList[Series[(1 + EllipticTheta[3, 0, x])^5/(32 (1 - x)), {x, 0, nmax}], x]

Formula

G.f.: (1 + theta_3(x))^5 / (32 * (1 - x)).
a(n^2) = A055404(n).

A341401 Number of nonnegative solutions to (x_1)^2 + (x_2)^2 + ... + (x_6)^2 <= n.

Original entry on oeis.org

1, 7, 22, 42, 63, 99, 160, 220, 265, 337, 457, 577, 672, 792, 978, 1178, 1319, 1469, 1739, 2039, 2255, 2507, 2882, 3242, 3513, 3819, 4269, 4769, 5159, 5555, 6181, 6841, 7246, 7666, 8401, 9181, 9763, 10363, 11188, 12108, 12828, 13434, 14394, 15534, 16359, 17211, 18477, 19677
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 10 2021

Keywords

Comments

Partial sums of A045848.

Crossrefs

Programs

  • Maple
    b:= proc(n, k) option remember; `if`(n=0, 1, `if`(n<0 or k<1, 0,
          b(n, k-1)+add(b(n-j^2, k-1), j=1..isqrt(n))))
        end:
    a:= proc(n) option remember; b(n, 6)+`if`(n>0, a(n-1), 0) end:
    seq(a(n), n=0..47);  # Alois P. Heinz, Feb 10 2021
  • Mathematica
    nmax = 47; CoefficientList[Series[(1 + EllipticTheta[3, 0, x])^6/(64 (1 - x)), {x, 0, nmax}], x]

Formula

G.f.: (1 + theta_3(x))^6 / (64 * (1 - x)).
a(n^2) = A055405(n).

A341402 Number of nonnegative solutions to (x_1)^2 + (x_2)^2 + ... + (x_7)^2 <= n.

Original entry on oeis.org

1, 8, 29, 64, 106, 169, 281, 422, 548, 702, 961, 1276, 1556, 1864, 2326, 2893, 3390, 3852, 4545, 5455, 6253, 7002, 8080, 9361, 10453, 11496, 12903, 14618, 16194, 17643, 19589, 22011, 24027, 25714, 28143, 31188, 33792, 36137, 39203, 42920, 46294, 49108, 52580, 57165, 61365
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 10 2021

Keywords

Comments

Partial sums of A045849.

Crossrefs

Programs

  • Maple
    b:= proc(n, k) option remember; `if`(n=0, 1, `if`(n<0 or k<1, 0,
          b(n, k-1)+add(b(n-j^2, k-1), j=1..isqrt(n))))
        end:
    a:= proc(n) option remember; b(n, 7)+`if`(n>0, a(n-1), 0) end:
    seq(a(n), n=0..44);  # Alois P. Heinz, Feb 10 2021
  • Mathematica
    nmax = 44; CoefficientList[Series[(1 + EllipticTheta[3, 0, x])^7/(128 (1 - x)), {x, 0, nmax}], x]

Formula

G.f.: (1 + theta_3(x))^7 / (128 * (1 - x)).
a(n^2) = A055406(n).

A295849 Number of nonnegative solutions to gcd(x,y,z) = 1 and x^2 + y^2 + z^2 <= n.

Original entry on oeis.org

0, 3, 6, 7, 7, 13, 16, 16, 16, 19, 25, 28, 28, 34, 40, 40, 40, 49, 52, 55, 55, 61, 64, 64, 64, 70, 82, 85, 85, 97, 103, 103, 103, 109, 118, 124, 124, 130, 139, 139, 139, 154, 160, 163, 163, 169, 175, 175, 175, 181, 193, 199, 199, 211, 220, 220, 220, 226, 232, 241
Offset: 0

Views

Author

Seiichi Manyama, Nov 29 2017

Keywords

Crossrefs

Programs

  • Maple
    N:= 100:
    V:= Vector(N):
    for x from 0 to floor(sqrt(N/3)) do
      for y from x to floor(sqrt((N-x^2)/2)) do
        for z from y to floor(sqrt(N-x^2-y^2)) do
          if igcd(x,y,z) = 1 then
            r:= x^2 + y^2 + z^2;
            m:= nops({x,y,z});
            if m=3 then V[r]:= V[r]+6
            elif m=2 then V[r]:= V[r]+3
            else V[r]:= V[r]+1
            fi
          fi
    od od od:
    0,op(ListTools:-PartialSums(convert(V,list))); # Robert Israel, Nov 30 2017
  • Mathematica
    a[n_] := Sum[Boole[GCD[i, j, k] == 1], {i, 0, Sqrt[n]}, {j, 0, Sqrt[n - i^2]}, {k, 0, Sqrt[n - i^2 - j^2]}];
    Table[a[n], {n, 0, 60}] (* Jean-François Alcover, Jul 07 2018, after Andrew Howroyd *)
  • PARI
    a(n) = {sum(i=0, sqrtint(n), sum(j=0, sqrtint(n-i^2), sum(k=0, sqrtint(n-i^2-j^2), gcd([i, j, k]) == 1)))} \\ Andrew Howroyd, Dec 12 2017

Formula

a(n) = a(n-1) + A295848(n) for n > 0.

A341403 Number of nonnegative solutions to (x_1)^2 + (x_2)^2 + ... + (x_8)^2 <= n.

Original entry on oeis.org

1, 9, 37, 93, 171, 283, 479, 767, 1076, 1420, 1952, 2688, 3444, 4228, 5320, 6776, 8262, 9662, 11454, 13918, 16480, 18832, 21772, 25644, 29508, 33044, 37300, 42732, 48340, 53556, 59632, 67472, 75405, 82237, 90189, 100661, 111155, 120403, 131099, 144651, 158469, 170621
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 10 2021

Keywords

Comments

Partial sums of A045850.

Crossrefs

Programs

  • Maple
    b:= proc(n, k) option remember; `if`(n=0, 1, `if`(n<0 or k<1, 0,
          b(n, k-1)+add(b(n-j^2, k-1), j=1..isqrt(n))))
        end:
    a:= proc(n) option remember; b(n, 8)+`if`(n>0, a(n-1), 0) end:
    seq(a(n), n=0..41);  # Alois P. Heinz, Feb 10 2021
  • Mathematica
    nmax = 41; CoefficientList[Series[(1 + EllipticTheta[3, 0, x])^8/(256 (1 - x)), {x, 0, nmax}], x]

Formula

G.f.: (1 + theta_3(x))^8 / (256 * (1 - x)).
a(n^2) = A055407(n).
Showing 1-10 of 13 results. Next