What are the divisors of 5889?
1, 3, 13, 39, 151, 453, 1963, 5889
- There is a total of 8 positive divisors.
- The sum of these divisors is 8512.
- The arithmetic mean is 1064.
8 odd divisors
1, 3, 13, 39, 151, 453, 1963, 5889
How to compute the divisors of 5889?
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 5889 by each of the numbers from 1 to 5889 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 5889 / 1 = 5889 (the remainder is 0, so 1 is a divisor of 5889)
- 5889 / 2 = 2944.5 (the remainder is 1, so 2 is not a divisor of 5889)
- 5889 / 3 = 1963 (the remainder is 0, so 3 is a divisor of 5889)
- ...
- 5889 / 5888 = 1.0001698369565 (the remainder is 1, so 5888 is not a divisor of 5889)
- 5889 / 5889 = 1 (the remainder is 0, so 5889 is a divisor of 5889)
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 5889 (i.e. 76.739820171799). 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 )
- 5889 / 1 = 5889 (the remainder is 0, so 1 and 5889 are divisors of 5889)
- 5889 / 2 = 2944.5 (the remainder is 1, so 2 is not a divisor of 5889)
- 5889 / 3 = 1963 (the remainder is 0, so 3 and 1963 are divisors of 5889)
- ...
- 5889 / 75 = 78.52 (the remainder is 39, so 75 is not a divisor of 5889)
- 5889 / 76 = 77.486842105263 (the remainder is 37, so 76 is not a divisor of 5889)