What are the divisors of 2024?
1, 2, 4, 8, 11, 22, 23, 44, 46, 88, 92, 184, 253, 506, 1012, 2024
- There is a total of 16 positive divisors.
- The sum of these divisors is 4320.
- The arithmetic mean is 270.
12 even divisors
2, 4, 8, 22, 44, 46, 88, 92, 184, 506, 1012, 2024
4 odd divisors
1, 11, 23, 253
How to compute the divisors of 2024?
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 2024 by each of the numbers from 1 to 2024 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2024 / 1 = 2024 (the remainder is 0, so 1 is a divisor of 2024)
- 2024 / 2 = 1012 (the remainder is 0, so 2 is a divisor of 2024)
- 2024 / 3 = 674.66666666667 (the remainder is 2, so 3 is not a divisor of 2024)
- ...
- 2024 / 2023 = 1.0004943153732 (the remainder is 1, so 2023 is not a divisor of 2024)
- 2024 / 2024 = 1 (the remainder is 0, so 2024 is a divisor of 2024)
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 2024 (i.e. 44.988887516808). 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 )
- 2024 / 1 = 2024 (the remainder is 0, so 1 and 2024 are divisors of 2024)
- 2024 / 2 = 1012 (the remainder is 0, so 2 and 1012 are divisors of 2024)
- 2024 / 3 = 674.66666666667 (the remainder is 2, so 3 is not a divisor of 2024)
- ...
- 2024 / 43 = 47.06976744186 (the remainder is 3, so 43 is not a divisor of 2024)
- 2024 / 44 = 46 (the remainder is 0, so 44 and 46 are divisors of 2024)