What are the divisors of 5799?
1, 3, 1933, 5799
- There is a total of 4 positive divisors.
- The sum of these divisors is 7736.
- The arithmetic mean is 1934.
4 odd divisors
1, 3, 1933, 5799
How to compute the divisors of 5799?
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 5799 by each of the numbers from 1 to 5799 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 5799 / 1 = 5799 (the remainder is 0, so 1 is a divisor of 5799)
- 5799 / 2 = 2899.5 (the remainder is 1, so 2 is not a divisor of 5799)
- 5799 / 3 = 1933 (the remainder is 0, so 3 is a divisor of 5799)
- ...
- 5799 / 5798 = 1.0001724732666 (the remainder is 1, so 5798 is not a divisor of 5799)
- 5799 / 5799 = 1 (the remainder is 0, so 5799 is a divisor of 5799)
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 5799 (i.e. 76.151165453984). 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 )
- 5799 / 1 = 5799 (the remainder is 0, so 1 and 5799 are divisors of 5799)
- 5799 / 2 = 2899.5 (the remainder is 1, so 2 is not a divisor of 5799)
- 5799 / 3 = 1933 (the remainder is 0, so 3 and 1933 are divisors of 5799)
- ...
- 5799 / 75 = 77.32 (the remainder is 24, so 75 is not a divisor of 5799)
- 5799 / 76 = 76.302631578947 (the remainder is 23, so 76 is not a divisor of 5799)