OFFSET
1,2
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
EXAMPLE
2 is a term since 2 + 2^2 + 2^3 + 2^4 - 1 = 29 and 2 + 2^2 + 2^3 + 2^4 + 1 = 31 are twin primes.
MATHEMATICA
lst={}; Do[p=(n^1+n^2+n^3+n^4); If[PrimeQ[p-1]&&PrimeQ[p+1], AppendTo[lst, n]], {n, 8!}]; lst
PROG
(Magma) [n: n in [1..6*10^3] | IsPrime(n^4+n^3+n^2+n-1) and IsPrime(n^4+n^3+n^2+n+1)]; // Vincenzo Librandi, Dec 26 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Vladimir Joseph Stephan Orlovsky, Feb 01 2009
STATUS
approved