A345356 Numbers k coprime to 30 such that ceiling(sqrt(k))^2 - k is a square.
1, 49, 77, 91, 121, 143, 169, 187, 209, 221, 247, 289, 299, 323, 361, 391, 437, 493, 529, 551, 589, 667, 713, 841, 851, 899, 961, 1073, 1147, 1189, 1247, 1271, 1333, 1369, 1457, 1517, 1591, 1681, 1739, 1763, 1813, 1849, 1927, 1961, 2009, 2021
Offset: 1
Examples
For k=77, ceiling(sqrt(k)) is 9, so we evaluate 9^2 - 77 = 4, which is a square, so 77 is a term. Let k=97, 100 - 97 = 3 is not a square and is not a term.
Programs
-
Mathematica
Select[Range[2000], CoprimeQ[#, 30] && IntegerQ @ Sqrt[Ceiling[Sqrt[#]]^2 - #] &] (* Amiram Eldar, Jun 23 2021 *)
-
PARI
genit(minn=1,maxx)={arr=List();forstep(w=minn,maxx,2,if(w%5==0||w%6==3,next);z=sqrtint(w-1)+1;if(issquare(z^2-w)>0,listput(arr,w);next));arr}
Comments