OFFSET
1,1
COMMENTS
Primes p such that p+6 and p+12 are also primes.
LINKS
Lei Zhou, Table of n, a(n) for n = 1..10000
Eric Weisstein's World of Mathematics, Prime Triplet
MATHEMATICA
triq[p_] := And[PrimeQ[p + 6], PrimeQ[p + 12]]; Select[Prime[Range[1000]], triq] (* Ben Branman, Sep 03 2012 *)
nrpQ[n_]:=AllTrue[Rest[NestList[#+6&, n, 2]], PrimeQ]; Select[Prime[Range[ 300]], nrpQ] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jan 27 2021 *)
PROG
(Magma) [n: n in [0..1000] | IsPrime(n) and IsPrime(n+6) and IsPrime(n+12)] // Vincenzo Librandi, Nov 20 2010
CROSSREFS
KEYWORD
nonn
AUTHOR
STATUS
approved