A071928 Kolakoski-(2,4) sequence: a(n) is length of n-th run.
2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 4, 4, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 4, 4, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 4, 4, 2, 2, 4, 4, 2, 2, 2, 2, 4, 4, 4, 4, 2, 2, 2, 2, 4
Offset: 1
Links
- Ivan Neretin, Table of n, a(n) for n = 1..10000
- Michael Baake and Bernd Sing, Kolakoski-(3,1) is a (deformed) model set, arXiv:math/0206098 [math.MG], 2002-2003.
- Bernd Sing, Kolakoski-(2m,2n) are limit-periodic model sets, arXiv:math-ph/0207037, 2002-2003.
Programs
-
Mathematica
seed = {2, 4}; w = {}; i = 1; Do[w = Join[w,Array[seed[[Mod[i - 1, Length[seed]] + 1]] &, If[i > Length[w], seed, w][[i]]]]; i++, {n, 36}]; w (* Ivan Neretin, Apr 02 2015 *)
Formula
Generated by infinitely iterating the morphism a->abc, b->dab, c->efg, d->hcd, e->cda, f->bef, g->ghc, h->dab starting with a, obtaining the infinite word abcdabefg..., and then replacing a,b,e,f by 2 and c,d,g,h by 4. - Jeffrey Shallit, Dec 31 2024
Extensions
More terms from Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Sep 08 2002