What are the divisors of 2221?
1, 2221
- There is a total of 2 positive divisors.
- The sum of these divisors is 2222.
- The arithmetic mean is 1111.
2 odd divisors
1, 2221
How to compute the divisors of 2221?
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 2221 by each of the numbers from 1 to 2221 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 2221 / 1 = 2221 (the remainder is 0, so 1 is a divisor of 2221)
- 2221 / 2 = 1110.5 (the remainder is 1, so 2 is not a divisor of 2221)
- 2221 / 3 = 740.33333333333 (the remainder is 1, so 3 is not a divisor of 2221)
- ...
- 2221 / 2220 = 1.0004504504505 (the remainder is 1, so 2220 is not a divisor of 2221)
- 2221 / 2221 = 1 (the remainder is 0, so 2221 is a divisor of 2221)
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 2221 (i.e. 47.127486671793). 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 )
- 2221 / 1 = 2221 (the remainder is 0, so 1 and 2221 are divisors of 2221)
- 2221 / 2 = 1110.5 (the remainder is 1, so 2 is not a divisor of 2221)
- 2221 / 3 = 740.33333333333 (the remainder is 1, so 3 is not a divisor of 2221)
- ...
- 2221 / 46 = 48.282608695652 (the remainder is 13, so 46 is not a divisor of 2221)
- 2221 / 47 = 47.255319148936 (the remainder is 12, so 47 is not a divisor of 2221)