Arvutaja

GCD and LCM calculator

The greatest common divisor is the largest number dividing both; the least common multiple is the smallest number both divide into. The two are linked: their product equals the product of the original numbers.

Greatest common divisor
12
Least common multiple
72

Rates and thresholds

GCD(24, 36)
12
LCM(24, 36)
72
Relationship
GCD × LCM = a × b

How do I find the greatest common divisor?

The quickest route is Euclid's algorithm: divide the larger by the smaller and replace the larger with the remainder until the remainder is zero — the last non-zero remainder is the GCD. For 36 and 24: 36 ÷ 24 leaves 12, and 24 ÷ 12 leaves 0, so the GCD is 12.

What is the least common multiple for?

Most often for adding fractions: the common denominator is the least common multiple of the denominators. Adding a third and a quarter, the LCM is 12, so 4/12 + 3/12 = 7/12. The same number answers when two events on different cycles next coincide.

Related calculators

All calculators