What are the divisors of 4068?
1, 2, 3, 4, 6, 9, 12, 18, 36, 113, 226, 339, 452, 678, 1017, 1356, 2034, 4068
- There is a total of 18 positive divisors.
- The sum of these divisors is 10374.
- The arithmetic mean is 576.33333333333.
12 even divisors
2, 4, 6, 12, 18, 36, 226, 452, 678, 1356, 2034, 4068
6 odd divisors
1, 3, 9, 113, 339, 1017
How to compute the divisors of 4068?
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 4068 by each of the numbers from 1 to 4068 to determine which ones have a remainder equal to 0.
(where is the integer part of the quotient)
- 4068 / 1 = 4068 (the remainder is 0, so 1 is a divisor of 4068)
- 4068 / 2 = 2034 (the remainder is 0, so 2 is a divisor of 4068)
- 4068 / 3 = 1356 (the remainder is 0, so 3 is a divisor of 4068)
- ...
- 4068 / 4067 = 1.0002458814851 (the remainder is 1, so 4067 is not a divisor of 4068)
- 4068 / 4068 = 1 (the remainder is 0, so 4068 is a divisor of 4068)
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 4068 (i.e. 63.780874876408). 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 )
- 4068 / 1 = 4068 (the remainder is 0, so 1 and 4068 are divisors of 4068)
- 4068 / 2 = 2034 (the remainder is 0, so 2 and 2034 are divisors of 4068)
- 4068 / 3 = 1356 (the remainder is 0, so 3 and 1356 are divisors of 4068)
- ...
- 4068 / 62 = 65.612903225806 (the remainder is 38, so 62 is not a divisor of 4068)
- 4068 / 63 = 64.571428571429 (the remainder is 36, so 63 is not a divisor of 4068)