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.

A000451 Smallest number that is the sum of 3 squares in at least n ways.

Original entry on oeis.org

0, 9, 41, 81, 146, 194, 306, 369, 425, 594, 689, 866, 1109, 1154, 1154, 1361, 1634, 1781, 1889, 2141, 2609, 2609, 3366, 3366, 3449, 3449, 3506, 4241, 4289, 4826, 5066, 5381, 5561, 5561, 6254, 7229, 7829, 8069, 8069, 8126, 8609, 8774, 8774
Offset: 1

Views

Author

Keywords

Programs

  • Mathematica
    nn = 100; lim = nn^2; t = Table[0, {lim}]; Do[k = x^2 + y^2 + z^2; If[0 < k <= lim, t[[k]]++], {x, 0, nn}, {y, x, nn}, {z, y, nn}]; u = Union[t]; c = Complement[Range[u[[-1]]], u]; If[c == {}, mx = u[[-1]], mx = c[[1]] - 1]; Join[{0}, Flatten[Table[Position[t, ?(# >= n &), 1, 1], {n, 2, mx}]]] (* _T. D. Noe, Jun 20 2012 *)