What are the divisors of 5420?
1, 2, 4, 5, 10, 20, 271, 542, 1084, 1355, 2710, 5420
- There is a total of 12 positive divisors.
- The sum of these divisors is 11424.
- The arithmetic mean is 952.
8 even divisors
2, 4, 10, 20, 542, 1084, 2710, 5420
4 odd divisors
1, 5, 271, 1355
How to compute the divisors of 5420?
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 5420 by each of the numbers from 1 to 5420 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 5420 / 1 = 5420 (the remainder is 0, so 1 is a divisor of 5420)
- 5420 / 2 = 2710 (the remainder is 0, so 2 is a divisor of 5420)
- 5420 / 3 = 1806.6666666667 (the remainder is 2, so 3 is not a divisor of 5420)
- ...
- 5420 / 5419 = 1.0001845358922 (the remainder is 1, so 5419 is not a divisor of 5420)
- 5420 / 5420 = 1 (the remainder is 0, so 5420 is a divisor of 5420)
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 5420 (i.e. 73.620649277224). 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 )
- 5420 / 1 = 5420 (the remainder is 0, so 1 and 5420 are divisors of 5420)
- 5420 / 2 = 2710 (the remainder is 0, so 2 and 2710 are divisors of 5420)
- 5420 / 3 = 1806.6666666667 (the remainder is 2, so 3 is not a divisor of 5420)
- ...
- 5420 / 72 = 75.277777777778 (the remainder is 20, so 72 is not a divisor of 5420)
- 5420 / 73 = 74.246575342466 (the remainder is 18, so 73 is not a divisor of 5420)