This article includes a list of references, related reading, or external links, but its sources remain unclear because it lacks inline citations .(January 2016) |
The digital root (also repeated digital sum) of a natural number in a given radix is the (single digit) value obtained by an iterative process of summing digits, on each iteration using the result from the previous iteration to compute a digit sum. The process continues until a single-digit number is reached. For example, in base 10, the digital root of the number 12345 is 6 because the sum of the digits in the number is 1 + 2 + 3 + 4 + 5 = 15, then the addition process is repeated again for the resulting number 15, so that the sum of 1 + 5 equals 6, which is the digital root of that number. In base 10, this is equivalent to taking the remainder upon division by 9 (except when the digital root is 9, where the remainder upon division by 9 will be 0), which allows it to be used as a divisibility rule.
Let be a natural number. For base , we define the digit sum to be the following:
where is the number of digits in the number in base , and
is the value of each digit of the number. A natural number is a digital root if it is a fixed point for , which occurs if .
All natural numbers are preperiodic points for , regardless of the base. This is because if , then
and therefore
because . If , then trivially
Therefore, the only possible digital roots are the natural numbers , and there are no cycles other than the fixed points of .
In base 12, 8 is the additive digital root of the base 10 number 3110, as for
This process shows that 3110 is 1972 in base 12. Now for
shows that 19 is 17 in base 12. And as 8 is a 1-digit number in base 12,
We can define the digit root directly for base in the following ways:
The formula in base is:
or,
In base 10, the corresponding sequence is (sequence A010888 in the OEIS ).
The digital root is the value modulo because and thus so regardless of position, the value is the same – – which is why digits can be meaningfully added. Concretely, for a three-digit number
To obtain the modular value with respect to other numbers , one can take weighted sums, where the weight on the -th digit corresponds to the value of modulo . In base 10, this is simplest for 2, 5, and 10, where higher digits vanish (since 2 and 5 divide 10), which corresponds to the familiar fact that the divisibility of a decimal number with respect to 2, 5, and 10 can be checked by the last digit (even numbers end in 0, 2, 4, 6, or 8).
Also of note is the modulus : since and thus taking the alternating sum of digits yields the value modulo .
It helps to see the digital root of a positive integer as the position it holds with respect to the largest multiple of less than the number itself. For example, in base 6 the digital root of 11 is 2, which means that 11 is the second number after . Likewise, in base 10 the digital root of 2035 is 1, which means that . If a number produces a digital root of exactly , then the number is a multiple of .
With this in mind the digital root of a positive integer may be defined by using floor function , as
The additive persistence counts how many times we must sum its digits to arrive at its digital root.
For example, the additive persistence of 2718 in base 10 is 2: first we find that 2 + 7 + 1 + 8 = 18, then that 1 + 8 = 9.
There is no limit to the additive persistence of a number in a number base . Proof: For a given number , the persistence of the number consisting of repetitions of the digit 1 is 1 higher than that of . The smallest numbers of additive persistence 0, 1, ... in base 10 are:
The next number in the sequence (the smallest number of additive persistence 5) is 2 × 102×(1022 − 1)/9 − 1 (that is, 1 followed by 2 222 222 222 222 222 222 222 nines). For any fixed base, the sum of the digits of a number is proportional to its logarithm; therefore, the additive persistence is proportional to the iterated logarithm. [1]
The example below implements the digit sum described in the definition above to search for digital roots and additive persistences in Python.
defdigit_sum(x:int,b:int)->int:total=0whilex>0:total=total+(x%b)x=x//breturntotaldefdigital_root(x:int,b:int)->int:seen=set()whilexnotinseen:seen.add(x)x=digit_sum(x,b)returnxdefadditive_persistence(x:int,b:int)->int:seen=set()whilexnotinseen:seen.add(x)x=digit_sum(x,b)returnlen(seen)-1
Digital roots are used in Western numerology, but certain numbers deemed to have occult significance (such as 11 and 22) are not always completely reduced to a single digit.
Digital roots form an important mechanic in the visual novel adventure game Nine Hours, Nine Persons, Nine Doors .
In mathematics, the Chinese remainder theorem states that if one knows the remainders of the Euclidean division of an integer n by several integers, then one can determine uniquely the remainder of the division of n by the product of these integers, under the condition that the divisors are pairwise coprime.
In number theory, the law of quadratic reciprocity is a theorem about modular arithmetic that gives conditions for the solvability of quadratic equations modulo prime numbers. Due to its subtlety, it has many formulations, but the most standard statement is:
In recreational mathematics, a Keith number or repfigit number is a natural number in a given number base with digits such that when a sequence is created such that the first terms are the digits of and each subsequent term is the sum of the previous terms, is part of the sequence. Keith numbers were introduced by Mike Keith in 1987. They are computationally very challenging to find, with only about 100 known.
Casting out nines is any of three arithmetical procedures:
In number theory, a self number or Devlali number in a given number base is a natural number that cannot be written as the sum of any other natural number and the individual digits of . 20 is a self number, because no such combination can be found. 21 is not, because it can be written as 15 + 1 + 5 using n = 15. These numbers were first described in 1949 by the Indian mathematician D. R. Kaprekar.
In mathematical notation for numbers, a signed-digit representation is a positional numeral system with a set of signed digits used to encode the integers.
The Ramanujan tau function, studied by Ramanujan (1916), is the function defined by the following identity:
The Schönhage–Strassen algorithm is an asymptotically fast multiplication algorithm for large integers, published by Arnold Schönhage and Volker Strassen in 1971. It works by recursively applying fast Fourier transform (FFT) over the integers modulo 2n+1. The run-time bit complexity to multiply two n-digit numbers using the algorithm is in big O notation.
In mathematics, the digit sum of a natural number in a given number base is the sum of all its digits. For example, the digit sum of the decimal number would be
In mathematics, Hensel's lemma, also known as Hensel's lifting lemma, named after Kurt Hensel, is a result in modular arithmetic, stating that if a univariate polynomial has a simple root modulo a prime number p, then this root can be lifted to a unique root modulo any higher power of p. More generally, if a polynomial factors modulo p into two coprime polynomials, this factorization can be lifted to a factorization modulo any higher power of p.
In number theory, a Dudeney number in a given number base is a natural number equal to the perfect cube of another natural number such that the digit sum of the first natural number is equal to the second. The name derives from Henry Dudeney, who noted the existence of these numbers in one of his puzzles, Root Extraction, where a professor in retirement at Colney Hatch postulates this as a general method for root extraction.
The Tonelli–Shanks algorithm is used in modular arithmetic to solve for r in a congruence of the form r2 ≡ n, where p is a prime: that is, to find a square root of n modulo p.
In number theory, a narcissistic number in a given number base is a number that is the sum of its own digits each raised to the power of the number of digits.
A sum-product number in a given number base is a natural number that is equal to the product of the sum of its digits and the product of its digits.
In mathematics, a Witt vector is an infinite sequence of elements of a commutative ring. Ernst Witt showed how to put a ring structure on the set of Witt vectors, in such a way that the ring of Witt vectors over the finite field of order is isomorphic to , the ring of -adic integers. They have a highly non-intuitive structure upon first glance because their additive and multiplicative structure depends on an infinite set of recursive formulas which do not behave like addition and multiplication formulas for standard p-adic integers.
In number theory, the multiplicative digital root of a natural number in a given number base is found by multiplying the digits of together, then repeating this operation until only a single-digit remains, which is called the multiplicative digital root of . The multiplicative digital root for the first few positive integers are:
In number theory, a factorion in a given number base is a natural number that equals the sum of the factorials of its digits. The name factorion was coined by the author Clifford A. Pickover.
In computational number theory, Cipolla's algorithm is a technique for solving a congruence of the form
In number theory and mathematical logic, a Meertens number in a given number base is a natural number that is its own Gödel number. It was named after Lambert Meertens by Richard S. Bird as a present during the celebration of his 25 years at the CWI, Amsterdam.
In number theory, a perfect digital invariant (PDI) is a number in a given number base () that is the sum of its own digits each raised to a given power ().