What are the divisors of 2788?
1, 2, 4, 17, 34, 41, 68, 82, 164, 697, 1394, 2788
- There is a total of 12 positive divisors.
- The sum of these divisors is 5292.
- The arithmetic mean is 441.
8 even divisors
2, 4, 34, 68, 82, 164, 1394, 2788
4 odd divisors
1, 17, 41, 697
How to compute the divisors of 2788?
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 2788 by each of the numbers from 1 to 2788 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2788 / 1 = 2788 (the remainder is 0, so 1 is a divisor of 2788)
- 2788 / 2 = 1394 (the remainder is 0, so 2 is a divisor of 2788)
- 2788 / 3 = 929.33333333333 (the remainder is 1, so 3 is not a divisor of 2788)
- ...
- 2788 / 2787 = 1.0003588087549 (the remainder is 1, so 2787 is not a divisor of 2788)
- 2788 / 2788 = 1 (the remainder is 0, so 2788 is a divisor of 2788)
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 2788 (i.e. 52.801515129776). 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 )
- 2788 / 1 = 2788 (the remainder is 0, so 1 and 2788 are divisors of 2788)
- 2788 / 2 = 1394 (the remainder is 0, so 2 and 1394 are divisors of 2788)
- 2788 / 3 = 929.33333333333 (the remainder is 1, so 3 is not a divisor of 2788)
- ...
- 2788 / 51 = 54.666666666667 (the remainder is 34, so 51 is not a divisor of 2788)
- 2788 / 52 = 53.615384615385 (the remainder is 32, so 52 is not a divisor of 2788)