OFFSET
1,1
EXAMPLE
For n=3, d = 2*n = 6, d-pattern = {6, 12}, a(3) = 503, first corresponding prime triple is {503, 509, 521}.
MATHEMATICA
d[x_] := Prime[x+1]-Prime[x]; t=Table[0, {70}]; Do[s=d[n]/2; If[(d[n+1]==4*s)&&(t[[s]]==0), t[[s]]=Prime[n]], {n, 2, 100000}]; t
PROG
(PARI) a(n) = my(p=5, q=3, r=2); until(r+2*n==q&&q+4*n==p, r=q; q=p; p=nextprime(p+1)); r; \\ Jinyuan Wang, Feb 10 2021
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Jan 21 2003
EXTENSIONS
Terms corrected and more terms from Jinyuan Wang, Feb 10 2021
STATUS
approved