Free Online Math Tool

LCM Calculator

Calculate the least common multiple (LCM) of two or more positive integers. See the answer, step-by-step calculations, and prime factorization method instantly.

Calculate the Least Common Multiple

Enter between 2 and 20 positive whole numbers. Separate them with commas, spaces, semicolons, or new lines. Each number must be at most 1,000,000,000.

Example: 12, 18, 30 or enter each number on a separate line.
Reset

What Is the Least Common Multiple?

The least common multiple (LCM) of two or more positive integers is the smallest positive integer that is divisible by every number in the set. It is also called the lowest common multiple.

LCM formula

LCM(a, b) = (a × b) ÷ GCD(a, b)

Here, GCD means greatest common divisor. Dividing one number by the GCD before multiplying helps avoid unnecessary intermediate overflow.

Example: LCM of 12 and 18

  1. The GCD of 12 and 18 is 6.
  2. Divide 12 by 6 to get 2.
  3. Multiply 2 by 18 to get 36.

LCM(12, 18) = (12 ÷ 6) × 18 = 36

Example: LCM of 12, 18, and 30

First, LCM(12, 18) = 36. Next, LCM(36, 30) = 180. Therefore, the LCM of 12, 18, and 30 is 180.

Example LCM Calculations

Numbers LCM
4 and 612
8 and 1224
12 and 1836
12, 18, and 30180
7, 14, and 2142
5 and 1010

Frequently Asked Questions

What does LCM mean?

LCM stands for least common multiple. It is the smallest positive integer that is divisible by all the given positive integers.

How do you calculate the LCM of two numbers?

Calculate their greatest common divisor, divide the first number by that GCD, and multiply the result by the second number.

Can I find the LCM of more than two numbers?

Yes. This calculator accepts up to 20 positive integers and combines them in sequence to find their LCM.

What is the difference between LCM and GCD?

The LCM is the smallest positive common multiple of the numbers. The GCD is the largest positive integer that divides all of them without a remainder.

Can the LCM be smaller than the input numbers?

For positive integers, the LCM is at least as large as every input number and is divisible by each of them.

Related Math Calculators

Explore more free mathematics tools on Summe.org.