What Are LCM and GCF?
The Greatest Common Factor (GCF), also known as the Greatest Common Divisor (GCD), is the largest positive integer that divides evenly into two or more numbers. The Least Common Multiple (LCM) is the smallest positive integer that is a multiple of all the numbers in the set.
How to Use the Lcm Gcf Calculator
- Enter two or more integers separated by commas (e.g., 12, 18 or 24, 36, 48).
- Click "Calculate LCM & GCF".
- View the LCM, GCF, prime factorization trees, and Euclidean algorithm steps.
Formula & How the Calculation Works
LCM(a, b) = |a × b| ÷ GCF(a, b)
Euclidean Algorithm: GCF(a, b) = GCF(b, a mod b)
The product of two positive integers always equals the product of their LCM and GCF.
Worked Calculation Example
Scenario: Find LCM and GCF of 12 and 18.
- Prime factors of 12: 2² × 3.
- Prime factors of 18: 2 × 3².
- GCF: Take lowest powers of common primes: 2¹ × 3¹ = 6.
- LCM: Take highest powers of all primes: 2² × 3² = 4 × 9 = 36.
Key Considerations & Common Mistakes to Avoid
- Mixing up LCM and GCF: The GCF is always less than or equal to the smallest number; the LCM is always greater than or equal to the largest number.
- Entering decimal numbers: LCM and GCF are standardly defined only for integers.