OFFSET
1,2
COMMENTS
LINKS
Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
EXAMPLE
37 is a term because 37 = 6^2 + 1 = 4^2 + 4*3 + 3^2.
MATHEMATICA
Select[Range[10^6], And[IntegerQ@Sqrt[# - 1], Resolve[Exists[{x, y}, Reduce[# == x^2 + x y + y^2, {x, y}, Integers]]]] &] (* Michael De Vlieger, Apr 01 2016 *)
PROG
(PARI) is(n) = #bnfisintnorm(bnfinit(z^2+z+1), n);
for(k=0, 2000, if(is(n=k^2+1), print1(n, ", ")));
CROSSREFS
KEYWORD
nonn
AUTHOR
Altug Alkan, Apr 01 2016
STATUS
approved