login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A046930 Size of sea of composite numbers surrounding n-th prime. 7

%I #22 Dec 21 2021 23:46:56

%S 1,1,2,4,4,4,4,4,8,6,6,8,4,4,8,10,6,6,8,4,6,8,8,12,10,4,4,4,4,16,16,8,

%T 6,10,10,6,10,8,8,10,6,10,10,4,4,12,22,14,4,4,8,6,10,14,10,10,6,6,8,4,

%U 10,22,16,4,4,16,18,14,10,4,8,12,12,10,8,8,12,10,10,16,10,10,10,6,8,8

%N Size of sea of composite numbers surrounding n-th prime.

%H T. D. Noe, <a href="/A046930/b046930.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = A031131(n) - 2 for n > 1. - _Reinhard Zumkeller_, Dec 19 2013

%e 23 is in a sea of 8 composites: 20,21,22,23,24,25,26,27,28.

%p [ seq(ithprime(i)-ithprime(i-2)-2,i=3..100) ];

%t Table[ Prime[n + 2] - Prime[n] - 2, {n, 75}] (* _Robert G. Wilson v_ Oct 27 2004 *)

%t Join[{1},#[[3]]-#[[1]]-2&/@Partition[Prime[Range[90]],3,1]] (* _Harvey P. Dale_, Sep 26 2012 *)

%o (Haskell)

%o a046930 1 = 1

%o a046930 n = subtract 2 $ a031131 n -- _Reinhard Zumkeller_, Dec 19 2013

%Y Related sequences: A023186-A023188, A046929-A046931, A051650, A051652, A051697-A051702, A051728-A051730.

%K nonn,easy,nice

%O 1,3

%A _N. J. A. Sloane_, _Marc LeBrun_

%E More terms from _Michel ten Voorde_

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 18 22:18 EDT 2024. Contains 371782 sequences. (Running on oeis4.)