login
A095111
One minus the parity of 1-fibits in Zeckendorf expansion A014417(n).
5
1, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 1, 0, 1, 0, 0, 1, 0, 0, 0, 1
OFFSET
0,1
REFERENCES
Michel Rigo, Formal Languages, Automata and Numeration Systems, 2 vols., Wiley, 2014. Mentions this sequence - see "List of Sequences" in Vol. 2.
FORMULA
a(n) = A010059(A003714(n)).
a(n) = 1 - A095076(n).
a(n) = a'(n+1) where a'(1) = 1 and if n >= 2 with F(k) < n <= F(k+1), a'(n)=1-a'(n-F(k)), where F(k) = A000045(k). E.g., F(5) = 5 < 6 <= F(6) = 8, thus a'(6) = 1 - a'(1) = 0 and a(5) = 0. - Benoit Cloitre, May 10 2005
MATHEMATICA
1 - Mod[DigitCount[Select[Range[0, 540], BitAnd[#, 2 #] == 0 &], 2, 1], 2] (* Amiram Eldar, Feb 05 2023 *)
PROG
(Python)
def ok(n): return 1 if n==0 else n*(2*n & n == 0)
print([1 - bin(n)[2:].count("1")%2 for n in range(1001) if ok(n)]) # Indranil Ghosh, Jun 08 2017
CROSSREFS
Characteristic function of A095096.
Run counts are given by A095276.
Sequence in context: A374043 A374041 A288733 * A166253 A159638 A187615
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jun 01 2004
STATUS
approved