OFFSET
1,1
COMMENTS
This is a subsequence of A046132: Larger member p+4 of cousin primes (p, p+4).
LINKS
Abhiram R Devesh, Table of n, a(n) for n = 1..1000
EXAMPLE
p = 11 is in this sequence because p - 4 = 7 (prime) and p^3 - 4 = 1327 (prime).
p = 17 is in this sequence because p - 4 = 13 (prime) and p^3 - 4 = 4909 (prime).
PROG
(Python)
import sympy.ntheory as snt
n=5
while n>1:
....n1=n-4
....n2=((n**3)-4)
....##Check if n1 and n2 are also primes.
....if snt.isprime(n1)== True and snt.isprime(n2)== True:
........print(n, n1, n2)
....n=snt.nextprime(n)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Abhiram R Devesh, Jun 11 2014
STATUS
approved