A268752 Cubefree numbers n such that n^2 + 1 is prime.
1, 2, 4, 6, 10, 14, 20, 26, 36, 66, 74, 84, 90, 94, 110, 116, 124, 126, 130, 134, 146, 150, 156, 170, 180, 204, 206, 210, 230, 236, 260, 284, 300, 306, 314, 326, 340, 350, 386, 396, 406, 420, 430, 436, 444, 466, 470, 474, 490, 556, 570, 634, 636, 644, 646, 654
Offset: 1
Keywords
Examples
a(5) = 10 = 2 * 5 that is cubefree. 10^2 + 1 = 101 which is a prime. a(6) = 14 = 2 * 7 that is cubefree. 14^2 + 1 = 197 which is a prime.
Links
- K. D. Bajpai, Table of n, a(n) for n = 1..10000
Programs
-
Maple
select(t -> isprime(t^2+1) and max(map(f->f[2],ifactors(t)[2]))<=2, [$1..1000]); # Robert Israel, Feb 12 2016
-
Mathematica
Select[Range[1000], FreeQ[FactorInteger[#], {, k /; k > 2}] && PrimeQ[#^2 + 1] &] Select[Range[1000],Max[FactorInteger[#][[;;,2]]]<3&&PrimeQ[#^2+1]&] (* Harvey P. Dale, May 30 2023 *)
-
PARI
for(n=1, 1000, f = factor(n)[, 2];if ((#f == 0) || vecmax(f) < 3,if (isprime(n^2+1), print1(n, ", "))));
Comments