GCD and LCM
- Greatest common divisor (GCD): the largest number that divides all the given numbers without a remainder.
- Least common multiple (LCM): the smallest number that is a multiple of all the given numbers.
How they are calculated
The GCD is found with Euclid's algorithm: repeatedly replace the larger number by the remainder of the division until the remainder is zero. The LCM of two numbers is a × b ÷ GCD(a, b).
Uses
The GCD simplifies fractions (12/18 = 2/3 because GCD = 6). The LCM helps add fractions with different denominators and solve scheduling problems, such as when two events repeat together.
Frequently asked questions
Can I use more than two numbers?
Yes, enter as many positive whole numbers as you like.
Does it accept decimals or negatives?
No. Only positive whole numbers are supported.
What is the GCD of numbers with no common factor?
It is 1, and the numbers are called coprime.