OFFSET
1
COMMENTS
Conjecture: the number of letters (0's and 1's) in the n-th iterate of the mapping is given by A289004.
The mapping is applied as in the Mathematica command StringReplace. In particular, for a word of odd length, the final letter is retained, as in 0010010 -> 00100100100. (If the final letter is removed, the iterates are changed, but the limiting fixed point remains unchanged. See A293077.)
More generally, to describe the result of the command StringReplace[w, {u(1)->v(1), u(2)->v(2) ... u(n)-<v(n)}], assume that no u(i) is a subword of any other u(j). The word w is then a concatenation of subwords u(i(0)), g(1), u(i(1)), g(2), u(i(2)), ..., such that u(i(0)) is the empty word, and each g(j) is the subword, g, possibly empty, of least length immediately following u(i(j-1)), such that no subword of g is one of the words u(i). The result of the command is then the concatenation of g(1), v(i(1)), g(2), v(i(2)), ... That is, each u(i) is replaced by v(i), and the words g(i) are left unchanged.
Conjecture: a(n) = A171588(n-3) for n>3. - Michel Dekking, Mar 20 2022
LINKS
Clark Kimberling, Table of n, a(n) for n = 1..10000
EXAMPLE
First seven iterates of the mapping:
00
0010
0010010
00100100100
001001001000100100
0010010010001001000100100100010
0010010010001001000100100100010010001001001000100100
MATHEMATICA
z = 10; (* number of iterates *)
s = {0, 0}; w[0] = StringJoin[Map[ToString, s]];
w[n_] := StringReplace[w[n - 1], {"00" -> "0010", "01" -> "010", "10" -> "010"}]
TableForm[Table[w[n], {n, 0, 10}]]
st = ToCharacterCode[w[z]] - 48 (* A289035 *)
Flatten[Position[st, 0]] (* A289036 *)
Flatten[Position[st, 1]] (* A289037 *)
Table[StringLength[w[n]], {n, 0, 20}] (* A289004 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Jun 27 2017
EXTENSIONS
Updated by Clark Kimberling, Sep 30 2017
STATUS
approved