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!)
A062187 a(n+1) = a(n) - a(floor(n/2)), with a(0)=0, a(1)=1. 2
0, 1, 1, 0, -1, -2, -3, -3, -3, -2, -1, 1, 3, 6, 9, 12, 15, 18, 21, 23, 25, 26, 27, 26, 25, 22, 19, 13, 7, -2, -11, -23, -35, -50, -65, -83, -101, -122, -143, -166, -189, -214, -239, -265, -291, -318, -345, -371, -397, -422, -447, -469, -491, -510, -529, -542, -555, -562, -569, -567, -565, -554, -543, -520, -497, -462 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,6
COMMENTS
Period of oscillations above and below the axis more than doubles at each cycle.
LINKS
FORMULA
G.f. A(x) satisfies: A(x) = x * (1 - (1 + x)*A(x^2))/(1 - x). - Ilya Gutkovskiy, May 04 2019
EXAMPLE
a(6) = a(5) - a(2) = -2 - 1 = -3.
a(7) = a(6) - a(3) = -3 - 0 = -3.
PROG
(Python)
from itertools import islice
from collections import deque
def A062187_gen(): # generator of terms
aqueue, f, b, a = deque([1]), True, 0, 1
yield from (0, 1)
while True:
a -= b
yield a
aqueue.append(a)
if f: b = aqueue.popleft()
f = not f
A061287_list = list(islice(A062187_gen(), 40)) # Chai Wah Wu, Jun 08 2022
CROSSREFS
Sequence in context: A098418 A364367 A128080 * A334485 A347824 A031283
KEYWORD
sign
AUTHOR
Henry Bottomley, Jun 13 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 | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 6 16:29 EDT 2024. Contains 372296 sequences. (Running on oeis4.)