What are the divisors of 3654?
1, 2, 3, 6, 7, 9, 14, 18, 21, 29, 42, 58, 63, 87, 126, 174, 203, 261, 406, 522, 609, 1218, 1827, 3654
- There is a total of 24 positive divisors.
- The sum of these divisors is 9360.
- The arithmetic mean is 390.
12 even divisors
2, 6, 14, 18, 42, 58, 126, 174, 406, 522, 1218, 3654
12 odd divisors
1, 3, 7, 9, 21, 29, 63, 87, 203, 261, 609, 1827
How to compute the divisors of 3654?
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 3654 by each of the numbers from 1 to 3654 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 3654 / 1 = 3654 (the remainder is 0, so 1 is a divisor of 3654)
- 3654 / 2 = 1827 (the remainder is 0, so 2 is a divisor of 3654)
- 3654 / 3 = 1218 (the remainder is 0, so 3 is a divisor of 3654)
- ...
- 3654 / 3653 = 1.0002737476047 (the remainder is 1, so 3653 is not a divisor of 3654)
- 3654 / 3654 = 1 (the remainder is 0, so 3654 is a divisor of 3654)
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 3654 (i.e. 60.44832503883). 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 )
- 3654 / 1 = 3654 (the remainder is 0, so 1 and 3654 are divisors of 3654)
- 3654 / 2 = 1827 (the remainder is 0, so 2 and 1827 are divisors of 3654)
- 3654 / 3 = 1218 (the remainder is 0, so 3 and 1218 are divisors of 3654)
- ...
- 3654 / 59 = 61.932203389831 (the remainder is 55, so 59 is not a divisor of 3654)
- 3654 / 60 = 60.9 (the remainder is 54, so 60 is not a divisor of 3654)