What are the divisors of 620?
1, 2, 4, 5, 10, 20, 31, 62, 124, 155, 310, 620
- There is a total of 12 positive divisors.
- The sum of these divisors is 1344.
- The arithmetic mean is 112.
8 even divisors
2, 4, 10, 20, 62, 124, 310, 620
4 odd divisors
1, 5, 31, 155
How to compute the divisors of 620?
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 620 by each of the numbers from 1 to 620 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 620 / 1 = 620 (the remainder is 0, so 1 is a divisor of 620)
- 620 / 2 = 310 (the remainder is 0, so 2 is a divisor of 620)
- 620 / 3 = 206.66666666667 (the remainder is 2, so 3 is not a divisor of 620)
- ...
- 620 / 619 = 1.0016155088853 (the remainder is 1, so 619 is not a divisor of 620)
- 620 / 620 = 1 (the remainder is 0, so 620 is a divisor of 620)
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 620 (i.e. 24.899799195977). 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 )
- 620 / 1 = 620 (the remainder is 0, so 1 and 620 are divisors of 620)
- 620 / 2 = 310 (the remainder is 0, so 2 and 310 are divisors of 620)
- 620 / 3 = 206.66666666667 (the remainder is 2, so 3 is not a divisor of 620)
- ...
- 620 / 23 = 26.95652173913 (the remainder is 22, so 23 is not a divisor of 620)
- 620 / 24 = 25.833333333333 (the remainder is 20, so 24 is not a divisor of 620)