login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A135993
a(0) = 0; a(n) = (floor(n/S2(n))) mod 2 for n >= 1, where S2(n) is the binary weight of n.
1
0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1
OFFSET
0,1
LINKS
J.-P. Allouche, J. Shallit and J. Sondow, Summation of Series Defined by Counting Blocks of Digits, arXiv:math/0512399 [math.NT], 2005-2006.
J.-P. Allouche, J. Shallit and J. Sondow, Summation of series defined by counting blocks of digits, J. Number Theory 123 (2007), 133-143.
Jonathan Sondow and Petros Hadjicostas, The Generalized-Euler-Constant Function (z) and a Generalization of Somos's Quadratic Recurrence Constant, arXiv:math/0610499 [math.CA], 2006.
Jonathan Sondow and Petros Hadjicostas, The generalized-Euler-constant function gamma(z) and a generalization of Somos's quadratic recurrence constant, J. Math. Anal. Appl. 332 (2007), 292-314.
FORMULA
a(n) = A135941(n) mod 2 for n > 0. - Michel Marcus, Feb 04 2016
EXAMPLE
a(17) = floor(17/2) mod 2 = 0.
a(18) = floor(18/2) mod 2 = 1.
PROG
(PARI) a(n) = if (n==0, 0, n\hammingweight(n) % 2); \\ Michel Marcus, Feb 04 2016
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Ctibor O. Zizka, Mar 03 2008
EXTENSIONS
Converted references into links - R. J. Mathar, Oct 30 2009
STATUS
approved