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 A053830 #45 Feb 16 2025 08:32:42 %S A053830 0,1,2,3,4,5,6,7,8,1,2,3,4,5,6,7,8,9,2,3,4,5,6,7,8,9,10,3,4,5,6,7,8,9, %T A053830 10,11,4,5,6,7,8,9,10,11,12,5,6,7,8,9,10,11,12,13,6,7,8,9,10,11,12,13, %U A053830 14,7,8,9,10,11,12,13,14,15,8,9,10,11,12,13,14,15,16,1,2,3,4,5,6,7,8,9 %N A053830 Sum of digits of (n written in base 9). %C A053830 Also the fixed point of the morphism 0->{0,1,2,3,4,5,6,7,8}, 1->{1,2,3,4,5,6,7,8,9}, 2->{2,3,4,5,6,7,8,9,10}, etc. - _Robert G. Wilson v_, Jul 27 2006 %H A053830 Indranil Ghosh, <a href="/A053830/b053830.txt">Table of n, a(n) for n = 0..59049</a> %H A053830 Jeffrey O. Shallit, <a href="http://www.jstor.org/stable/2322179">Problem 6450</a>, Advanced Problems, The American Mathematical Monthly, Vol. 91, No. 1 (1984), pp. 59-60; <a href="http://www.jstor.org/stable/2322523">Two series, solution to Problem 6450</a>, ibid., Vol. 92, No. 7 (1985), pp. 513-514. %H A053830 Robert Walker, <a href="http://robertinventor.com/ftswiki/Self_Similar_Sloth_Canon_Number_Sequences">Self Similar Sloth Canon Number Sequences</a>. %H A053830 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/DigitSum.html">Digit Sum</a>. %F A053830 From _Benoit Cloitre_, Dec 19 2002: (Start) %F A053830 a(0) = 0, a(9n+i) = a(n) + i for 0 <= i <= 8; %F A053830 a(n) = n - 8*Sum_{k>=1} floor(n/9^k) = n - 8*A054898(n). (End) %F A053830 a(n) = A138530(n,9) for n > 8. - _Reinhard Zumkeller_, Mar 26 2008 %F A053830 a(n) = Sum_{k>=0} A031087(n,k). - _Philippe Deléham_, Oct 21 2011 %F A053830 a(0) = 0; a(n) = a(n - 9^floor(log_9(n))) + 1. - _Ilya Gutkovskiy_, Aug 24 2019 %F A053830 Sum_{n>=1} a(n)/(n*(n+1)) = 9*log(9)/8 (Shallit, 1984). - _Amiram Eldar_, Jun 03 2021 %e A053830 a(20) = 2+2 = 4 because 20 is written as 22 base 9. %e A053830 From _Omar E. Pol_, Feb 23 2010: (Start) %e A053830 It appears that this can be written as a triangle (see the conjecture in the entry A000120): %e A053830 0; %e A053830 1,2,3,4,5,6,7,8; %e A053830 1,2,3,4,5,6,7,8,9,2,3,4,5,6,7,8,9,10,3,4,5,6,7,8,9,10,11,4,5,6,7,8,9,10,11,... %e A053830 where the rows converge to A173529. (End) %t A053830 Table[Plus @@ IntegerDigits[n, 9], {n, 0, 100}] (* or *) %t A053830 Nest[ Flatten[ #1 /. a_Integer -> Table[a + i, {i, 0, 8}]] &, {0}, 3] (* _Robert G. Wilson v_, Jul 27 2006 *) %o A053830 (PARI) a(n)=if(n<1,0,if(n%9,a(n-1)+1,a(n/9))) %o A053830 (Magma) [&+Intseq(n, 9):n in [0..100]]; // _Marius A. Burtea_, Aug 24 2019 %Y A053830 Cf. A000120, A007953, A053735, A053737, A053824, A053828, A231684, A231685, A231686, A231687. %Y A053830 Cf. A173529. - _Omar E. Pol_, Feb 23 2010 %K A053830 base,nonn %O A053830 0,3 %A A053830 _Henry Bottomley_, Mar 28 2000