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!)
A163618 a(2*n) = 2 * a(n). a(2*n - 1) = 2 * a(n) - 2 - (-1)^n, for all n in Z. 2
0, 1, 2, 1, 4, 1, 2, 5, 8, 1, 2, 1, 4, 9, 10, 13, 16, 1, 2, 1, 4, 1, 2, 5, 8, 17, 18, 17, 20, 25, 26, 29, 32, 1, 2, 1, 4, 1, 2, 5, 8, 1, 2, 1, 4, 9, 10, 13, 16, 33, 34, 33, 36, 33, 34, 37, 40, 49, 50, 49, 52, 57, 58, 61, 64, 1, 2, 1, 4, 1, 2, 5, 8, 1, 2, 1, 4, 9, 10, 13, 16, 1, 2, 1, 4, 1, 2, 5, 8, 17 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
Integers n>=0 such that a(n) = 1 is A118113.
Fibbinary numbers (A003714) give all integers n>=0 for which a(n+1) = 1 or 2. - Michael Somos, Feb 21 2016
LINKS
FORMULA
a(n) = -A163617(-n) for all n in Z.
EXAMPLE
G.f. = x + 2*x^2 + x^3 + 4*x^4 + x^5 + 2*x^6 + 5*x^7 + 8*x^8 + x^9 + 2*x^10 + ...
MATHEMATICA
Table[(-1)*BitOr[-n, -2*n], {n, 0, 50}] (* G. C. Greubel, Jul 30 2017 *)
PROG
(PARI) {a(n) = n=-n; -bitor(n, n<<1)};
(PARI) {a(n) = if( n==0 || n==1, n, 2 * a((n+1) \ 2) - (n%2) * (2 + (-1)^((n+1) \ 2)))};
CROSSREFS
Cf. A163617.
Sequence in context: A171174 A171173 A268671 * A341691 A275392 A360329
KEYWORD
nonn
AUTHOR
Michael Somos, Aug 01 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 19 23:40 EDT 2024. Contains 371798 sequences. (Running on oeis4.)