OFFSET
0,2
COMMENTS
If n<0, then a(n)=0. If n>0, then a(n) is even since (-x, -y, -z) is a solution if (x, y, z) is.
Rouse [2014] conjectures that the ternary quadratic form x^2 + 2y^2 + 5z^2 + xz represents all positive odd integers.
If n == 10, 26, 40, 42 or 58 (mod 64), or n == 160 (mod 256), then a(n) = 0. - Robert Israel, Jun 18 2019
LINKS
Robert Israel, Table of n, a(n) for n = 0..10000
J. Rouse, Quadratic forms representing all odd positive integers Amer. J. Math, 136 (2014), no. 6, 1693-1745.
K. S. Williams, Eveything You Wanted to Know about ax^2+by^2+cz^2+dt^2 But Were Afraid To Ask, Amer. Math. Monthly, Vol. 125, No. 9, (2018), 797-810. See page 803.
EXAMPLE
G.f. = 1 + 2*x + 2*x^2 + 4*x^3 + 2*x^4 + 4*x^5 + 4*x^6 + 12*x^7 + ...
MAPLE
N:= 100: # for a(0)..a(N)
V:= Array(0..N):
for z from 0 to floor(sqrt(4*N/19)) do
if z = 0 then mz:= 1 else mz:= 2 fi;
for y from 0 to floor(sqrt((N - 19/4*z^2)/2)) do
if y = 0 then my:= 1 else my:= 2 fi;
r:= sqrt(N - 2*y^2 - 19/4*z^2);
for x from ceil(-r -z/2) to floor(r-z/2) do
v:= x^2 + 2*y^2 + 5*z^2 + x*z;
V[v]:= V[v] + my*mz;
od
od
od:
convert(V, list); # Robert Israel, Jun 18 2019
MATHEMATICA
a[ n_] := Length @ FindInstance[ x^2 + 2 y^2 + 5 z^2 + x z == n, {x, y, z}, Integers, 10^8];
PROG
(PARI) {a(n) = if( n<1, n==0, 2*qfrep([4, 0, 0; 0, 2, 1; 0, 1, 10], 2*n)[2*n])};
CROSSREFS
KEYWORD
nonn
AUTHOR
Michael Somos, Jan 12 2019
STATUS
editing