OFFSET
1,2
COMMENTS
REFERENCES
M. Hall, Jr., Combinatorial Theory, Theorem 12.3.2.
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 1..10000
R. H. Bruck and H. J. Ryser, The nonexistence of certain projective planes, Canad. J. Math., 1 (1949), 88-93.
MATHEMATICA
max = 225; Flatten[ Table[ a^2 + b^2, {a, 0, Sqrt[max]}, {b, a, Sqrt[max - a^2]}], 1] // Union // Select[#, (1 <= Mod[#, 4] <= 2)& ]& (* Jean-François Alcover, Sep 13 2012 *)
With[{max=15}, Select[Select[Total/@Tuples[Range[0, max]^2, 2], MemberQ[ {1, 2}, Mod[ #, 4]]&]//Union, #<=max^2&]] (* Harvey P. Dale, Jan 14 2017 *)
PROG
(Haskell)
a046711 n = a046711_list !! (n-1)
a046711_list = [x | x <- a042963_list, a000161 x > 0]
-- Reinhard Zumkeller, Aug 16 2011
(Python)
from itertools import count, islice
from sympy import factorint
def A046711_gen(): # generator of terms
return filter(lambda n:0 < n & 3 < 3 and all(p & 3 != 3 or e & 1 == 0 for p, e in factorint(n).items()), count(0))
CROSSREFS
KEYWORD
nonn,easy,nice
AUTHOR
EXTENSIONS
More terms from James A. Sellers
STATUS
approved