OFFSET
0,2
LINKS
Ray Chandler, Table of n, a(n) for n = 0..1438 (a(1439) exceeds 1000 digits).
Eric Weisstein's World of Mathematics, Circle Lattice Points
Eric Weisstein's World of Mathematics, Pythagorean Triple
MATHEMATICA
oneModFourPrimes[1] = 5;
oneModFourPrimes[n_] := oneModFourPrimes[n] = NestWhile[NextPrime, NextPrime[oneModFourPrimes[n - 1]], Mod[#, 4] != 1 & ];
factorizations[1, limit_] = {{}};
factorizations[n_, limit_] := factorizations[n, limit] = Join @@ Table[Prepend[#, d]& /@ factorizations[n/d, d], {d, Select[Rest[Divisors[n]], # <= limit & ]}];
leastHypotenuse[n_] := Min[(Times @@ (Array[oneModFourPrimes, Length[#]]^((# - 1)/2)) & ) /@ factorizations[2*n + 1, 2*n + 1]];
Array[leastHypotenuse, 30, 0]
(* Albert H. Mao, Jan 06 2012 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved