How to Use the LCM Calculator

1
Choose how many numbers

Select two to five whole numbers. Additional input fields appear only when needed.

2
Enter the whole numbers

Type non-negative integers. The calculator treats negative entries by using their absolute value and defines any set containing zero as having LCM zero.

3
Read the LCM and factors

Review the least common multiple, the highest prime powers used, the GCD shortcut and a multiple check.

4
Copy or share the result

Copy the formatted answer for homework or share the URL so the same numbers reopen with one click.

Formula & Calculation Logic

LCM(a, b) = |a × b| ÷ GCD(a, b) LCM(a, b, c) = LCM(LCM(a, b), c) Prime-factor rule: LCM = product of the highest power of every prime appearing in any input

The least common multiple is the smallest positive whole number divisible by every input. For two numbers, the fastest method is to divide their product by the greatest common divisor. For three or more numbers, apply that rule pairwise or use prime factorisation: take each prime that appears in any number, raised to the highest exponent found anywhere, then multiply.

Worked Example

Scheduling With a Three-Number LCM

Buses on three routes leave every 12, 18 and 30 minutes. The LCM of 12, 18 and 30 is 180, so all three routes leave together every 180 minutes, or every three hours. Prime factors are 12 = 2² × 3, 18 = 2 × 3² and 30 = 2 × 3 × 5; taking the highest powers gives 2² × 3² × 5 = 180.

Common LCM Reference

Useful least common multiples for fractions, timetables and repeating events.

Frequently used least common multiples
NumbersGCDLCMTypical use
4 and 6212Fraction denominators
8 and 12424Common schedules
12 and 18636Repeating work cycles
15 and 20560Clock and timing problems
24 and 361272Large interval planning

Visual Explanation Diagram

Prime factor columns showing how the highest powers combine into an LCM

An LCM takes the highest power of each prime factor present in any input.

Frequently Asked Questions

The least common multiple, or LCM, is the smallest positive number that is a multiple of every number in a set. For 4 and 6, the LCM is 12.

For two numbers, multiply them and divide by their greatest common divisor: LCM(a, b) = a × b ÷ GCD(a, b). For 12 and 18, 216 ÷ 6 = 36.

A GCD is the largest number that divides every input, while an LCM is the smallest number that every input divides into. For 12 and 18, the GCD is 6 and the LCM is 36.

Write the fractions in lowest terms, then divide the LCM of the numerators by the GCD of the denominators. This calculator handles whole numbers; use those whole-number LCM and GCD results as the inputs to that method.

LCM is used to add fractions with different denominators, align repeating schedules such as bus or medication intervals, and find when cycles coincide.

Verified Mathematical Logic & Formulas
Last updated: 2026-11-21 • Client-side computation (no data transmitted)