What are the divisors of 801?
1, 3, 9, 89, 267, 801
- There is a total of 6 positive divisors.
- The sum of these divisors is 1170.
- The arithmetic mean is 195.
6 odd divisors
1, 3, 9, 89, 267, 801
How to compute the divisors of 801?
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 801 by each of the numbers from 1 to 801 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 801 / 1 = 801 (the remainder is 0, so 1 is a divisor of 801)
- 801 / 2 = 400.5 (the remainder is 1, so 2 is not a divisor of 801)
- 801 / 3 = 267 (the remainder is 0, so 3 is a divisor of 801)
- ...
- 801 / 800 = 1.00125 (the remainder is 1, so 800 is not a divisor of 801)
- 801 / 801 = 1 (the remainder is 0, so 801 is a divisor of 801)
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 801 (i.e. 28.30194339617). 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 )
- 801 / 1 = 801 (the remainder is 0, so 1 and 801 are divisors of 801)
- 801 / 2 = 400.5 (the remainder is 1, so 2 is not a divisor of 801)
- 801 / 3 = 267 (the remainder is 0, so 3 and 267 are divisors of 801)
- ...
- 801 / 27 = 29.666666666667 (the remainder is 18, so 27 is not a divisor of 801)
- 801 / 28 = 28.607142857143 (the remainder is 17, so 28 is not a divisor of 801)