What are the divisors of 2240?
1, 2, 4, 5, 7, 8, 10, 14, 16, 20, 28, 32, 35, 40, 56, 64, 70, 80, 112, 140, 160, 224, 280, 320, 448, 560, 1120, 2240
- There is a total of 28 positive divisors.
- The sum of these divisors is 6096.
- The arithmetic mean is 217.71428571429.
24 even divisors
2, 4, 8, 10, 14, 16, 20, 28, 32, 40, 56, 64, 70, 80, 112, 140, 160, 224, 280, 320, 448, 560, 1120, 2240
4 odd divisors
1, 5, 7, 35
How to compute the divisors of 2240?
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 2240 by each of the numbers from 1 to 2240 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2240 / 1 = 2240 (the remainder is 0, so 1 is a divisor of 2240)
- 2240 / 2 = 1120 (the remainder is 0, so 2 is a divisor of 2240)
- 2240 / 3 = 746.66666666667 (the remainder is 2, so 3 is not a divisor of 2240)
- ...
- 2240 / 2239 = 1.0004466279589 (the remainder is 1, so 2239 is not a divisor of 2240)
- 2240 / 2240 = 1 (the remainder is 0, so 2240 is a divisor of 2240)
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 2240 (i.e. 47.328638264797). 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 )
- 2240 / 1 = 2240 (the remainder is 0, so 1 and 2240 are divisors of 2240)
- 2240 / 2 = 1120 (the remainder is 0, so 2 and 1120 are divisors of 2240)
- 2240 / 3 = 746.66666666667 (the remainder is 2, so 3 is not a divisor of 2240)
- ...
- 2240 / 46 = 48.695652173913 (the remainder is 32, so 46 is not a divisor of 2240)
- 2240 / 47 = 47.659574468085 (the remainder is 31, so 47 is not a divisor of 2240)