login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A354760
a(0) = 0; for n >= 1, a(n) = a(n - A054055(n)) + 1.
0
0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13
OFFSET
0,11
COMMENTS
Number of steps needed to reach zero when starting from k = n and repeatedly applying the map that replaces k by k - A054055(k). a(n) ~ n/ln(n).
EXAMPLE
n = 12, a(12) = 1 + a(12 - A054055(12)) = 1 + a(10) = 1 + 1 + a(10 - A054055(10)) = 2 + a(9) = 2 + 1 + a(9 - A054055(9)) = 2 + 1 + 0 = 3.
MATHEMATICA
a[0] = 0; a[n_] := a[n] = a[n - Max[IntegerDigits[n]]] + 1; Array[a, 100, 0] (* Amiram Eldar, Jun 06 2022 *)
CROSSREFS
Cf. A054055.
Sequence in context: A121242 A185436 A025794 * A025793 A102680 A025791
KEYWORD
base,easy,nonn
AUTHOR
Ctibor O. Zizka, Jun 06 2022
STATUS
approved