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 A287576 #4 Jun 01 2017 21:09:12 %S A287576 0,3,2,1,1,0,3,2,2,1,0,3,3,2,1,0,3,2,1,0,0,3,2,1,1,0,3,2,2,1,0,3,2,1, %T A287576 0,3,3,2,1,0,0,3,2,1,1,0,3,2,1,0,3,2,2,1,0,3,3,2,1,0,0,3,2,1,1,0,3,2, %U A287576 2,1,0,3,3,2,1,0,0,3,2,1,0,3,2,1,1,0 %N A287576 Start with 0 and repeatedly substitute 0->0321, 1->3210, 2->2103, 3->1032. %C A287576 This is the fixed point of the morphism 0->0231, 1->2310, 2->3102, 3->1023 starting with 0. Let t be the (nonperiodic) sequence of positions of 0, and likewise, u for 1, v for 2, and w for 3; then t(n)/n -> 4, u(n)/n -> 4, v(n)/n -> 4, w(n)/n -> 4. Also, t(n) + u(n) + v(n) + w(n) = 16*n - 6 for n >= 1. See A287556 for a guide to related sequences. %H A287576 Clark Kimberling, <a href="/A287576/b287576.txt">Table of n, a(n) for n = 1..20000</a> %H A287576 <a href="/index/Fi#FIXEDPOINTS">Index entries for sequences that are fixed points of mappings</a> %F A287576 a(n) = 4n - A287578(n) for n >= 1. %e A287576 First three iterations of the morphism: %e A287576 0321 %e A287576 0321103221033210 %e A287576 0321103221033210321003211032210321033210032110321032210332100321 %t A287576 s = Nest[Flatten[# /. {0 -> {0,3,2,1}, 1 -> {3,2,1,0}, 2 -> {2,1,0,3}, 3 -> {1,0,3,2}}] &, {0}, 9]; (* A287576 *) %t A287576 Flatten[Position[s, 0]]; (* A287577 *) %t A287576 Flatten[Position[s, 1]]; (* A287578 *) %t A287576 Flatten[Position[s, 2]]; (* A287579 *) %t A287576 Flatten[Position[s, 3]]; (* A287580 *) %Y A287576 Cf. A287577, A287578, A287579, A287580. %K A287576 nonn,easy %O A287576 1,2 %A A287576 _Clark Kimberling_, Jun 01 2017