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

 

Logo

Please make a donation to keep the OEIS running. We are now in our 55th year. In the past year we added 12000 new sequences and reached 8000 citations (which often say "discovered thanks to the OEIS"). We need to raise money to hire someone to manage submissions, which would reduce the load on our editors and speed up editing.
Other ways to donate

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A162385 Alternating sum from the n-th Mersenne prime up to the n-th perfect number. 0
2, 11, 233, 4001, 16771073, 4294868993, 68719083521, 1152921502996234241, 1329227995784915871174424803370074113, 95780971304118053647396688732666809244153592049303553 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

Define the alternating sum S(k) = sum_{x=0..k} x*(-1)^x = (-1)^k*(k/2+1/4)-1/4 = A130472(k).

a(n) is this sum evaluated with a lower limit of A000668(n) and an upper limit of A000396(n).

LINKS

Table of n, a(n) for n=1..10.

FORMULA

a(n) = A130472(A000396(n)) - A130472( A000668(n)-1).

a(n) = (A000396(n) - A000668(n) + 1)/2. - César Aguilera, May 13 2017

a(n) = (1 + A139224(n))/2. - Omar E. Pol, May 22 2017

EXAMPLE

a(1) = -3+4-5+6 = 2. a(2) = -7+8-9+10-11+12-13+14-15+16-17+...-27+28 = 11.

CROSSREFS

Cf. A000396, A000668.

Sequence in context: A042805 A088639 A269710 * A244012 A264330 A134096

Adjacent sequences:  A162382 A162383 A162384 * A162386 A162387 A162388

KEYWORD

nonn,less

AUTHOR

Juri-Stepan Gerasimov, Jul 21 2009

EXTENSIONS

Edited and extended by R. J. Mathar, Sep 16 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 | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 14 19:27 EST 2019. Contains 329987 sequences. (Running on oeis4.)