login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A253899 a(0) = 3, then a(n) is the least prime greater than a(n-1) that follows a gap of exactly 2*n. 2
3, 5, 11, 29, 97, 149, 211, 307, 1847, 1931, 3109, 3251, 4201, 5557, 5981, 6521, 10831, 11777, 12889, 30631, 33287, 35023, 36433, 81509, 86677, 95701, 103289, 106087, 153247, 181361, 189127, 190471, 288647, 294629, 326437, 399353, 507289, 515041 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

LINKS

Robert G. Wilson v, Table of n, a(n) for n = 0..180

FORMULA

a(n) = A256454(n)+2n for n>0. - Robert G. Wilson v, Mar 30 2015

EXAMPLE

149 - 139 = 10, the first time this gap was seen after smaller gaps of 1,2,4,6,8.

MAPLE

A[0]:= 3:

p:=3:

n:= 1:

for i from 1 to 10^5 do

  q:= nextprime(p);

  gap:= q - p;

  if gap = 2*n then

     A[n]:= q;

     n:= n+1;

  fi;

  p:= q;

od:

seq(A[i], i=1..n); # Robert Israel, Jan 18 2015

MATHEMATICA

lst = {3}; p = 2; q = 3; gp = 2; While[gp != 1000, While[q - p != gp, p = q; q = NextPrime@ p]; AppendTo[lst, q]; Print@ q; gp += 2]; lst (* Robert G. Wilson v, Jan 23 2015 *)

PROG

(PARI) genit(maxx)={n=3; delta=2; print1(n, ", "); ptr=1; while(delta<maxx, p=prime(n-1); q=nextprime(p+1); if(delta==q-p, print1(q, ", "); delta+=2; ptr++); n++); }

CROSSREFS

Cf. A000101, A000230.

Sequence in context: A095302 A335367 A000101 * A037152 A084748 A265784

Adjacent sequences:  A253896 A253897 A253898 * A253900 A253901 A253902

KEYWORD

nonn,easy

AUTHOR

Bill McEachen, Jan 17 2015

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 13 08:26 EDT 2020. Contains 335685 sequences. (Running on oeis4.)