

A191091


Least number of squares required when writing n as a sum of squares with the smallest square as large as possible.


3



1, 2, 3, 1, 2, 3, 4, 2, 1, 2, 3, 3, 2, 3, 4, 1, 3, 2, 3, 2, 4, 3, 4, 3, 1, 4, 3, 4, 2, 5, 4, 2, 3, 2, 5, 1, 4, 3, 6, 2, 2, 4, 3, 3, 2, 5, 4, 3, 1, 2, 5, 2, 2, 3, 6, 3, 3, 2, 3, 4, 2, 3, 4, 1, 2, 3, 3, 3, 3, 3, 4, 2, 4, 2, 3, 4, 3, 3, 4, 2, 1, 4, 3, 4, 2, 3, 4
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,2


COMMENTS

The smallest value in the sum is A191090. All sums have at most 6 terms for n <= 1000. Is this the largest possible value? For n up to 1000, only 39, 55, 143, 543, and 564 need 6 terms.


LINKS

T. D. Noe, Table of n, a(n) for n = 1..1000


EXAMPLE

The sum for 30 gives the first sum having 5 terms: 4 + 4 + 4 + 9 + 9.


MATHEMATICA

Table[s=DeleteCases[#, 0]& /@ PowersRepresentations[n, 11, 2]; t=Last[Union[First /@ Union /@ s]]; Min @@ Length /@ Select[s, #[[1]] == t &], {n, 100}]


CROSSREFS

Cf. A191090, A193018.
Sequence in context: A194050 A316340 A002828 * A098066 A096436 A053610
Adjacent sequences: A191088 A191089 A191090 * A191092 A191093 A191094


KEYWORD

nonn


AUTHOR

T. D. Noe, Jul 21 2011


STATUS

approved



