A283867 Numbers n such that 30*n^2 - 1 and 30*n^2 + 1 are (twin) primes.
1, 3, 10, 14, 18, 38, 62, 73, 116, 118, 143, 183, 221, 232, 242, 330, 333, 413, 430, 455, 470, 496, 507, 533, 538, 556, 606, 622, 645, 675, 687, 701, 720, 777, 792, 819, 846, 879, 881, 895, 913, 1000, 1019, 1030, 1092, 1155, 1214, 1238, 1253, 1261, 1313, 1337, 1350, 1407, 1418, 1429, 1431
Offset: 1
Keywords
Examples
3 is in this sequence because 30*3^2 - 1 = 269 and 30*3^2 + 1 = 271 are twin primes.
Links
- Charles R Greathouse IV, Table of n, a(n) for n = 1..10000
Programs
-
Magma
[n: n in [1..1500] | IsPrime(30*n^2-1) and IsPrime(30*n^2+1)];
-
Mathematica
Select[Range@ 1431, PrimeQ[30*#^2 + 1] && PrimeQ[30*#^2 - 1] &] (* Indranil Ghosh, Mar 17 2017 *)
-
PARI
is(n)=isprime(30*n^2-1) && isprime(30*n^2+1) \\ Charles R Greathouse IV, Mar 17 2017
-
Python
from sympy import isprime [i for i in range(1, 1501) if isprime(30*i**2 - 1) and isprime(30*i**2 + 1)] # Indranil Ghosh, Mar 17 2017
Formula
a(n) >> n log^2 n. - Charles R Greathouse IV, Mar 17 2017