OFFSET
0,2
REFERENCES
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
D. Shanks and L. P. Schmid, Variations on a theorem of Landau. Part I, Math. Comp., 20 (1966), 551-569.
EXAMPLE
a(3)=6 since 2^3=8 and 1=1^2, 2=2*1^2, 3=1^2+2*1^2, 4=2^2, 6=2^2+2*1^2, 8=2*2^2.
PROG
(PARI) a(n)=if(n<0, 0, sum(k=1, 2^n, 0<sum(y=0, sqrtint(k\2), issquare(k-2*y^2))))
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved