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!)
A163061 Sum of the first n primes plus the first n nonprimes. 1
2, 6, 15, 28, 47, 69, 96, 127, 164, 208, 255, 310, 371, 435, 504, 581, 665, 752, 846, 945, 1048, 1159, 1275, 1398, 1530, 1667, 1808, 1954, 2103, 2258, 2429, 2605, 2788, 2975, 3173, 3374, 3582, 3797, 4018, 4246, 4481, 4719, 4968, 5221, 5480, 5742 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
FORMULA
a(n)=A007504(n)+A051349(n-1).
EXAMPLE
a(1)=2+0=2. a(2)=5+1=6. a(3)=10+5=15. a(4)=17+11=28. a(5)=28+19=47. a(6)=41+28=69. a(7)=58+38=96.
MATHEMATICA
Module[{nn=80, np, len}, np=Select[Range[0, nn], !PrimeQ[#]&]; len=Length[np]; Total/@ Thread[{Accumulate[np], Accumulate[Prime[Range[len]]]}]] (* Harvey P. Dale, Jun 14 2019 *)
CROSSREFS
Sequence in context: A360405 A256313 A138621 * A331773 A033286 A182724
KEYWORD
nonn
AUTHOR
EXTENSIONS
Formula index corrected, 1119 replaced by 1159 - R. J. Mathar, Jul 27 2009
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 April 25 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)