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 A191255 #45 May 31 2024 14:38:05 %S A191255 0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,2,0,1, %T A191255 0,2,0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,3,0,1,0,2, %U A191255 0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,2,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2,0,1,0,3,0,1,0,2,0,1,0,1,0,1,0,2 %N A191255 Fixed point of the morphism 0 -> 01, 1 -> 02, 2 -> 03, 3 -> 01. %C A191255 See A191250. %C A191255 The asymptotic density of the occurrences of k = 0, 1, 2 and 3 is 1/2, 2/7, 1/7 and 1/14, respectively. The asymptotic mean of this sequence is 11/14. - _Amiram Eldar_, May 31 2024 %H A191255 Antti Karttunen, <a href="/A191255/b191255.txt">Table of n, a(n) for n = 1..65537</a> %F A191255 a(n) = 0 for odd n, otherwise a(n) is the unique number in {1,2,3} that is congruent to v2(n) modulo 3, where v2(n) = A007814(n) is the 2-adic valuation of n. - _Jianing Song_, Sep 21 2018 [Clarified by _Jianing Song_, May 30 2024] %F A191255 Recurrence: a(2n-1) = 0, a(2n) = 1, 2, 3, 1 for a(n) = 0, 1, 2, 3 respectively. - _Jianing Song_, May 30 2024 %t A191255 t = Nest[Flatten[# /. {0 -> {0, 1}, 1 -> {0, 2}, 2 -> {0, 3}, 3 -> {0, 1}}] &, {0}, 9] (* this sequence *) %t A191255 Flatten[Position[t, 0]] (* A005408, the odds *) %t A191255 a = Flatten[Position[t, 1]] (* A067368 *) %t A191255 b = Flatten[Position[t, 2]] (* A213258 *) %t A191255 a/2 (* A191257 *) %t A191255 b/4 (* a/2 *) %o A191255 (PARI) A191255(n) = if(n%2, 0, my(e=valuation(n, 2)%3); if(!e, 3, e)); \\ _Antti Karttunen_, May 28 2024, after _Jianing Song_'s Sep 21 2018 formula %Y A191255 Cf. A191250, A191254, A373157. %Y A191255 Positions of 0 or 3: A191257; positions of 0: A005408; positions of 1: A067368; positions of 2: A213258. %K A191255 nonn %O A191255 1,4 %A A191255 _Clark Kimberling_, May 28 2011