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.

A036580 Ternary Thue-Morse sequence: closed under a->abc, b->ac, c->b.

Original entry on oeis.org

0, 1, 2, 0, 2, 1, 0, 1, 2, 1, 0, 2, 0, 1, 2, 0, 2, 1, 0, 2, 0, 1, 2, 1, 0, 1, 2, 0, 2, 1, 0, 1, 2, 1, 0, 2, 0, 1, 2, 1, 0, 1, 2, 0, 2, 1, 0, 2, 0, 1, 2, 0, 2, 1, 0, 1, 2, 1, 0, 2, 0, 1, 2, 0, 2, 1, 0, 2, 0, 1, 2, 1, 0, 1, 2, 0, 2, 1, 0, 2, 0, 1, 2, 0, 2, 1, 0, 1, 2, 1, 0, 2, 0, 1, 2, 1, 0, 1, 2
Offset: 0

Views

Author

Keywords

Comments

0 is a, 1 is b and 2 is c. - Robert G. Wilson v, Jul 30 2018

References

  • M. Lothaire, Combinatorics on Words. Addison-Wesley, Reading, MA, 1983, p. 26.

Crossrefs

A007413(n+1) - 1.
See A036577 for another version.

Programs

  • Mathematica
    Nest[Flatten[# /. {0 -> {0, 1, 2}, 1 -> {0, 2}, 2 -> {1}}] &, {1}, 7] // Most (* Robert G. Wilson v, Jul 30 2018, corrected by Paolo Xausa, Jul 21 2025 *)
    1 - Differences[ThueMorse[Range[0,100]]] (* Paolo Xausa, Jul 21 2025 *)