%I #6 Mar 20 2024 05:07:11
%S 1,2,1,4,3,5,2,4,1,4,3,5,8,2,4,7,1,4,8,10,3,5,8,11,2,4,7,11,1,4,8,10,
%T 13,3,5,8,11,13,2,4,7,11,13,1,4,8,10,13,16,3,5,8,11,13,16,2,4,7,11,13,
%U 16,18,1,4,8,10,13,16,18,3,5,8,11,13,16,20
%N Order of appearance of twos in the tribonacci ( Rauzy type) substitution: triangular.
%F 1->{2}, 2->{3}, 3->{1, 2, 3}
%t s[1] = {2}; s[2] = {3}; s[3] = {1, 2, 3}; t[a_] := Flatten[s /@ a]; p[0] =
%t {1}; p[1] = t[p[0]]; p[n_] := t[p[n - 1]]; a = Table[Flatten[Table[If[(Length[p[i]]) >= j && (p[i][[j]] == 2), j, {}], {j, 1, i}]], {i, 1, 20}]; MatrixForm[a] //Flatten
%Y Cf. A000073.
%K nonn,uned,tabf
%O 0,2
%A _Roger L. Bagula_, Jun 09 2005