OFFSET
1,1
COMMENTS
Conjecture: the even members of this sequence are all numbers of the form
k*4^m for k in [9,17,29], m>= 1, or k*4^m for k in [34, 50, 54, 74, 86, 94], m>=0. - Robert Israel, Nov 03 2017
LINKS
Alois P. Heinz, Table of n, a(n) for n = 1..77 (first 71 terms from Robert Price)
Eric Weisstein's World of Mathematics, Square Number
FORMULA
{n: A025428(n) = 2}. - R. J. Mathar, Jun 15 2018
MAPLE
N:= 10000: # to get all terms <= N
T:= Vector(N):
for a from 1 to floor(sqrt(N/4)) do
for b from a to floor(sqrt((N-a^2)/3)) do
for c from b to floor(sqrt((N-a^2-b^2)/2)) do
for d from c to floor(sqrt(N-a^2-b^2-c^2)) do
m:= a^2+b^2+c^2+d^2;
T[m]:= T[m]+1;
od od od od:
select(i -> T[i] = 2, [$1..N]); # Robert Israel, Nov 03 2017
MATHEMATICA
M = 1000;
Clear[T]; T[_] = 0;
For[a = 1, a <= Floor[Sqrt[M/4]], a++,
For[b = a, b <= Floor[Sqrt[(M - a^2)/3]], b++,
For[c = b, c <= Floor[Sqrt[(M - a^2 - b^2)/2]], c++,
For[d = c, d <= Floor[Sqrt[M - a^2 - b^2 - c^2]], d++,
m = a^2 + b^2 + c^2 + d^2;
T[m] = T[m] + 1;
]]]];
Select[Range[M], T[#] == 2&] (* Jean-François Alcover, Mar 22 2019, after Robert Israel *)
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved