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

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A212530 Difference between the sum of the first n primes s(n) and the nearest square <  s(n). 1
 1, 1, 1, 1, 3, 5, 9, 13, 19, 8, 16, 1, 13, 25, 4, 20, 40, 17, 39, 14, 36, 7, 33, 2, 36, 5, 39, 2, 36, 72, 39, 2, 52, 11, 67, 26, 84, 43, 105, 62, 17, 83, 38, 110, 59, 2, 82, 37, 127, 76, 21, 113, 54, 152, 97, 40, 146, 85, 22, 130, 61, 175, 118, 57, 181, 114 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,5 COMMENTS Let  A007504(n) the sum of the first n primes. It is proved that between the numbers A007504(n) and A007504(n+1) there must be a square integer. The sum of the first n primes is asymptotically equivalent to (1/2)*log(n)*n^2. LINKS Michel Lagneau, Table of n, a(n) for n = 1..10000 EXAMPLE a(5) = 3 because the sum of the 5 primes 2 + 3 + 5 + 7 + 11 = 28, and 28 - 25 = 3. MAPLE with(numtheory): for n from 1 to 100 do:s:=sum(‘ithprime(k)’, ’k’=1..n):x:=s -floor(sqrt(s-1))^2: printf(`%d, `, x):od: CROSSREFS Cf. A007504. Sequence in context: A074133 A215909 A078735 * A004132 A207187 A065802 Adjacent sequences:  A212527 A212528 A212529 * A212531 A212532 A212533 KEYWORD nonn AUTHOR Michel Lagneau, May 20 2012 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.

Last modified January 16 05:22 EST 2022. Contains 350374 sequences. (Running on oeis4.)