|
|
A093914
|
|
a(1) = 1; for n > 1, a(n) = curling number of (b(1),...,b(n-1)), where b() = Thue-Morse sequence A010060 (with offset changed to 1).
|
|
4
|
|
|
1, 1, 1, 2, 1, 1, 2, 2, 1, 2, 1, 2, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 2, 2, 1, 2, 2, 1, 2, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 2, 2, 1, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 1, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 1, 2, 2, 2, 2, 2, 2
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,4
|
|
COMMENTS
|
The curling number of a finite string S = (s(1),...,s(n)) is the largest integer k such that S can be written as xy^k for strings x and y (where y has positive length).
The sequence consists of 1's and 2's only.
If 2^k>=n-1, then a(n+2^k)>=a(n).
The density of 1's seems to converge to 1/6.
(End)
|
|
LINKS
|
F. J. van de Bult, D. C. Gijswijt, J. P. Linderman, N. J. A. Sloane and Allan Wilks, A Slow-Growing Sequence Defined by an Unusual Recurrence [pdf, ps].
|
|
PROG
|
(Python)
p, tm, s = 8, 0, 1
for i in range(p):
tm += (tm^((1<<s)-1))<<s
s *= 2
print(1)
for i in range(1, 1<<p):
a = any(((tm>>(i-j))&((1<<j)-1)) == ((tm>>(i-2*j))&((1<<j)-1)) for j in range(1, i//2+1))
print(2 if a else 1)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|