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!)
A072926 a(n) = Sum_{k=1..n} A051699(k). 1
1, 1, 1, 2, 2, 3, 3, 4, 6, 7, 7, 8, 8, 9, 11, 12, 12, 13, 13, 14, 16, 17, 17, 18, 20, 23, 25, 26, 26, 27, 27, 28, 30, 33, 35, 36, 36, 37, 39, 40, 40, 41, 41, 42, 44, 45, 45, 46, 48, 51, 53, 54, 54, 55, 57, 60, 62, 63, 63, 64, 64, 65, 67, 70, 72, 73, 73, 74, 76, 77, 77, 78, 78, 79 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,4
LINKS
FORMULA
Conjecture: a(n) is asymptotic to C*n*log(n) with C = 0.29... .
MATHEMATICA
f[n_] := If[PrimeQ[n], 0, Min[NextPrime[n] - n, n - NextPrime[n, -1]]]; Accumulate[Table[f[n], {n, 1, 100}]] (* Amiram Eldar, May 05 2022 *)
PROG
(PARI) a(n)=sum(k=1, n, vecmin(vector(k, i, abs(k-prime(i)))))
CROSSREFS
Cf. A051699.
Sequence in context: A276774 A129768 A210715 * A080087 A345163 A369728
KEYWORD
nonn
AUTHOR
Benoit Cloitre, Aug 11 2002
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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 1 22:05 EDT 2024. Contains 375597 sequences. (Running on oeis4.)