A250310 Numbers whose squares are of the form x^2 + y^2 + 3 where x >= y >= 0 (repetitions omitted).
2, 4, 8, 10, 14, 20, 22, 26, 32, 34, 40, 44, 46, 52, 56, 58, 64, 68, 74, 80, 86, 88, 92, 94, 98, 100, 110, 112, 118, 124, 128, 130, 134, 136, 140, 142, 146, 148, 152, 158, 164, 172, 178, 184, 190, 194, 202, 206, 208, 212, 218, 220, 230, 238, 242, 244, 250, 254, 256, 266, 268, 274, 278, 290, 296, 298
Offset: 1
Keywords
Examples
a(4) = 10 as 10^2 - 3 = 9^2 + 4^2 and 10 is the 4th such occurrence.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000
- Frank M. Jackson and Stalislav Takhaev, Heronian Triangles of Class K: Congruent Incircles Cevian Perspective, Forum Geom., 15 (2015) 5-12.
Programs
-
Maple
filter:= proc(n) local F; F:= ifactors(n^2-3)[2]; andmap(t -> t[1] mod 4 <> 3 or t[2]::even, F) end proc: select(filter, [seq(i,i=2..1000,2)]); # Robert Israel, Feb 05 2019
-
Mathematica
lst = {}; Do[If[IntegerQ[k=Sqrt[m^2+n^2+3]], AppendTo[lst, k]], {m, 0, 1000}, {n, 0, m}]; Union@lst
-
Python
from itertools import count, islice from sympy import factorint def A250310_gen(): # generator of terms return filter(lambda n:all(p & 3 != 3 or e & 1 == 0 for p, e in factorint(n**2-3).items()),count(2)) A250310_list = list(islice(A250310_gen(),30)) # Chai Wah Wu, Jun 27 2022
Extensions
Edited by Robert Israel, Feb 05 2019
Comments