What are the divisors of 1152?
1, 2, 3, 4, 6, 8, 9, 12, 16, 18, 24, 32, 36, 48, 64, 72, 96, 128, 144, 192, 288, 384, 576, 1152
- There is a total of 24 positive divisors.
- The sum of these divisors is 3315.
- The arithmetic mean is 138.125.
21 even divisors
2, 4, 6, 8, 12, 16, 18, 24, 32, 36, 48, 64, 72, 96, 128, 144, 192, 288, 384, 576, 1152
3 odd divisors
1, 3, 9
How to compute the divisors of 1152?
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 1152 by each of the numbers from 1 to 1152 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 1152 / 1 = 1152 (the remainder is 0, so 1 is a divisor of 1152)
- 1152 / 2 = 576 (the remainder is 0, so 2 is a divisor of 1152)
- 1152 / 3 = 384 (the remainder is 0, so 3 is a divisor of 1152)
- ...
- 1152 / 1151 = 1.0008688097307 (the remainder is 1, so 1151 is not a divisor of 1152)
- 1152 / 1152 = 1 (the remainder is 0, so 1152 is a divisor of 1152)
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 1152 (i.e. 33.941125496954). 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 )
- 1152 / 1 = 1152 (the remainder is 0, so 1 and 1152 are divisors of 1152)
- 1152 / 2 = 576 (the remainder is 0, so 2 and 576 are divisors of 1152)
- 1152 / 3 = 384 (the remainder is 0, so 3 and 384 are divisors of 1152)
- ...
- 1152 / 32 = 36 (the remainder is 0, so 32 and 36 are divisors of 1152)
- 1152 / 33 = 34.909090909091 (the remainder is 30, so 33 is not a divisor of 1152)