OFFSET
1,1
COMMENTS
Primes in the sequence A236477.
LINKS
Daniel Starodubtsev, Table of n, a(n) for n = 1..10000
EXAMPLE
419 is prime and 419^3 - 419 + 1 = 73559641 is prime. So 419 is a member of this sequence.
MATHEMATICA
Select[Prime[Range[300]], PrimeQ[#^3-#+1]&] (* Harvey P. Dale, Oct 30 2021 *)
PROG
(Python)
import sympy
from sympy import isprime
{print(n) for n in range(10**4) if isprime(n) and isprime(n**3-n+1)}
(PARI)
s=[]; forprime(p=2, 2000, if(isprime(p^3-p+1), s=concat(s, p))); s \\ Colin Barker, Jan 27 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
Derek Orr, Jan 26 2014
EXTENSIONS
More terms from Colin Barker, Jan 27 2014
STATUS
approved