What are the divisors of 5934?

1, 2, 3, 6, 23, 43, 46, 69, 86, 129, 138, 258, 989, 1978, 2967, 5934

8 even divisors

2, 6, 46, 86, 138, 258, 1978, 5934

8 odd divisors

1, 3, 23, 43, 69, 129, 989, 2967

How to compute the divisors of 5934?

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.

N mod M = 0

Brute force algorithm

We could start by using a brute-force method which would involve dividing 5934 by each of the numbers from 1 to 5934 to determine which ones have a remainder equal to 0.

Remainder = N ( M × N M )

(where N M is the integer part of the quotient)

  • 5934 / 1 = 5934 (the remainder is 0, so 1 is a divisor of 5934)
  • 5934 / 2 = 2967 (the remainder is 0, so 2 is a divisor of 5934)
  • 5934 / 3 = 1978 (the remainder is 0, so 3 is a divisor of 5934)
  • ...
  • 5934 / 5933 = 1.0001685487949 (the remainder is 1, so 5933 is not a divisor of 5934)
  • 5934 / 5934 = 1 (the remainder is 0, so 5934 is a divisor of 5934)

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 5934 (i.e. 77.032460690283). Indeed, if a number N has a divisor D greater than its square root, then there is necessarily a smaller divisor d such that:

D × d = N

(thus, if N D = d , then N d = D )

  • 5934 / 1 = 5934 (the remainder is 0, so 1 and 5934 are divisors of 5934)
  • 5934 / 2 = 2967 (the remainder is 0, so 2 and 2967 are divisors of 5934)
  • 5934 / 3 = 1978 (the remainder is 0, so 3 and 1978 are divisors of 5934)
  • ...
  • 5934 / 76 = 78.078947368421 (the remainder is 6, so 76 is not a divisor of 5934)
  • 5934 / 77 = 77.064935064935 (the remainder is 5, so 77 is not a divisor of 5934)