What are the divisors of 669?
1, 3, 223, 669
- There is a total of 4 positive divisors.
- The sum of these divisors is 896.
- The arithmetic mean is 224.
4 odd divisors
1, 3, 223, 669
How to compute the divisors of 669?
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 669 by each of the numbers from 1 to 669 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 669 / 1 = 669 (the remainder is 0, so 1 is a divisor of 669)
- 669 / 2 = 334.5 (the remainder is 1, so 2 is not a divisor of 669)
- 669 / 3 = 223 (the remainder is 0, so 3 is a divisor of 669)
- ...
- 669 / 668 = 1.001497005988 (the remainder is 1, so 668 is not a divisor of 669)
- 669 / 669 = 1 (the remainder is 0, so 669 is a divisor of 669)
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 669 (i.e. 25.865034312755). 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 )
- 669 / 1 = 669 (the remainder is 0, so 1 and 669 are divisors of 669)
- 669 / 2 = 334.5 (the remainder is 1, so 2 is not a divisor of 669)
- 669 / 3 = 223 (the remainder is 0, so 3 and 223 are divisors of 669)
- ...
- 669 / 24 = 27.875 (the remainder is 21, so 24 is not a divisor of 669)
- 669 / 25 = 26.76 (the remainder is 19, so 25 is not a divisor of 669)