Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #30 Jun 15 2021 15:09:46
%S 5,17,1277,4217,21587,91127,103967,113147,122027,236867,342047,422087,
%T 524957,560477,626597,754967,797567,909317,997097,1322147,1493717,
%U 1698857,1748027,1762907,2144477,2158577,2228507,2398157,2580647,2615957
%N Initial members of prime sextuples (p, p+2, p+12, p+14, p+24, p+26).
%C This sequence is primes p for which there exist three twin prime pairs (p, p+2), (p+12, p+14) and (p+24, p+26).
%C Excluding 5, this is a subsequence of each of the following: A128468 (a(n)=30n+17). A039949 (Primes of the form 30n-13), A181605 (twin primes ending in 7).
%C Note that not in all cases (p, p+2, p+12, p+14, p+24, p+26) are consecutive primes; the first p's for which (p, p+2, p+12, p+14, p+24, p+26) are consecutive primes are 4217, 21587, 91127, 103967, 236867, 342047, 422087, 560477, 797567, 909317, 1322147, 1493717, 1748027, 1762907, 2144477, 2158577, 2228507, 2615957 (not in OEIS). - _Zak Seidov_, May 16 2017
%H Karl V. Keller, Jr., <a href="/A253624/b253624.txt">Table of n, a(n) for n = 1..10000</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/TwinPrimes.html">Twin Primes</a>
%H Wikipedia, <a href="http://www.wikipedia.org/wiki/Twin_prime">Twin prime</a>
%e For p = 17, the numbers 17, 19, 29, 31, 41, 43 are primes.
%p select(t -> andmap(isprime, [t,t+2,t+12,t+14,t+24,t+26]),
%p [5, seq(30*k+17,k=0..10^5)]); # _Robert Israel_, Jan 07 2015
%t Select[Prime@ Range[2*10^5], Times @@ Boole@ PrimeQ[# + {2, 12, 14, 24, 26}] == 1 &] (* _Michael De Vlieger_, May 16 2017 *)
%t Select[Prime[Range[200000]],AllTrue[#+{2,12,14,24,26},PrimeQ]&] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Jun 15 2021 *)
%o (Python)
%o from sympy import isprime
%o for n in range(1,10000001,2):
%o if isprime(n) and isprime(n+2) and isprime(n+12) and isprime(n+14) and isprime(n+24) and isprime(n+26): print(n,end=', ')
%o (Python)
%o from sympy import isprime, primerange
%o def aupto(limit):
%o alst = []
%o for p in primerange(2, limit+1):
%o if all(map(isprime, [p+2, p+12, p+14, p+24, p+26])): alst.append(p)
%o return alst
%o print(aupto(3*10**6)) # _Michael S. Branicky_, May 17 2021
%Y Cf. A077800 (twin primes), A128468, A039949, A181605.
%K nonn
%O 1,1
%A _Karl V. Keller, Jr._, Jan 06 2015