A352170 Primes p such that p+4, 3*p+4 and 3*p+8 are also prime.
3, 13, 103, 223, 823, 2953, 7873, 11113, 11863, 13033, 13963, 16063, 22153, 23743, 24763, 27733, 30133, 31513, 34213, 35593, 39883, 41893, 43063, 50383, 51043, 54493, 62983, 65323, 66343, 68473, 71593, 72643, 87793, 88423, 98893, 101203, 106363, 110563, 127873, 134593, 136603, 158563, 164623, 165703
Offset: 1
Keywords
Examples
a(4) = 223 is a term because 223, 223+4 = 227, 3*223+4 = 673 and 3*223+8 = 677 are all prime.
Links
- Martin Ehrenstein, Table of n, a(n) for n = 1..10000
Programs
-
Maple
select(p -> isprime(p) and isprime(p+4) and isprime(3*p+4) and isprime(3*p+8), [3,seq(i,i=13..10^6,30)]);
-
Mathematica
Select[Range[200000], AllTrue[{#, # + 4, 3*# + 4, 3*# + 8}, PrimeQ] &] (* Amiram Eldar, Mar 07 2022 *)
-
Python
from sympy import sieve, isprime for p in sieve.primerange(0, 10**6): if(all(isprime(q) for q in [p+4, 3*p+4, 3*p+8])): print (p, end=", ") # Martin Ehrenstein, Mar 09 2022
Comments