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.
%I A156257 #33 Nov 11 2020 22:51:17 %S A156257 2,1,2,2,1,1,2,1,2,1,1,2,2,1,2,1,1,2,2,1,2,2,1,1,2,1,2,2,1,2,2,1,1,2, %T A156257 1,2,2,1,1,2,1,1,2,1,1,2,2,1,2,1,2,2,1,1,2,2,1,2,1,1,2,1,2,1,1,2,1,2, %U A156257 2,1,2,2,1,1,2,1,1,2,2,1,2,1,1,2,1,1,2,2,1,2,1,1,2,2,1,2,1,1,2,2,1,2,2,1,2 %N A156257 Digit of runs of length 2 in the Kolakoski sequence A000002: a(n) = A000002(A078649(n)). %C A156257 Often equal to A074292 (at the beginning), but not always (see comments in A074292). First differences between the two sequences are at n = 47, 48, 56, 57, 128, 129, 137, 139, 147, 148,176, 177,... (see A248345 = A156257 - A074292). - _Jean-Christophe Hervé_, Oct 11 2014 %C A156257 As in the Kolakoski sequence, runs in this sequence are of length 1 or 2: a run XX in this sequence implies YXXYX in OK for the first X, and this cannot be continued by a single Y (because XYXYX is not possible), thus we have YXXYXXY, which can be continued by YXXYXXYY or by YXXYXXYXYY, but not by YXXYXXYXX (because this would imply an impossible 21212 in OK). However, words of the form YXYXY appear in this sequence, but they don't in A000002. - _Jean-Christophe Hervé_, Oct 12 2014 %C A156257 Applying Lenormand's "raboter" transformation (see A318921) to A000002 leads to this sequence. - _Rémy Sigrist_, Nov 11 2020 %H A156257 Jean-Christophe Hervé, <a href="/A156257/b156257.txt">Table of n, a(n) for n = 1..5000</a> %F A156257 a(n) = A000002(A078649(n)) = A000002(A078649(n)+1). %F A156257 Strictly positive terms of (A000002(n)-1)*(mod(n-1, 2)+1). - _Jean-Christophe Hervé_, Oct 11 2014 %F A156257 Strictly positive terms of (1-abs(A000002(n+1)-A000002(n)))*A000002(n). - _Jean-Christophe Hervé_, Oct 11 2014 %e A156257 Kolakoski sequence begins (1),(2,2),(1,1),(2),(1),(2,2),(1),(2,2), so this one begins 2,1,2,2. %p A156257 A156257 := proc(n) %p A156257 A000002(A078649(n)) ; %p A156257 end proc: %p A156257 seq(A156257(n),n=1..50) ; # _R. J. Mathar_, Nov 15 2014 %t A156257 OK = {1, 2, 2}; Do[OK = Join[OK, {1+Mod[n-1, 2]}], {n, 3, 1000}, {OK[[n]]}]; Select[Split[OK], Length[#] == 2&][[All, 1]] (* _Jean-François Alcover_, Nov 13 2014 *) %Y A156257 Cf. A000002, A074292, A318921. %K A156257 nonn %O A156257 1,1 %A A156257 _Benoit Cloitre_, Feb 07 2009 %E A156257 Definition revised by _Jean-Christophe Hervé_, Oct 11 2014