LCM Calculator (Least Common Multiple) with Steps
LCM calculator. Enter two or more whole numbers separated by commas or spaces. The calculator finds the least common multiple and shows the work using prime factorization (highest power of each prime) and the GCF method, plus a short list-of-multiples check for small numbers. It also shows the GCF, which helps when adding fractions with unlike denominators.
How to use
- Enter two or more positive whole numbers, separated by commas or spaces. Up to 20 numbers, each up to 1,000,000,000,000.
- Read the least common multiple and the greatest common factor.
- Follow each prime factorization and the highest power of every prime.
- Check the pairwise steps, LCM(a, b) = |a × b| / GCF(a, b), and the list of multiples when the numbers are small.
Formula
Prime factorization writes each number as primes, then multiplies the highest power of every prime that appears. For two numbers, LCM(a, b) = |a × b| / GCF(a, b). For a longer list, that identity is applied one pair at a time. The GCF is the largest positive integer that divides every number.
Example. LCM(4, 6) = 12. The factorizations are 4 = 2^2 and 6 = 2 × 3, so the highest powers are 2^2 × 3 = 12. GCF(4, 6) = 2, and |4 × 6| / 2 = 12.
Example. LCM(8, 9, 21) = 504. LCM(12, 15, 20) = 60 with GCF 1. LCM(18, 24) = 72 with GCF 6.
Fractions
The LCM of the denominators is the least common denominator. That is the smallest shared denominator when you add or subtract fractions.
Frequently asked questions
What is the least common multiple?
The least common multiple (LCM) is the smallest positive number that every number in your list divides into evenly. For 4 and 6 it is 12.
How do you find the LCM using prime factorization?
Write each number as a product of primes, take the highest power of every prime that appears, and multiply them together.
What is the difference between LCM and GCF?
The GCF is the largest number that divides all of your numbers, while the LCM is the smallest number they all divide into. For two numbers, LCM times GCF equals their product.
Can I find the LCM of more than two numbers?
Yes. Enter as many numbers as you like and the calculator combines them one pair at a time to get the LCM of the whole list.
How is the LCM used with fractions?
The LCM of the denominators is the least common denominator, which lets you add or subtract fractions with unlike denominators.
Related tools
- SchoolGCF CalculatorFind the greatest common factor of two or more numbers, with prime factors and Euclid's steps.
- SchoolFactoring CalculatorFactor whole numbers into primes and factor quadratic trinomials with steps.
- SchoolLong Division CalculatorDivide with remainders or decimals and see every long division step laid out.
- SchoolPythagorean Theorem CalculatorFind a missing side of a right triangle, plus area, perimeter, and angles.
- SchoolHigh School GPA CalculatorWeighted and unweighted 4.0 GPA from your courses, credits, and level.
- SchoolPercentage CalculatorFind X% of Y, what percent one number is of another, percent change, and an optional percent table.