login
Trajectory of 1 under repeated application of the morphism 1->121, 2->232, 3->343, 4->414.
1

%I #14 Apr 06 2020 10:27:35

%S 1,2,1,2,3,2,1,2,1,2,3,2,3,4,3,2,3,2,1,2,1,2,3,2,1,2,1,2,3,2,3,4,3,2,

%T 3,2,3,4,3,4,1,4,3,4,3,2,3,2,3,4,3,2,3,2,1,2,1,2,3,2,1,2,1,2,3,2,3,4,

%U 3,2,3,2,1,2,1,2,3,2,1,2,1,2,3,2,3,4,3,2,3,2,3,4,3,4

%N Trajectory of 1 under repeated application of the morphism 1->121, 2->232, 3->343, 4->414.

%H Robert Israel, <a href="/A317952/b317952.txt">Table of n, a(n) for n = 0..10000</a>

%H Julien Cassaigne, Juhani Karhumäki, Svetlana Puzynina, <a href="https://doi.org/10.1016/j.ic.2018.04.001">On k-abelian palindromes</a>, Information and Computation, Volume 260, June 2018, Pages 89-98. See Lemma 1.

%F From _Robert Israel_, Aug 20 2018: (Start)

%F a(3*k) = a(3*k+2) = a(k).

%F a(3*k+1) == 1 + a(k) mod 4. (End)

%p A:= [1]:

%p for k from 1 to 5 do A:= subs([1=(1,2,1),2=(2,3,2),3=(3,4,3),4=(4,1,4)],A);

%p od:

%p op(A); # _Robert Israel_, Aug 20 2018

%t SubstitutionSystem[{1 -> {1, 2, 1}, 2 -> {2, 3, 2}, 3 -> {3, 4, 3}, 4 -> {4, 1, 4}}, 1, 5] // Last (* _Jean-François Alcover_, Apr 06 2020 *)

%K nonn

%O 0,2

%A _N. J. A. Sloane_, Aug 20 2018