OFFSET
1,1
COMMENTS
All the terms in this sequence are congruent to 0 (mod 5).
Each term in this sequence yields two sets of cousin prime pairs i.e., for n = 435 -> {82312877, 82312873} and {1307, 1303}.
All terms are congruent to 15 mod 30. - Robert Israel, Feb 05 2016
LINKS
Robert Israel, Table of n, a(n) for n = 1..1000
EXAMPLE
435 is in the sequence because 435^3 + - 2 = 82312877, 82312873; 3*435 + - 2 = 1307, 1303 are all prime.
555 is in the sequence because 555^3 + - 2 = 170953877, 170953873; 3*555 + - 2 = 1667, 1663 are all prime.
MAPLE
select(n -> andmap(isprime, [n^3 + 2, n^3 - 2, 3*n + 2, 3*n - 2]), [seq(p, p=1.. 10^6)]);
MATHEMATICA
Select[Range[1000000], PrimeQ[#^3 + 2] && PrimeQ[#^3 - 2] && PrimeQ[3 # + 2] && PrimeQ[3 # - 2] &]
PROG
(PARI) for(n = 1, 1e5, if( isprime(n^3 + 2) && isprime(n^3 - 2) && isprime(3*n + 2) && isprime(3*n - 2), print1(n ", ")))
(Magma) [n : n in [1..1e5] | IsPrime(n^3 + 2) and IsPrime(n^3 - 2) and IsPrime(3*n + 2) and IsPrime(3*n - 2)];
CROSSREFS
KEYWORD
nonn
AUTHOR
K. D. Bajpai, Feb 05 2016
STATUS
approved