cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A268676 a(n) = A101080(n,A268823(3+n)), where A101080(x,y) gives the Hamming distance between binary expansions of x and y.

Original entry on oeis.org

1, 3, 3, 1, 3, 1, 1, 3, 3, 1, 1, 3, 1, 3, 3, 1, 3, 1, 1, 3, 1, 3, 3, 1, 1, 3, 3, 1, 3, 1, 1, 3, 3, 1, 1, 3, 1, 3, 3, 1, 1, 3, 3, 1, 3, 1, 1, 3, 1, 3, 3, 1, 3, 1, 1, 3, 3, 1, 1, 3, 1, 3, 3, 1, 3, 1, 1, 3, 1, 3, 3, 1, 1, 3, 3, 1, 3, 1, 1, 3, 1, 3, 3, 1, 3, 1, 1, 3, 3, 1, 1, 3, 1, 3, 3, 1, 1, 3, 3, 1, 3, 1, 1, 3, 3, 1, 1, 3, 1, 3, 3, 1, 3, 1, 1, 3, 1, 3, 3, 1, 1
Offset: 0

Views

Author

Antti Karttunen, Feb 19 2016

Keywords

Comments

It seems that A001969 gives the positions of 1's, while A000069 gives the positions of 3's.
The above observation follows because by definition, a(n) gives the Hamming distance between binary expansions of n and A003188(3+A006068(n)). To see how this leads to the stated claim, consider the illustration "Visualized as a traversal of vertices of a tesseract" in the Wikipedia article "Gray code". Starting from any vertex with either (A) an even, or (B) an odd number of 1-bits, traverse three edges along the red path, to the direction indicated by the arrow, and then note the Hamming distance between the starting and the ending vertex. It is always 1 in case (A), and 3 in case (B), because the position of the flipped bit is given by sequence A007814, with its every other term zero, so in case (A) the third flip cancels the first flip (both toggling the rightmost bit), which leaves only the second bit-flip effective. Note that the properties of a tesseract generalize to those of an infinite dimensional hypercube. - Antti Karttunen, Mar 11 2024

Crossrefs

Programs

Formula

a(n) = A101080(n,A268823(3+n)), where A101080(x,y) gives the Hamming distance between binary expansions of x and y.
a(n) = 2 - (-1)^A000120(n) = 2 - A106400(n). - Lorenzo Sauras Altuzarra, Mar 10 2024
a(n) = 1 + 2 * A010060(n). - Joerg Arndt, Mar 11 2024