What are the divisors of 2870?
1, 2, 5, 7, 10, 14, 35, 41, 70, 82, 205, 287, 410, 574, 1435, 2870
- There is a total of 16 positive divisors.
- The sum of these divisors is 6048.
- The arithmetic mean is 378.
8 even divisors
2, 10, 14, 70, 82, 410, 574, 2870
8 odd divisors
1, 5, 7, 35, 41, 205, 287, 1435
How to compute the divisors of 2870?
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 2870 by each of the numbers from 1 to 2870 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2870 / 1 = 2870 (the remainder is 0, so 1 is a divisor of 2870)
- 2870 / 2 = 1435 (the remainder is 0, so 2 is a divisor of 2870)
- 2870 / 3 = 956.66666666667 (the remainder is 2, so 3 is not a divisor of 2870)
- ...
- 2870 / 2869 = 1.000348553503 (the remainder is 1, so 2869 is not a divisor of 2870)
- 2870 / 2870 = 1 (the remainder is 0, so 2870 is a divisor of 2870)
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 2870 (i.e. 53.572380943915). 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 )
- 2870 / 1 = 2870 (the remainder is 0, so 1 and 2870 are divisors of 2870)
- 2870 / 2 = 1435 (the remainder is 0, so 2 and 1435 are divisors of 2870)
- 2870 / 3 = 956.66666666667 (the remainder is 2, so 3 is not a divisor of 2870)
- ...
- 2870 / 52 = 55.192307692308 (the remainder is 10, so 52 is not a divisor of 2870)
- 2870 / 53 = 54.150943396226 (the remainder is 8, so 53 is not a divisor of 2870)