login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A031165 a(n) = p(n+3)-p(n) (p()=primes). 2
5, 8, 8, 10, 8, 10, 12, 12, 14, 12, 12, 10, 12, 16, 14, 14, 12, 12, 12, 12, 16, 18, 18, 14, 10, 8, 10, 20, 22, 24, 12, 18, 14, 18, 14, 16, 16, 16, 14, 18, 14, 16, 8, 18, 26, 28, 18, 10, 12, 12, 18, 18, 22, 18, 14, 14, 12, 12, 16, 26, 28, 20, 10, 20, 24, 30, 18, 16, 12 (list; graph; refs; listen; history; internal format)
OFFSET

1,1

COMMENTS

Comments from Jonathan Vos Post (jvospost3(AT)gmail.com), Jan 22 2006 (Start): This sequence is the k=3 case of the family of sequences a(k,n) = prime(n+k) - prime(n). See A001223 and A031131 for k = 1 and 2.

The records in this sequence give A115401. The minimal value, after the anomalous initial values (5, 8, 8), is 8 which occurs iff n is an element of A007530 (prime quadruples: numbers n such that n, n+2, n+6, n+8 are all prime). (End)

FORMULA

a(n) = prime(n+3) - prime(n). a(n) = A000040(n+3) - A000040(n). - Jonathan Vos Post (jvospost3(AT)gmail.com), Jan 22 2006

EXAMPLE

a(1) = prime(4) - prime(1) = 7 - 2 = 5, which is the only odd element of this sequence.

a(2) = prime(5) - prime(2) = 11 - 3 = 8.

a(3) = prime(6) - prime(3) = 13 - 5 = 8.

a(4) = prime(7) - prime(4) = 17 - 7 = 10.

a(99) = prime(102) - prime(99) = 557 - 523 = 34. - Jonathan Vos Post (jvospost3(AT)gmail.com), Jan 22 2006

MAPLE

ithprime(n+3)-ithprime(n);

MATHEMATICA

t = Array[Prime, 75]; Drop[t, 3] - Drop[t, -3] (* Robert G. Wilson v *)

PROG

(MAGMA) [NthPrime(n+3)-NthPrime(n): n in [1..100] ]; // Vincenzo Librandi, Apr 11 2011

CROSSREFS

Cf. A000040, A001223, A007530, A031131, A115401.

Sequence in context: A200286 A073822 A198606 * A113729 A097523 A197815

Adjacent sequences:  A031162 A031163 A031164 * A031166 A031167 A031168

KEYWORD

nonn

AUTHOR

Jeff Burch (jmburch(AT)osprey.smcm.edu)

EXTENSIONS

Edited by R. J. Mathar and N. J. A. Sloane (njas(AT)research.att.com), Aug 11 2008

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 16 21:48 EST 2012. Contains 205978 sequences.