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

 Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 60th year, we have over 367,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”). Other ways to Give
 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A058043 a(n) = nextprime(n^2) - prevprime(n^2). 10
 2, 4, 4, 6, 6, 6, 6, 4, 4, 14, 10, 6, 4, 4, 6, 10, 14, 8, 4, 4, 8, 18, 6, 12, 4, 6, 14, 14, 20, 14, 10, 4, 10, 6, 6, 6, 8, 12, 4, 24, 18, 14, 16, 10, 16, 6, 12, 12, 26, 16, 8, 16, 8, 14, 16, 22, 10, 22, 14, 8, 14, 22, 6, 10, 8, 10, 16, 24, 14, 12, 10, 10, 6, 16, 30, 12, 10, 18, 24, 10 (list; graph; refs; listen; history; text; internal format)
 OFFSET 2,1 LINKS Alois P. Heinz, Table of n, a(n) for n = 2..10000 EXAMPLE 6^2=36 is immediately preceded and followed by 31 and 37, of which 6 is the difference. MAPLE [seq(nextprime(i^2)-prevprime(i^2), i=2..1000)]; MATHEMATICA Table[n2=n^2; (NextPrime[n2]-NextPrime[n2, -1]), {n, 2, 100}] (* Vladimir Joseph Stephan Orlovsky, Mar 09 2011 *) PROG (PARI) A058043(n) = nextprime(n^2)-prime(primepi(n^2)) \\ Michael B. Porter, Feb 09 2010 CROSSREFS Sequence in context: A058249 A340226 A348769 * A251546 A282894 A162550 Adjacent sequences: A058040 A058041 A058042 * A058044 A058045 A058046 KEYWORD nonn AUTHOR Labos Elemer, Nov 17 2000 STATUS approved

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.

Last modified December 8 13:46 EST 2023. Contains 367679 sequences. (Running on oeis4.)