What are the divisors of 2112?
1, 2, 3, 4, 6, 8, 11, 12, 16, 22, 24, 32, 33, 44, 48, 64, 66, 88, 96, 132, 176, 192, 264, 352, 528, 704, 1056, 2112
- 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, 6, 8, 12, 16, 22, 24, 32, 44, 48, 64, 66, 88, 96, 132, 176, 192, 264, 352, 528, 704, 1056, 2112
4 odd divisors
1, 3, 11, 33
How to compute the divisors of 2112?
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 2112 by each of the numbers from 1 to 2112 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2112 / 1 = 2112 (the remainder is 0, so 1 is a divisor of 2112)
- 2112 / 2 = 1056 (the remainder is 0, so 2 is a divisor of 2112)
- 2112 / 3 = 704 (the remainder is 0, so 3 is a divisor of 2112)
- ...
- 2112 / 2111 = 1.0004737091426 (the remainder is 1, so 2111 is not a divisor of 2112)
- 2112 / 2112 = 1 (the remainder is 0, so 2112 is a divisor of 2112)
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 2112 (i.e. 45.956501172304). 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 )
- 2112 / 1 = 2112 (the remainder is 0, so 1 and 2112 are divisors of 2112)
- 2112 / 2 = 1056 (the remainder is 0, so 2 and 1056 are divisors of 2112)
- 2112 / 3 = 704 (the remainder is 0, so 3 and 704 are divisors of 2112)
- ...
- 2112 / 44 = 48 (the remainder is 0, so 44 and 48 are divisors of 2112)
- 2112 / 45 = 46.933333333333 (the remainder is 42, so 45 is not a divisor of 2112)