OFFSET
1,1
COMMENTS
Equivalently, primes p such that p, p+4, p+6, p+10 and p+16 are consecutive primes.
All terms = {7, 13} mod 30. - Muniru A Asiru, Aug 21 2017
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000 (terms 1..1000 from R. J. Mathar)
R. J. Mathar, Table of Prime Gap Constellations.
EXAMPLE
37 is in the sequence since 37, 41 = 37 + 4, 43 = 37 + 6, 47 = 37 + 10 and 53 = 37 + 16 are consecutive primes.
MAPLE
for i from 1 to 10^7 do if ithprime(i+1)=ithprime(i)+4 and ithprime(i+2)=ithprime(i)+6 and ithprime(i+3)=ithprime(i)+10 and ithprime(i+4)=ithprime(i)+16 then print(ithprime(i)); fi; od; # Muniru A Asiru, Aug 21 2017
MATHEMATICA
With[{s = Differences@ Prime@ Range[10^5]}, Prime[SequencePosition[s, {4, 2, 4, 6}][[All, 1]]]] (* Michael De Vlieger, Aug 21 2017 *)
PROG
(GAP)
K:=2*10^7+1;; # to get all terms <= K.
P:=Filtered([1, 3..K], IsPrime);; I:=[4, 2, 4, 6];;
P1:=List([1..Length(P)-1], i->P[i+1]-P[i]);;
P2:=List([1..Length(P)-Length(I)], i->[P1[i], P1[i+1], P1[i+2], P1[i+3]]);;
P3:=List(Positions(P2, I), i->P[i]); # Muniru A Asiru, Aug 21 2017
(PARI) lista(nn) = forprime(p=3, nn, if(nextprime(p+1)==p+4 && nextprime(p+5)==p+6 && nextprime(p+7)==p+10 && nextprime(p+11)==p+16, print1(p, ", "))); \\ Altug Alkan, Aug 21 2017
(PARI) list(lim) = {my(p1 = 2, p2 = 3, p3 = 5, p4 = 7); forprime(p5 = 11, lim, if(p2 - p1 == 4 && p3 - p2 == 2 && p4 - p3 == 4 && p5 - p4 == 6, print1(p1, ", ")); p1 = p2; p2 = p3; p3 = p4; p4 = p5); } \\ Amiram Eldar, Feb 21 2025
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Dec 19 2002
EXTENSIONS
Edited by Dean Hickerson, Dec 20 2002
STATUS
approved