OFFSET
0,2
COMMENTS
Harter-Heighway dragon when interpreting 1, 2, 3, and 4 respectively as unit edge to right, up, left, and down. - Joerg Arndt, Jun 03 2021
The characteristic polynomial of the transition matrix is x^4-4*x^3+6*x^2-4*x = x*(x-2)*(x^2 - 2*x + 2).
LINKS
Joerg Arndt, Iterate six of the Harter-Heighway dragon
F. M. Dekking, Recurrent sets, Advances in Mathematics, vol. 44, no. 1 (1982), 78-104; page 89, section 4.5.
FORMULA
a(n) = A246960(n) + 1. - Joerg Arndt, Jun 03 2021
MATHEMATICA
Flatten[ Nest[ Flatten[ # /. {1 -> {1, 2}, 2 -> {3, 2}, 3 -> {3, 4}, 4 -> {1, 4}} &], {1}, 7]]
PROG
(Python)
def A105500(n): return ((n^(n>>1)).bit_count()&3)+1 # Chai Wah Wu, Jul 13 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Roger L. Bagula, May 02 2005
STATUS
approved