%I #20 Jan 06 2021 12:44:04
%S 1,0,2,1,2,0,1,0,2,0,1,2,1,0,2,1,2,0,1,2,1,0,2,0,1,0,2,1,2,0,1,0,2,0,
%T 1,2,1,0,2,0,1,0,2,1,2,0,1,2,1,0,2,1,2,0,1,0,2,0,1,2,1,0,2,1,2,0,1,2,
%U 1,0,2,0,1,0,2,1,2,0,1,2,1,0,2,1,2,0,1,0,2,0,1,2,1,0,2,0,1,0,2
%N Ternary Thue-Morse sequence: closed under a->abc, b->ac, c->b.
%C Trajectory of 1 under the morphism 0 -> 12, 1 -> 102 & 2 -> 0. - _Robert G. Wilson v_, Apr 06 2008
%D Brian Hayes, Group Theory in the Bedroom and other Mathematical Diversions, Hill and Wang, A division of Farrar, Straus and Giroux, NY, 2008, pages 190-194.
%D M. Lothaire, Combinatorics on Words. Addison-Wesley, Reading, MA, 1983, p. 26.
%H Aviezri S. Fraenkel, <a href="http://dx.doi.org/10.1016/j.disc.2011.03.032">The vile, dopey, evil and odious game players</a>, Discrete Math. 312 (1) (2012) 42-46.
%H <a href="/index/Fi#FIXEDPOINTS">Index entries for sequences that are fixed points of mappings</a>
%t Nest[ # /. {0 -> {1, 2}, 1 -> {1, 0, 2}, 2 -> {0}} &, {0}, 7] // Flatten (* _Robert G. Wilson v_, Apr 06 2008 *)
%Y Cf. A005679, A036577, A036579, A036580, A036581, A036582, A036583, A036584, A036585, A036586.
%K nonn
%O 0,3
%A _N. J. A. Sloane_.