%I #27 Aug 18 2017 16:43:39
%S -1,12,1,1,212,212,11,11,11,11,2212,2212,2212,2212,111,211,111,211,
%T 111,211,111,211,12212,22212,12212,22212,12212,22212,12212,22212,1111,
%U 1211,2111,2211,1111,1211,2111,2211,1111,1211,2111,2211,1111,1211,2111,2211,112212
%N Take n-th string over {1,2} in lexicographic order and apply the Post tag system described in A284116 (but adapted to the alphabet {1,2}) just once.
%C Post's tag system maps a word w over {1,2} to w', where if w begins with 1, w' is obtained by appending 11 to w and deleting the first three letters, or if w begins with 2, w' is obtained by appending 2212 to w and deleting the first three letters.
%C The empty word is denoted by -1.
%C We work over {1,2} rather than the official alphabet {0,1} because of the prohibition in the OEIS of terms (other than 0 itself) which begin with 0.
%H Chai Wah Wu, <a href="/A289673/b289673.txt">Table of n, a(n) for n = 1..10000</a>
%e The initial words are:
%e 1,2,11,12,21,22,111,112,121,122,211,212,221,222,1111,...
%e Applying the tag system over {1,2} these become:
%e -1, 12, 1, 1, 212, 212, 11, 11, 11, 11, 2212, 2212, 2212, 2212, 111, ...
%e If we were working over {0,1} the initial strings would be:
%e 0,1,00,01,10,11,000,001,010,011,100,101,110,111,0000,...
%e and applying the tag system over {0,1} described in A284116 these would become:
%e -1, 01, 0, 0, 101, 101, 00, 00, 00, 00, 1101, 1101, 1101, 1101, 000, ...
%p See A291072.
%o (Python)
%o from itertools import product
%o A289673_list = [-1 if s == ('1',) else int((''.join(s)+('2212' if s[0] == '2' else '11'))[3:]) for l in range(1,10) for s in product('12',repeat=l)] # _Chai Wah Wu_, Aug 06 2017
%Y Cf. A284116, A284119, A284121, A289670, A289671, A289672, A289674, A289675.
%Y See also A291072, A291073, A291074.
%K sign
%O 1,2
%A _N. J. A. Sloane_, Jul 29 2017
%E More terms from _Chai Wah Wu_, Aug 06 2017
|