OFFSET
0,3
COMMENTS
Compare with obvious base-2 analog. What is the general base-k formula?
LINKS
Michael De Vlieger, Table of n, a(n) for n = 0..10000
FORMULA
a(n) = Sum_{i=0..n} (maximal digit in base-3 expansion of i).
a(n) = 3n + O(n^0.631). - Charles R Greathouse IV, Aug 21 2011
MATHEMATICA
Accumulate@ Array[Max@ IntegerDigits[#, 3] &, 105, 0] (* Michael De Vlieger, Feb 15 2020 *)
CROSSREFS
KEYWORD
nonn,easy,base
AUTHOR
Jonathan Vos Post, May 24 2011
STATUS
approved