Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #38 Jan 19 2021 21:01:02
%S 1,3,3,1,1,3,3,1,0,3,4,2,2,3,2,2,4,6,3,1,4,3,2,1,0,6,8,5,2,4,7,3,3,4,
%T 7,5,3,6,6,2,0,9,7,1,1,4,6,2,2,4,9,7,4,5,7,7,2,6,6,4,3,7,11,3,1,8,15,
%U 5,5,6,6,4,2,6,6,9,5,7,5,4,4,12,12,7,6,6,8,7,2,6,12,3,6,8,8,3,3,9,10,7,6
%N Number of ways to write n as x^2 + y^2 + z^2 + w^2 with x + 3*y + 4*z a 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, 43).
%C We have verified this for n up to 3*10^6. The conjecture is similar to the author's 1-3-5 conjecture (cf. A271518).
%C In his 2017 JNT paper, the author conjectured that any natural number not of the form 2^(4k+2)*7 (k = 0,1,...) can be written as w^2 + x^2 + y^2 + z^2 with w + 2*x + 3*y + 5*z a square, where w, x, y, z are nonnegative integers.
%C See also A338019 for a similar conjecture.
%H Zhi-Wei Sun, <a href="/A335624/b335624.txt">Table of n, a(n) for n = 0..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.
%p a(4) = 1, and 4 = 0^2 + 0^2 + 0^2 + 2^2 with 0 + 3*0 + 4*0 = 0^2.
%p a(7) = 1, and 7 = 2^2 + 1^2 + 1^2 + 1^2 with 2 + 3*1 + 4*1 = 3^2.
%p a(44) = 1, and 44 = 3^2 + 3^2 + 1^2 + 5^2 with 3 + 3*3 + 4*1 = 4^2.
%p a(328) = 1, and 328 = 8^2 + 16^2 + 2^2 + 2^2 with 8 + 3*16 + 4*2 = 8^2.
%p a(776) = 1, and 776 = 24^2 + 0^2 + 10^2 + 10^2 with 24 + 3*0 + 4*10 = 8^2.
%t SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
%t tab={};Do[r=0;Do[If[SQ[n-x^2-y^2-z^2]&&SQ[x+3y+4z],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,0,100}];Print[tab]
%Y Cf. A000118, A000290, A271518, A338019.
%K nonn
%O 0,2
%A _Zhi-Wei Sun_, Oct 08 2020