What are the divisors of 9594?

1, 2, 3, 6, 9, 13, 18, 26, 39, 41, 78, 82, 117, 123, 234, 246, 369, 533, 738, 1066, 1599, 3198, 4797, 9594

12 even divisors

2, 6, 18, 26, 78, 82, 234, 246, 738, 1066, 3198, 9594

12 odd divisors

1, 3, 9, 13, 39, 41, 117, 123, 369, 533, 1599, 4797

How to compute the divisors of 9594?

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 9594 by each of the numbers from 1 to 9594 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)

  • 9594 / 1 = 9594 (the remainder is 0, so 1 is a divisor of 9594)
  • 9594 / 2 = 4797 (the remainder is 0, so 2 is a divisor of 9594)
  • 9594 / 3 = 3198 (the remainder is 0, so 3 is a divisor of 9594)
  • ...
  • 9594 / 9593 = 1.000104242677 (the remainder is 1, so 9593 is not a divisor of 9594)
  • 9594 / 9594 = 1 (the remainder is 0, so 9594 is a divisor of 9594)

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 9594 (i.e. 97.948966303887). 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 )

  • 9594 / 1 = 9594 (the remainder is 0, so 1 and 9594 are divisors of 9594)
  • 9594 / 2 = 4797 (the remainder is 0, so 2 and 4797 are divisors of 9594)
  • 9594 / 3 = 3198 (the remainder is 0, so 3 and 3198 are divisors of 9594)
  • ...
  • 9594 / 96 = 99.9375 (the remainder is 90, so 96 is not a divisor of 9594)
  • 9594 / 97 = 98.907216494845 (the remainder is 88, so 97 is not a divisor of 9594)