OFFSET
0,2
COMMENTS
Conjecture: a(n) > 0 for all n = 0,1,2,....
In the latest version of arXiv:1605.03074, the authors showed that any natural number can be written as x^2 + y^2 + z^2 + w^2 with x,y,z,w integers such that x + y + z + w is a cube (or a square).
For more conjectural refinements of Lagrange's four-square theorem, see the author's preprint arXiv:1604.06723.
LINKS
Zhi-Wei Sun, Table of n, a(n) for n = 0..10000
Yu-Chen Sun and Zhi-Wei Sun, Two refinements of Lagrange's four-square theorem, arXiv:1605.03074 [math.NT], 2016.
Zhi-Wei Sun, Refining Lagrange's four-square theorem, arXiv:1604.06723 [math.GM], 2016.
EXAMPLE
a(12) = 1 since 12 = 3^2 + 1^2 + (-1)^2 + (-1)^2 with 3 - 1 + (-1) + (-1) = 0^3.
a(17) = 1 since 17 = 2^2 + 0^2 + 2^2 + (-3)^2 with 2 - 0 + 2 + (-3) = 1^3.
a(28) = 1 since 28 = 3^2 + 1^2 + 3^2 + 3^2 with 3 - 1 + 3 + 3 = 2^3.
a(29) = 1 since 29 = 3^2 + 0^2 + 2^2 + (-4)^2 with 3 - 0 + 2 + (-4) = 1^3.
a(71) = 1 since 71 = 5^2 + 1^2 + 3^2 + (-6)^2 with 5 - 1 + 3 + (-6) = 1^3.
a(149) = 1 since 149 = 8^2 + 0^2 + 2^2 + (-9)^2 with 8 - 0 + 2 + (-9) = 1^3.
a(188) = 1 since 188 = 13^2 + 3^2 + 1^2 + (-3)^2 with 13 - 3 + 1 + (-3) = 2^3.
a(284) = 1 since 284 = 15^2 + 5^2 + 3^2 + (-5)^2 with 15 - 5 + 3 + (-5) = 2^3.
MATHEMATICA
SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
CQ[n_]:=CQ[n]=n>=0&&IntegerQ[n^(1/3)]
Do[r=0; Do[If[SQ[n-x^2-y^2-z^2]&&CQ[x-y+(-1)^j*z+(-1)^k*Sqrt[n-x^2-y^2-z^2]], r=r+1], {y, 0, (n/2)^(1/2)}, {x, y, Sqrt[n-y^2]}, {z, 0, Min[x, Sqrt[(n-x^2-y^2)/2]]}, {j, 0, Min[1, z]}, {k, 0, Min[1, Sqrt[n-x^2-y^2-z^2]]}];
Print[n, " ", r]; Continue, {n, 0, 80}]
CROSSREFS
Cf. A000118, A000290, A000578, A260625, A261876, A262357, A267121, A268197, A268507, A269400, A270073, A270969, A271510, A271513, A271518, A271608, A271665, A271714, A271721, A271724, A271775, A271778, A271824, A272084, A272332, A272351, A272620, A272888, A272977, A273021, A273107, A273108, A273110, A273134, A273278, A273294, A273302, A273404, A273429, A273432, A273568.
KEYWORD
nonn
AUTHOR
Zhi-Wei Sun, May 22 2016
STATUS
approved