login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A107337 Substitution 1->{1, 2, 1, 3, 2, 3, 1}, 2->{3}, 3->{1}, starting with 1. 1

%I #13 Sep 04 2014 09:26:31

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

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

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

%N Substitution 1->{1, 2, 1, 3, 2, 3, 1}, 2->{3}, 3->{1}, starting with 1.

%C Original name was: 223 Pisot cubic substitution with characteristic polynomial: x^3-3*x^2-2*x-2.

%e Start: 1

%e Rules:

%e 1 --> 1213231

%e 2 --> 3

%e 3 --> 1

%e -------------

%e 0: (#=1)

%e 1

%e 1: (#=7)

%e 1213231

%e 2: (#=25)

%e 1213231312132311311213231

%e 3: (#=91)

%e 1213231312132311311213231112132313121323113112132311213231112132311213231312132311311213231

%e 4: (#=337)

%e 12132313121323113112132311121323131213231131121323112132 ...

%t s[1] = {1, 2, 1, 3, 2, 3, 1}; s[2] = {3}; s[3] = {1}; t[a_] := Flatten[s /@ a]; p[0] = {1}; p[1] = t[p[0]]; p[n_] := t[p[n - 1]] aa = p[4]

%o (Python)

%o from itertools import chain

%o A107337 = [1]

%o for _ in range(4):

%o ....A107337 = list(chain.from_iterable(([1,2,1,3,2,3,1] if d == 1 else [3] if d == 2 else [1] for d in A107337)))

%o # _Chai Wah Wu_, Sep 03 2014

%K nonn,easy

%O 0,2

%A _Roger L. Bagula_, May 22 2005

%E Edited by _Joerg Arndt_, Jun 26 2011

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 01:35 EDT 2024. Contains 371964 sequences. (Running on oeis4.)