What are the divisors of 624?
1, 2, 3, 4, 6, 8, 12, 13, 16, 24, 26, 39, 48, 52, 78, 104, 156, 208, 312, 624
- There is a total of 20 positive divisors.
- The sum of these divisors is 1736.
- The arithmetic mean is 86.8.
16 even divisors
2, 4, 6, 8, 12, 16, 24, 26, 48, 52, 78, 104, 156, 208, 312, 624
4 odd divisors
1, 3, 13, 39
How to compute the divisors of 624?
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 624 by each of the numbers from 1 to 624 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 624 / 1 = 624 (the remainder is 0, so 1 is a divisor of 624)
- 624 / 2 = 312 (the remainder is 0, so 2 is a divisor of 624)
- 624 / 3 = 208 (the remainder is 0, so 3 is a divisor of 624)
- ...
- 624 / 623 = 1.0016051364366 (the remainder is 1, so 623 is not a divisor of 624)
- 624 / 624 = 1 (the remainder is 0, so 624 is a divisor of 624)
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 624 (i.e. 24.979991993594). 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 )
- 624 / 1 = 624 (the remainder is 0, so 1 and 624 are divisors of 624)
- 624 / 2 = 312 (the remainder is 0, so 2 and 312 are divisors of 624)
- 624 / 3 = 208 (the remainder is 0, so 3 and 208 are divisors of 624)
- ...
- 624 / 23 = 27.130434782609 (the remainder is 3, so 23 is not a divisor of 624)
- 624 / 24 = 26 (the remainder is 0, so 24 and 26 are divisors of 624)