A158238 Primes p such that (p-7)/8 and 8p + 7 are both prime.
23, 47, 863, 1103, 1439, 1583, 1823, 2879, 3359, 4943, 5279, 6719, 7823, 8783, 9743, 11279, 11903, 12479, 13103, 16703, 18719, 19583, 20399, 20879, 21503, 23279, 23663, 25343, 26399, 27743, 29759, 33119, 35279, 38303, 39359, 39503, 41183
Offset: 1
Keywords
Links
- Harvey P. Dale, Table of n, a(n) for n = 1..1000
Crossrefs
Cf. A023231 Numbers n such that n and 8n + 7 are both prime.
Programs
-
Mathematica
Select[Prime[Range[5000]],AllTrue[{(#-7)/8,8#+7},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Mar 24 2015 *)
-
PARI
isok(p) = isprime(p) && isprime(8*p+7) && ((p % 8)==7) && isprime((p-7)/8); \\ Michel Marcus, Oct 16 2013
Formula
23, (23-7)/8=2, and 8*23+7=191 are all prime.