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!)
A356551 a(n) = A005132(n+2) - A005132(n). 0
3, 5, -1, 1, 11, 13, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 35, 37, -1, 1, -1, -45, 1, -1, 1, -1, 1, -1, 1, -1, 1, 65, 67, -1, 1, -1, -75, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, 1, 131, 133, -1, 1, -1 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,1
LINKS
PROG
(PARI) vR(nn) = my(s, t, v=vector(nn)); for(n=1, nn, s=bitor(s, 1<<t += if( t<=n || bittest(s, t-n), n, -n)); v[n]=t); concat(0, v); \\ from A005132
lista(nn) = my(v=vR(nn+1)); vector(nn, k, v[k+2] - v[k]); \\ Michel Marcus, Aug 14 2022
(Python)
from itertools import count, islice
def A356551_gen(): # generator of terms
b, c, aset = 0, 1, {0}
for n in count(2):
aset.add(c)
a, b, c = b, c, d if (d:=c-n)>=0 and d not in aset else c+n
yield c-a
A356551_list = list(islice(A356551_gen(), 70)) # Chai Wah Wu, Sep 15 2022
CROSSREFS
Sequence in context: A074903 A091084 A016610 * A305470 A141707 A329593
KEYWORD
sign
AUTHOR
Paul Curtz, Aug 12 2022
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 August 1 23:38 EDT 2024. Contains 374819 sequences. (Running on oeis4.)