%I #33 Apr 14 2019 20:36:00
%S 0,4,31,28,52,82,90,135,130,162,198,202,252,234,210,346,306,322,423,
%T 370,330,418,390,462,378,490,598,450,546,618,522,594,642,682,570,770,
%U 714,690,762,906,738,630,1030,850,1035,978,858,954,810,1197,1146,882,1090,1206
%N Least sum of 4 nonzero squares in exactly n ways.
%C Conjecture: The sequence never becomes monotonic increasing. - _Jon Perry_, Nov 03 2012
%H Alois P. Heinz, <a href="/A025416/b025416.txt">Table of n, a(n) for n = 0..2000</a> (first 501 terms from T. D. Noe)
%H <a href="/index/Su#ssq">Index entries for sequences related to sums of squares</a>
%F {min k: A025428(k) = n}. - _R. J. Mathar_, Jun 15 2018
%e a(2) = 31 because 31 = 1 + 1 + 4 + 25 = 4 + 9 + 9 + 9 and no others.
%e a(3) = 28 because 28 = 1 + 1 + 1 + 25 = 1 + 9 + 9 + 9 = 4 + 4 + 4 + 16 and no others.
%e a(4) = 52 because 52 = 1 + 1 + 1 + 49 = 1 + 1 + 25 + 25 = 4 + 16 + 16 + 16 = 9 + 9 + 9 + 25 and no others.
%t nn = 40; t = Select[Flatten[Table[a^2 + b^2 + c^2 + d^2, {a, nn}, {b, a}, {c, b}, {d, c}]], # <= nn^2 + 3 &]; {t1, t2} = Transpose[Sort[Tally[t]]]; u = Union[t2]; c = Complement[Range[u[[-1]]], u]; If[c == {}, last = u[[-1]], last = c[[1]] - 1]; Join[{0}, Table[t1[[Position[t2, n, 1, 1][[1, 1]]]], {n, last}]] (* _T. D. Noe_, Nov 02 2012 *)
%K nonn
%O 0,2
%A _David W. Wilson_
%E 0th term added by _Jon Perry_, Nov 02 2012