login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A241979
(0,1) sequence such that lengths of three consecutive runs are always distinct.
1
0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1
OFFSET
0
COMMENTS
Periodic with period 12;
a(n+6) = 1 - a(n).
EXAMPLE
. a(n): 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0
. runs: 0, 11, 000, 1, 00, 111, 0, 11, 000, 1, 00
. lengths: 1, 2, 3, 1, 2, 3, 1, 2, 3, 1, 2
MATHEMATICA
LinearRecurrence[{1, 0, 0, 0, 0, -1, 1}, {0, 1, 1, 0, 0, 0, 1}, 108] (* Ray Chandler, Aug 27 2015 *)
PROG
(Haskell)
a241979 n = a241979_list !! n
a241979_list = cycle [0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 1, 1]
CROSSREFS
Cf. A010882 (run lengths).
Sequence in context: A280910 A305816 A359820 * A200244 A261185 A093692
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Aug 10 2014
EXTENSIONS
Extended by Ray Chandler, Aug 27 2015
STATUS
approved