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-6 of 6 results.

A025429 Number of partitions of n into 5 nonzero squares.

Original entry on oeis.org

0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 3, 0, 1, 3, 1, 3, 2, 1, 3, 2, 1, 3, 3, 2, 3, 2, 2, 2, 2, 3, 3, 5, 2, 2, 5, 1, 3, 5, 1, 5, 4, 2, 5, 3, 2, 5, 5, 3, 4, 4, 4, 3, 5, 4, 4, 7, 3, 5, 6, 2, 4, 7, 4, 7, 6, 3, 7, 4, 3, 8, 6, 5, 7, 5, 5, 4, 6, 7, 6, 9, 5, 6, 8, 2, 8
Offset: 0

Views

Author

Keywords

Comments

a(33) is the last zero in this sequence, cf. the link to Mathematics Stack Exchange and also A080673(n) for the largest index k with a(k)=n. - M. F. Hasler, May 30 2014
First occurrence of k beginning with 0: 0, 5, 20, 29, 62, 53, 80, 77, 91, 101, ..., (A080654). - Robert G. Wilson v, May 30 2014

Crossrefs

Column k=5 of A243148.

Programs

  • Maple
    b:= proc(n, i, t) option remember; `if`(n=0, `if`(t=0, 1, 0),
          `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(i^2>n, 0, b(n-i^2, i, t-1))))
        end:
    a:= n-> b(n, isqrt(n), 5):
    seq(a(n), n=0..120);  # Alois P. Heinz, May 30 2014
  • Mathematica
    f[n_] := Block[{c = Range@ Sqrt@ n^2}, Length@ IntegerPartitions[n, {5}, c]]; Array[f, 105, 0] (* Robert G. Wilson v, May 30 2014 *)
    b[n_, i_, t_] := b[n, i, t] = If[n==0, If[t==0, 1, 0], If[i<1 || t<1, 0, b[n, i-1, t] + If[i^2>n, 0, b[n-i^2, i, t-1]]]]; a[n_] := b[n, Sqrt[n] // Floor, 5]; Table[a[n], {n, 0, 120}] (* Jean-François Alcover, Oct 12 2015, after Alois P. Heinz *)
  • PARI
    A025429(n)=sum(d=sqrtint(max(n, 5)\5), sqrtint(max(n-4, 0)), nn=n-d^2; sum(a=sqrtint(max(nn-d^2, 4)\4), min(sqrtint(max(nn-3, 0)),d), sum(b=sqrtint((nn-a^2)\3-1)+1, min(sqrtint(nn-a^2-2), a), sum(c=sqrtint((t=nn-a^2-b^2)\2-1)+1, min(sqrtint(t-1), b), issquare(t-c^2) )))) \\ M. F. Hasler, May 30 2014

Formula

a(n) = [x^n y^5] Product_{k>=1} 1/(1 - y*x^(k^2)). - Ilya Gutkovskiy, Apr 19 2019
a(n) = Sum_{l=1..floor(n/5)} Sum_{k=l..floor((n-1)/4)} Sum_{j=k..floor((n-k-l)/3)} Sum_{i=j..floor((n-j-k-l)/2)} A010052(i) * A010052(j) * A010052(k) * A010052(l) * A010052(n-i-j-k-l). - Wesley Ivan Hurt, Apr 19 2019

A287166 Smallest number with exactly n representations as a sum of 7 nonzero squares or 0 if no such number exists.

Original entry on oeis.org

7, 22, 31, 37, 45, 67, 55, 61, 69, 70, 79, 82, 94, 108, 85, 93, 103, 106, 111, 132, 109, 126, 139, 117, 147, 146, 130, 145, 144, 133, 153, 167, 141, 154, 160, 172, 159, 166, 187, 157, 177, 174, 175, 0, 178, 165
Offset: 1

Views

Author

Ilya Gutkovskiy, May 20 2017

Keywords

Examples

			a(1) = 7 because 7 is the smallest number with exactly 1 representation as a sum of 7 nonzero squares: 7 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2;
a(2) = 22 because 22 is the smallest number with exactly 2 representations as a sum of 7 nonzero squares: 22 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 4^2 = 1^2 + 1^2 + 2^2 + 2^2 + 2^2 + 2^2 + 2^2, etc.
		

Crossrefs

Formula

A025431(a(n)) = n for a(n) > 0.

A080673 Largest number with exactly n representations as sum of five positive squares (or 0 if no number with exactly n representations exists).

Original entry on oeis.org

33, 60, 105, 90, 132, 177, 145, 201, 225, 180, 297, 228, 213, 265, 345, 258, 305, 300, 393, 369, 465, 417, 385, 337, 420, 425, 513, 537, 409, 473, 449, 585, 561, 545, 481, 505, 633, 540, 528, 705, 593, 462, 665, 681, 617, 825, 564, 753, 548, 689, 777, 713
Offset: 0

Views

Author

Rainer Rosenthal, Mar 02 2003

Keywords

Comments

a(0) = 33 has been asked as a riddle by Gerhard Woeginger in de.rec.denksport.
There is no number <= 10^6 that is the sum of five positive squares in exactly 188 ways. - Donovan Johnson, Aug 15 2013
Donovan Johnson's exhaustive search in fact shows that a(188) is undefined / should be assigned the default value 0. Hagen von Eitzen, Jun 05 2014
In what sense the search is exhaustive? Is any of the 0's of the b-file proved? - M. F. Hasler, Oct 27 2017

Examples

			A known result says a(0) = 33, since there is no representation of 33 as sum of 5 positive squares.
a(1) = 60 is the largest number allowing exactly one such representation.
		

Crossrefs

Programs

  • Mathematica
    max = 1000; m = Ceiling[Sqrt[max]]; xx = Array[x, 6, 0]; x[0] = 1; iter = Sequence @@ Thread[{Rest[xx], Most[xx], m}]; representations = Table[ Rest[xx] . Rest[xx], Evaluate[iter]] // Flatten // Sort // Split // Select[#, First[#] <= max &] &; counts = {First[#], Length[#]} & /@ representations; a[0] = Complement[Range[max], counts[[All, 1]]] // Last; a[n_] := Select[counts, #[[2]] == n &] // Last // First; Table[a[n], {n, 0, 51}] (* Jean-François Alcover, Jul 12 2012 *)

Formula

a(n) = max { k | A025429(k) = n }. - M. F. Hasler, May 30 2014

Extensions

a(15)-a(51) from Donovan Johnson, Aug 23 2010
Definition adjusted to cope with otherwise undefined values and b-file extended by Hagen von Eitzen, Jun 04 2014

A287165 Smallest number with exactly n representations as a sum of 6 nonzero squares or 0 if no such number exists.

Original entry on oeis.org

6, 21, 30, 36, 63, 54, 60, 87, 78, 81, 84, 111, 102, 117, 108, 116, 126, 129, 134, 137, 132, 150, 172, 165, 161, 156, 177, 164, 195, 191, 182, 213, 180, 188, 198, 0, 204, 206, 215, 222, 243, 212, 251, 262, 233, 230
Offset: 1

Views

Author

Ilya Gutkovskiy, May 20 2017

Keywords

Examples

			a(1) = 6 because 6 is the smallest number with exactly 1 representation as a sum of 6 nonzero squares: 6 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2;
a(2) = 21 because 21 is the smallest number with exactly 2 representations as a sum of 6 nonzero squares: 21 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 4^2 = 1^2 + 2^2 + 2^2 + 2^2 + 2^2 + 2^2, etc.
		

Crossrefs

Formula

A025430(a(n)) = n for a(n) > 0.

A287167 Smallest number with exactly n representations as a sum of 8 nonzero squares or 0 if no such number exists.

Original entry on oeis.org

8, 23, 35, 32, 46, 58, 72, 56, 62, 70, 71, 79, 80, 83, 88, 89, 91, 86, 103, 94, 109, 104, 107, 112, 113, 110, 122, 119, 126, 121, 118, 144, 0, 128, 131, 136, 137, 153, 143, 139, 149, 134, 0, 0, 142, 152, 164, 154
Offset: 1

Views

Author

Ilya Gutkovskiy, May 20 2017

Keywords

Examples

			a(1) = 8 because 8 is the smallest number with exactly 1 representation as a sum of 8 nonzero squares: 8 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2;
a(2) = 23 because 23 is the smallest number with exactly 2 representations as a sum of 8 nonzero squares: 23 = 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 4^2 = 1^2 + 1^2 + 1^2 + 2^2 + 2^2 + 2^2 + 2^2 + 2^2, etc.
		

Crossrefs

Formula

A025432(a(n)) = n for a(n) > 0.

A243077 Numbers missing from A025429 (number of partitions of n into 5 nonzero squares).

Original entry on oeis.org

188, 259, 304, 308, 372, 394, 483, 497, 594, 634, 685, 705, 722, 729, 740, 750, 756, 766, 780, 782, 834, 850, 864, 884, 885, 888, 922, 925, 946, 955, 956, 1016, 1026, 1048, 1069, 1070, 1071, 1080, 1082, 1108, 1134, 1140, 1154, 1159, 1160, 1161, 1187, 1198, 1266, 1268
Offset: 1

Views

Author

M. F. Hasler, May 30 2014 and Hagen von Eitzen, Jun 05 2014

Keywords

Comments

For these indices, A080654 and A080673 are ill-defined. Stated another way, a(n) is the n-th index where A080654 and A080673 default to 0.

Examples

			a(1)=188 because all the values 0, 1, ..., 187 appear somewhere in A025429, but 188 doesn't.
		

Crossrefs

Extensions

Edited by N. J. A. Sloane, Jun 06 2014
Showing 1-6 of 6 results.