What are the divisors of 9007?
1, 9007
- There is a total of 2 positive divisors.
- The sum of these divisors is 9008.
- The arithmetic mean is 4504.
2 odd divisors
1, 9007
How to compute the divisors of 9007?
A number N is said to be divisible by a number M (with M non-zero) if, when we divide N by M, the remainder of the division is zero.
Brute force algorithm
We could start by using a brute-force method which would involve dividing 9007 by each of the numbers from 1 to 9007 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 9007 / 1 = 9007 (the remainder is 0, so 1 is a divisor of 9007)
- 9007 / 2 = 4503.5 (the remainder is 1, so 2 is not a divisor of 9007)
- 9007 / 3 = 3002.3333333333 (the remainder is 1, so 3 is not a divisor of 9007)
- ...
- 9007 / 9006 = 1.0001110370864 (the remainder is 1, so 9006 is not a divisor of 9007)
- 9007 / 9007 = 1 (the remainder is 0, so 9007 is a divisor of 9007)
Improved algorithm using square-root
However, there is another slightly better approach that reduces the number of iterations by testing only integers less than or equal to the square root of 9007 (i.e. 94.905215873523). Indeed, if a number N has a divisor D greater than its square root, then there is necessarily a smaller divisor d such that:
(thus, if , then )
- 9007 / 1 = 9007 (the remainder is 0, so 1 and 9007 are divisors of 9007)
- 9007 / 2 = 4503.5 (the remainder is 1, so 2 is not a divisor of 9007)
- 9007 / 3 = 3002.3333333333 (the remainder is 1, so 3 is not a divisor of 9007)
- ...
- 9007 / 93 = 96.849462365591 (the remainder is 79, so 93 is not a divisor of 9007)
- 9007 / 94 = 95.81914893617 (the remainder is 77, so 94 is not a divisor of 9007)