OFFSET
1,1
EXAMPLE
31 is prime and (31^2+31+1)^2+(31^2+31+1)+1 = 987043 is prime. Thus, 31 is a member of this sequence.
PROG
(Python)
import sympy
from sympy import isprime
{print(n) for n in range(10**4) if isprime(n) and isprime((n**2+n+1)**2+(n**2+n+1)+1)}
(PARI)
s=[]; forprime(p=2, 4000, if(isprime(p^4+2*p^3+4*p^2+3*p+3), s=concat(s, p))); s \\ Colin Barker, Feb 07 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
Derek Orr, Feb 06 2014
STATUS
approved