

A025142


Fixed point of the square runlength transform, with a(1) = 1 (the runlength transform of a binary sequence is the sequence of the lengths of its runs).


12



1, 1, 2, 1, 1, 2, 2, 1, 2, 2, 1, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 1, 2, 1, 1, 2, 1, 1, 2, 2, 1, 2, 1, 1, 2, 1, 2, 2, 1, 1, 2, 1, 1, 2, 1, 2, 2, 1, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 1, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 1, 2, 1, 1, 2, 1, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 1, 2, 2, 1, 1, 2, 1, 1, 2, 1, 2, 2, 1, 2, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,3


COMMENTS

Unique sequence a such that a(1) = 1 and RL^2(a) = a != RL(a), where for any sequence s of 1's and 2's, the runlength transform of s RL(s) is such that RL(s)(n) = length of nth run of same symbols in s; RL(a) is sequence A025143.
Conjecture: as for the Kolakoski sequence A000002, which is a fixed point of RL, it remains to be shown that the limiting frequency of 1's and 2's in this sequence is 0.5.  JeanChristophe Hervé, Oct 21 2014
Like the Kolakoski sequence, this sequence is cubefree and for this reason some words can never appear like XYXYX. Also, the number of 1's and 2's in any word of length 10 is 4, 5 or 6 (see comments in A000002).  JeanChristophe Hervé, Oct 21 2014


REFERENCES

Mathematische Semesterberichte 44 94 1997.


LINKS



FORMULA



EXAMPLE

We illustrate how this sequence and A025143 can be constructed from each other. Start with two 1's in this sequence: a(1) = a(2) = 1 (and thus a(3) = 2), which gives A025143(1) = 2 (first run length of this sequence), followed by a 1 because a(1) = 1 is also the first run length of A025143; thus a(4) = 1, which gives A025143(3) = 2, which in turn gives a(5) = 1 and a(6) = 2, etc.  JeanChristophe Hervé, Oct 21 2014


PROG

(R) seq < function(n) {
k2< k1 < rep(0, n+2)
c1<w2< 1
w1<c2<k1[1]<2
while(w2<=n){
while(c1<w1) {
x<(c11)%%2+1
k2[w2]<x
w2<w2+1
if(k1[c1]==2) {
k2[w2]<x
w2<w2+1}
c1<c1+1}
while(c2<w2 && w1<=n) {
x<c2%%2+1
k1[w1]<x
w1<w1+1
if(k2[c2]==2) {
k1[w1]<x
w1<w1+1}
c2<c2+1}}


CROSSREFS



KEYWORD

nonn


AUTHOR



EXTENSIONS



STATUS

approved



