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.

A133162 Trajectory of 1 under the morphism 1 -> {1,1,2,1}, 2 -> {2}.

This page as a plain text file.
%I A133162 #24 Jan 12 2022 09:25:46
%S A133162 1,1,2,1,1,1,2,1,2,1,1,2,1,1,1,2,1,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,1,2,
%T A133162 1,2,1,1,2,1,1,1,2,1,1,1,2,1,2,1,1,2,1,1,1,2,1,1,1,2,1,2,1,1,2,1,2,1,
%U A133162 1,2,1,1,1,2,1,2,1,1,2,1,2,1,1,2,1,1,1,2,1,2,1,1,2,1,1,1,2,1,1
%N A133162 Trajectory of 1 under the morphism 1 -> {1,1,2,1}, 2 -> {2}.
%C A133162 It can be shown that this is lim_{t -> oo} S_t, where S_0 = 1, S_{t+1} = S_t S_t 2 S_t.
%C A133162 Suggested by A131989: a(n) = length of n-th run of 1's in A131989.
%C A133162 For a proof of this see the Comments of A131989. - _Michel Dekking_, Oct 19 2019
%H A133162 Seiichi Manyama, <a href="/A133162/b133162.txt">Table of n, a(n) for n = 1..10000</a>
%H A133162 <a href="/index/Fi#FIXEDPOINTS">Index entries for sequences that are fixed points of mappings</a>
%F A133162 Denote the sequence by a(1), a(2), ...
%F A133162 Block t, that is, S_t, extends from n=1 through n=(3^(t+1)-1)/2.
%F A133162 Given n, to find a(n): first find t from
%F A133162 p = (3^t-1)/2 < n <= (3^(t+1)-1)/2.
%F A133162 Then if n=3^t, a(n) = 2. Otherwise, a(n) = a(n'), where
%F A133162 n' = n-p if n<3^t, otherwise n' = n-2p-1.
%t A133162 Nest[Function[l, {Flatten[(l /. {1 -> {1,1,2,1}, 2 -> {2} })] }], {1}, 5] (* _Georg Fischer_, Jul 19 2019 *)
%Y A133162 Cf. A049320, A131989, A317962.
%K A133162 nonn,easy
%O A133162 1,3
%A A133162 _N. J. A. Sloane_, Oct 09 2007, Oct 10 2007