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 A050104 #17 Feb 16 2025 08:32:40 %S A050104 1,3,9,2,6,18,4,12,36,108,27,81,20,5,15,45,11,33,8,24,72,216,54,13,39, %T A050104 117,29,7,21,63,189,47,141,35,105,26,78,19,57,14,42,10,30,90,22,66,16, %U A050104 48,144,432,1296,324,972,243,60,180,540,135 %N A050104 a(n) = floor(a(n-1)/4) if this is not among 0, a(1), ..., a(n-2); otherwise a(n) = 3*a(n-1). %H A050104 Ivan Neretin, <a href="/A050104/b050104.txt">Table of n, a(n) for n = 1..10000</a> %H A050104 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Digit.html">Digit.</a> %t A050104 Rest@Nest[Append[#, If[FreeQ[#, r = Quotient[#[[-1]], 4]], r, 3 #[[-1]]]] &, {0, 1}, 57] (* _Ivan Neretin_, Jul 31 2016 *) %Y A050104 Cf. A050000 and references therein. %K A050104 nonn %O A050104 1,2 %A A050104 _Clark Kimberling_