login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A064009 a(n) = Sum_{k=1..n} d(k)*prime(k), where d(k) = A001223. 1
2, 8, 18, 46, 68, 120, 154, 230, 368, 426, 612, 760, 842, 1014, 1296, 1614, 1732, 2098, 2366, 2508, 2946, 3262, 3760, 4472, 4860, 5062, 5474, 5688, 6124, 7706, 8214, 9000, 9274, 10664, 10962, 11868, 12810, 13462, 14464, 15502, 15860, 17670, 18052 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Harry J. Smith, Table of n, a(n) for n=1..1000

EXAMPLE

a(4) = 2*(3-2) + 3*(5-3) + 5*(7-5) + 7*(11-7) = 46.

MATHEMATICA

Accumulate@ Array[# (NextPrime@ # - #) &@ Prime@ # &, {43}] (* Michael De Vlieger, May 05 2016 *)

PROG

(PARI) d(n) = prime(n+1)-prime(n); j=[]; for(n=1, 150, j=concat(j, sum(k=1, n, prime(k)*d(k)))); j

(PARI) d(n)= { prime(n + 1) - prime(n) } { a=0; for (n=1, 1000, write("b064009.txt", n, " ", a+=prime(n)*d(n)) ) } \\ Harry J. Smith, Sep 05 2009

(Sage) p=primes_first_n(44); d=differences(p); v=[]; a=0

for k in range(len(d)):

   a+=p[k]*d[k]; v.append(a)

print v  # Giuseppe Coppoletta, May 05 2016

CROSSREFS

Sequence in context: A212518 A264054 A073307 * A246148 A201348 A102713

Adjacent sequences:  A064006 A064007 A064008 * A064010 A064011 A064012

KEYWORD

nonn

AUTHOR

Jason Earls, Sep 06 2001

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.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 20 18:39 EDT 2019. Contains 328269 sequences. (Running on oeis4.)