What are the divisors of 3834?
1, 2, 3, 6, 9, 18, 27, 54, 71, 142, 213, 426, 639, 1278, 1917, 3834
- There is a total of 16 positive divisors.
- The sum of these divisors is 8640.
- The arithmetic mean is 540.
8 even divisors
2, 6, 18, 54, 142, 426, 1278, 3834
8 odd divisors
1, 3, 9, 27, 71, 213, 639, 1917
How to compute the divisors of 3834?
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 3834 by each of the numbers from 1 to 3834 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 3834 / 1 = 3834 (the remainder is 0, so 1 is a divisor of 3834)
- 3834 / 2 = 1917 (the remainder is 0, so 2 is a divisor of 3834)
- 3834 / 3 = 1278 (the remainder is 0, so 3 is a divisor of 3834)
- ...
- 3834 / 3833 = 1.0002608922515 (the remainder is 1, so 3833 is not a divisor of 3834)
- 3834 / 3834 = 1 (the remainder is 0, so 3834 is a divisor of 3834)
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 3834 (i.e. 61.919302321651). 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 )
- 3834 / 1 = 3834 (the remainder is 0, so 1 and 3834 are divisors of 3834)
- 3834 / 2 = 1917 (the remainder is 0, so 2 and 1917 are divisors of 3834)
- 3834 / 3 = 1278 (the remainder is 0, so 3 and 1278 are divisors of 3834)
- ...
- 3834 / 60 = 63.9 (the remainder is 54, so 60 is not a divisor of 3834)
- 3834 / 61 = 62.852459016393 (the remainder is 52, so 61 is not a divisor of 3834)