Consider the process of taking a number, taking its digit sum, then adding the digits of numbers derived from
it, etc., until the remaining number has only one digit.
The number of additions required to obtain a single digit
from a number
in a given base is called the additive persistence
of
, and the digit
obtained is called the digital root of
.
For example, the sequence obtained from the starting number 9876 in base 10 is (9876, 30, 3), so 9876 has an additive persistence
of 2 and a digital root of 3. The base-10 digital roots of the first few integers
are 1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 2, 3, 4, 5, 6, 7, 8, 9, 1, ... (OEIS A010888).
The digital root
of an integer
can be computed without actually performing the iteration
using the simple congruence formula
(1)
| |||
(2)
|