What are the divisors of 282?
1, 2, 3, 6, 47, 94, 141, 282
- There is a total of 8 positive divisors.
- The sum of these divisors is 576.
- The arithmetic mean is 72.
4 even divisors
2, 6, 94, 282
4 odd divisors
1, 3, 47, 141
How to compute the divisors of 282?
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 282 by each of the numbers from 1 to 282 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 282 / 1 = 282 (the remainder is 0, so 1 is a divisor of 282)
- 282 / 2 = 141 (the remainder is 0, so 2 is a divisor of 282)
- 282 / 3 = 94 (the remainder is 0, so 3 is a divisor of 282)
- ...
- 282 / 281 = 1.0035587188612 (the remainder is 1, so 281 is not a divisor of 282)
- 282 / 282 = 1 (the remainder is 0, so 282 is a divisor of 282)
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 282 (i.e. 16.792855623747). 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 )
- 282 / 1 = 282 (the remainder is 0, so 1 and 282 are divisors of 282)
- 282 / 2 = 141 (the remainder is 0, so 2 and 141 are divisors of 282)
- 282 / 3 = 94 (the remainder is 0, so 3 and 94 are divisors of 282)
- ...
- 282 / 15 = 18.8 (the remainder is 12, so 15 is not a divisor of 282)
- 282 / 16 = 17.625 (the remainder is 10, so 16 is not a divisor of 282)