What are the divisors of 4785?

1, 3, 5, 11, 15, 29, 33, 55, 87, 145, 165, 319, 435, 957, 1595, 4785

16 odd divisors

1, 3, 5, 11, 15, 29, 33, 55, 87, 145, 165, 319, 435, 957, 1595, 4785

How to compute the divisors of 4785?

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

  • 4785 / 1 = 4785 (the remainder is 0, so 1 is a divisor of 4785)
  • 4785 / 2 = 2392.5 (the remainder is 1, so 2 is not a divisor of 4785)
  • 4785 / 3 = 1595 (the remainder is 0, so 3 is a divisor of 4785)
  • ...
  • 4785 / 4784 = 1.0002090301003 (the remainder is 1, so 4784 is not a divisor of 4785)
  • 4785 / 4785 = 1 (the remainder is 0, so 4785 is a divisor of 4785)

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 4785 (i.e. 69.173694422085). 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 )

  • 4785 / 1 = 4785 (the remainder is 0, so 1 and 4785 are divisors of 4785)
  • 4785 / 2 = 2392.5 (the remainder is 1, so 2 is not a divisor of 4785)
  • 4785 / 3 = 1595 (the remainder is 0, so 3 and 1595 are divisors of 4785)
  • ...
  • 4785 / 68 = 70.367647058824 (the remainder is 25, so 68 is not a divisor of 4785)
  • 4785 / 69 = 69.347826086957 (the remainder is 24, so 69 is not a divisor of 4785)