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!)
A290741 Orbit of word "2" under the 3-shift tag system over the alphabet {1,2} defined in the Comments. 4
2, 21222, 221221222, 2212221221222, 22212212221221222, 122122212212221221222, 1222122122212212222112, 21221222122122221122112, 212221221222211221121221222, 2212212222112211212212221221222, 22122221122112122122212212221221222, 222211221121221222122122212212221221222 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
This tag system maps a word w over {1,2} to w', where if w begins with 1, w' is obtained by appending 2112 to w and deleting the first three letters, or if w begins with 2, w' is obtained by appending 1221222 to w and deleting the first three letters.
This is a 3-shift version of a 5-shift tag system studied in [De Mol, p. 307] (cf. A293945).
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..328
MAPLE
with(StringTools);
f1:=proc(w) local L, t2, t1, ws, w2;
t1:="2112"; t2:="1221222"; ws:=convert(w, string);
if ws[1]="1" then w2:=Join([ws, t1], ""); else w2:=Join([ws, t2], ""); fi;
L:=length(w2); if L <= 3 then return(-1); fi;
w2[4..L]; end;
# and apply f1 repeatedly to "2"
PROG
(Python)
from itertools import islice
def agen(w="2"):
while True:
yield int(w)
w += ("2112" if w[0] == "1" else "1221222")
w = w[3:]
print(list(islice(agen(), 12))) # Michael S. Branicky, Mar 15 2022
CROSSREFS
Sequence in context: A339476 A242959 A123692 * A261362 A132942 A237521
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Aug 11 2017
EXTENSIONS
Definition corrected by N. J. A. Sloane, Oct 23 2017 (this is not De Mol's 5-shift tag system, which is described in A293945).
STATUS
approved

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 24 22:17 EDT 2024. Contains 371964 sequences. (Running on oeis4.)