What are the divisors of 2013?
1, 3, 11, 33, 61, 183, 671, 2013
- There is a total of 8 positive divisors.
- The sum of these divisors is 2976.
- The arithmetic mean is 372.
8 odd divisors
1, 3, 11, 33, 61, 183, 671, 2013
How to compute the divisors of 2013?
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 2013 by each of the numbers from 1 to 2013 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2013 / 1 = 2013 (the remainder is 0, so 1 is a divisor of 2013)
- 2013 / 2 = 1006.5 (the remainder is 1, so 2 is not a divisor of 2013)
- 2013 / 3 = 671 (the remainder is 0, so 3 is a divisor of 2013)
- ...
- 2013 / 2012 = 1.0004970178926 (the remainder is 1, so 2012 is not a divisor of 2013)
- 2013 / 2013 = 1 (the remainder is 0, so 2013 is a divisor of 2013)
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 2013 (i.e. 44.866468548349). 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 )
- 2013 / 1 = 2013 (the remainder is 0, so 1 and 2013 are divisors of 2013)
- 2013 / 2 = 1006.5 (the remainder is 1, so 2 is not a divisor of 2013)
- 2013 / 3 = 671 (the remainder is 0, so 3 and 671 are divisors of 2013)
- ...
- 2013 / 43 = 46.813953488372 (the remainder is 35, so 43 is not a divisor of 2013)
- 2013 / 44 = 45.75 (the remainder is 33, so 44 is not a divisor of 2013)