OFFSET
1,3
COMMENTS
Conjecture: (i) a(n) > 0 for all n > 0, and the only values of n >= 1000 with a(n) = 1 are 1000, 1052, 1472, 1675, 1967, 4787, 4822, 11962.
(ii) For any positive integer n, we can write 6*n+3 as p^2 + 2*q^2 + 3*r^2, where p is prime, and q and r are integers.
LINKS
Zhi-Wei Sun, Table of n, a(n) for n = 1..10000
Zhi-Wei Sun, Restricted sums of four squares, arXiv:1701.05868 [math.NT], 2017.
EXAMPLE
a(1) = 1 since 4*1+1 = 2^2 + 1^2 + 8*0^2 with 2 prime.
a(2) = 1 since 4*2+1 = 3^2 + 0^2 + 8*0^2 with 3 prime.
a(4) = 1 since 4*4+1 = 3^2 + 0^2 + 8*1^2 with 3 prime.
a(16) = 1 since 4*16+1 = 7^2 + 4^2 + 8*0^2 with 7 prime.
a(17) = 1 since 4*17+1 = 5^2 + 6^2 + 8*1^2 with 5 prime.
a(4787) = 1 since 4*4787+1 = 31^2 + 126^2 + 8*17^2 with 31 prime.
a(4822) = 1 since 4*4822+1 = 29^2 + 4^2 + 8*48^2 with 29 prime.
a(11962) = 1 since 4*11962+1 = 109^2 + 160^2 + 8*36^2 with 109 prime.
MATHEMATICA
SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
tab={}; Do[r=0; Do[If[PrimeQ[p]&&SQ[4n+1-p^2-8q^2], r=r+1], {p, 2, Sqrt[4n+1]}, {q, 0, Sqrt[(4n+1-p^2)/8]}];
tab=Append[tab, r]; Continue, {n, 1, 80}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Zhi-Wei Sun, Aug 16 2017
STATUS
approved