

A272620


Number of ordered ways to write n as w^2 + x^2 + y^2 + z^2 with w + x + y  z a square, where w is an integer and x,y,z are nonnegative integers with w <= x >= y <= z < x + y.


24



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



OFFSET

1,5


COMMENTS

Conjecture: a(n) > 0 for all n > 0.
In contrast, the author has proved that any natural number can be written as w^2 + x^2 + y^2 + z^2 with w,x,y,z integers such that x + y + z is a square. See arXiv:1604.06723.
YuChen Sun and the author proved in arXiv:1605.03074 that any nonnegative integer can be written as w^2 + x^2 + y^2 + z^2 with w,x,y,z integers such that w + x + y + z is a square.  ZhiWei Sun, May 10 2016


LINKS

ZhiWei Sun, Table of n, a(n) for n = 1..10000
YuChen Sun and ZhiWei Sun, Two refinements of Lagrange's foursquare theorem, arXiv:1605.03074 [math.NT], 2016.
ZhiWei Sun, Refining Lagrange's foursquare theorem, arXiv:1604.06723 [math.GM], 2016.
ZhiWei Sun, Refine Lagrange's foursquare theorem, a message to Number Theory List, April 26, 2016.


EXAMPLE

a(1) = 1 since 1 = 0^2 + 1^2 + 0^2 + 0^2 with 0 < 1 > 0 = 0 < 1 + 0 and 0 + 1 + 0  0 = 1^2.
a(2) = 1 since 2 = (1)^2 + 1^2 + 0^2 + 0^2 with 1 = 1 > 0 = 0 < 1 + 0 and 1 + 1 + 0  0 = 0^2.
a(3) = 1 since 3 = 0^2 + 1^2 + 1^2 + 1^2 with 0 < 1 = 1 = 1 < 1 + 1 and 0 + 1 + 1  1 = 1^2.
a(4) = 1 since 4 = (1)^2 + 1^2 + 1^2 + 1^2 with 1 = 1 = 1 = 1 < 1 + 1 and 1 + 1 + 1  1 = 0^2.
a(6) = 1 since 6 = (1)^2 + 2^2 + 0^2 + 1^2 with 1 < 2 > 0 < 1 < 2 + 0 and 1 + 2 + 0  1 = 0^2.
a(7) = 1 since 7 = (1)^2 + 2^2 + 1^2 + 1^2 with 1 < 2 > 1 = 1 < 2 + 1 and 1 + 2 + 1  1 = 1^2.
a(9) = 1 since 9 = 0^2 + 2^2 + 1^2 + 2^2 with 0 < 2 > 1 < 2 < 2 + 1 and 0 + 2 + 1  2 = 1^2.
a(11) = 1 since 11 = (1)^2 + 3^2 + 0^2 + 1^2 with 1 < 3 > 0 < 1 < 3 + 0 and 1 + 3 + 0  1 = 1^2.
a(12) = 1 since 12 = 1^2 + 3^2 + 1^2 + 1^2 with 1 < 3 > 1 = 1 < 3 + 1 and 1 + 3 + 1  1 = 2^2.
a(17) = 1 since 17 = 0^2 + 2^2 + 2^2 + 3^2 with 0 < 2 = 2 < 3 < 2 + 2 and 0 + 2 + 2  3 = 1^2.
a(19) = 1 since 19 = 0^2 + 3^2 + 1^2 + 3^2 with 0 < 3 > 1 < 3 < 3 + 1 and 0 + 3 + 1  3 = 1^2.
a(23) = 1 since 23 = (1)^2 + 3^2 + 2^2 + 3^2 with 1 < 3 > 2 < 3 < 3 + 2 and 1 + 3 + 2  3 = 1^2.
a(29) = 1 since 29 = 0^2 + 3^2 + 2^2 + 4^2 with 0 < 3 > 2 < 4 < 3 + 2 and 0 + 3 + 2  4 = 1^2.
a(31) = 1 since 31 = (2)^2 + 3^2 + 3^2 + 3^2 with 2 < 3 = 3 = 3 < 3 + 3 and 2 + 3 + 3  3 = 1^2.
a(37) = 1 since 37 = (1)^2 + 4^2 + 2^2 + 4^2 with 1 < 4 > 2 < 4 < 4 + 2 and 1 + 4 + 2  4 = 1^2.
a(92) = 1 since 92 = 3^2 + 5^2 + 3^2 + 7^2 with 3 < 5 > 3 < 7 < 5 + 3 and 3 + 5 + 3  7 = 2^2.
a(284) = 1 since 284 = 3^2 + 9^2 + 5^2 + 13^2 with 3 < 9 > 5 < 13 < 9 + 5 and 3 + 9 + 5  13 = 2^2.
a(572) = 1 since 572 = 3^2 + 11^2 + 9^2 + 19^2 with 3 < 11 > 9 < 19 < 11 + 9 and 3 + 11 + 9  19 = 2^2.


MATHEMATICA

SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]]
Do[r=0; Do[If[Sqrt[nx^2y^2z^2]<=x&&SQ[nx^2y^2z^2]&&SQ[x+yz+(1)^k*Sqrt[nx^2y^2z^2]], r=r+1], {y, 0, Sqrt[n/3]}, {x, y, Sqrt[ny^2]}, {z, y, Min[x+y1, Sqrt[nx^2y^2]]}, {k, 0, Min[1, Sqrt[nx^2y^2z^2]]}]; Print[n, " ", r]; Continue, {n, 1, 80}]


CROSSREFS

Cf. A000118, A000290, A260625, A261876, A262357, A267121, A268507, A269400, A271510, A271513, A271518, A271608, A271665, A271714, A271721, A271724, A271775, A271778, A271824, A272084, A272332, A272351.
Sequence in context: A102190 A138650 A266685 * A304080 A137843 A130194
Adjacent sequences: A272617 A272618 A272619 * A272621 A272622 A272623


KEYWORD

nonn


AUTHOR

ZhiWei Sun, May 03 2016


EXTENSIONS

Rick L. Shepherd, May 27 2016: I checked all the statements in each example.


STATUS

approved



