login
Number of ways to write n as x^2 + y^2 + z^2 + w^2 with 3*x + 10*y + 36*z a positive square, where x, y, z, w are nonnegative integers.
2

%I #30 Jan 19 2021 21:01:17

%S 1,1,1,1,2,1,1,0,2,2,1,2,3,3,1,1,4,1,1,2,1,3,1,0,3,4,2,1,4,4,2,1,1,3,

%T 2,2,1,5,4,0,4,4,1,1,4,3,3,1,4,3,3,4,1,4,1,2,3,3,1,4,3,3,2,1,4,2,2,2,

%U 1,1,2,1,2,3,5,1,5,5,3,2,6,4,1,6,3,5,3,1,3,7,2,2,2,7,3,1,4,1,2,2

%N Number of ways to write n as x^2 + y^2 + z^2 + w^2 with 3*x + 10*y + 36*z a positive square, where x, y, z, w are nonnegative integers.

%C Conjecture: a(n) > 0 if n is not divisible by 8. Moreover, a(n) = 0 if and only if n has the form 2^(4k+3)*m (k >= 0 and m = 1, 3, 5, 61).

%C We have verified this for n up to 5*10^6. See also A335624 for a similar conjecture.

%H Zhi-Wei Sun, <a href="/A338019/b338019.txt">Table of n, a(n) for n = 1..10000</a>

%H Zhi-Wei Sun, <a href="http://dx.doi.org/10.1016/j.jnt.2016.11.008">Refining Lagrange's four-square theorem</a>, J. Number Theory 175(2017), 167-190. See also <a href="http://arxiv.org/abs/1604.06723">arXiv:1604.06723 [math.NT]</a>.

%H Zhi-Wei Sun, <a href="https://arxiv.org/abs/2010.05775">Sums of four squares with certain restrictions</a>, arXiv:2010.05775 [math.NT], 2020.

%e a(21) = 1, and 21 = 2^2 + 1^2 + 0^2 + 4^2 with 3*2 + 10*1 + 36*0 = 4^2.

%e a(98) = 1, and 98 = 6^2 + 7^2 + 3^2 + 2^2 with 3*6 + 10*7 + 36*3 = 14^2.

%e a(203) = 1, and 203 = 5^2 + 3^2 + 5^2 + 12^2 with 3*5 + 10*3 + 36*5 = 15^2.

%e a(760) = 1, and 760 = 0^2 + 18^2 + 20^2 + 6^2 with 3*0 + 10*18 + 36*20 = 30^2.

%t SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];

%t TQ[n_]:=TQ[n]=n>0&&SQ[n];

%t tab={};Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&TQ[3x+10y+36z],r=r+1],{x,0,Sqrt[n]},{y,0,Sqrt[n-x^2]},{z,0,Sqrt[n-x^2-y^2]}];

%t tab=Append[tab,r],{n,1,100}];Print[tab]

%Y Cf. A000118, A000290, A271518, A335624.

%K nonn

%O 1,5

%A _Zhi-Wei Sun_, Oct 08 2020