What is the LCM of my numbers?
Free online lcm calculator. Fast, accurate, and easy to use math tool.
- Least common multiple
- 72
The least common multiple of 12, 18 and 24 is 72.
- Numbers
- 12, 18 and 24
Least common multiple: 72. The least common multiple of 12, 18 and 24 is 72.
How to calculate
Finds the least common multiple (LCM) of two or more numbers, exactly, however large the answer is.
Example with the default inputs (Your numbers [12, 18, 24]): The least common multiple of 12, 18 and 24 is 72.
Method: LCM(a, b) = |a × b| ÷ GCF(a, b), and LCM(a, b, c) = LCM(LCM(a, b), c); decimals are scaled by a power of ten.
- Negative numbers count by their absolute value: LCM(−4, 6) = 12.
- The LCM of a list that contains 0 is 0, because 0 is the only multiple of 0.
- Decimals are exact as typed: every number is multiplied by the same power of ten to make it whole, and the LCM is divided by it again.
- The answer keeps every digit, however large. Very large numbers typed in the box are read as 64-bit floats, so enter whole numbers below 9,007,199,254,740,992 (2^53) to keep them exact.
Worked examples
Each example is checked against the calculator on every build.
- Your numbers 12, 18, 24 gives Least common multiple 72.Source: OpenStax, Prealgebra 2e, §2.5 Prime Factorization and the Least Common Multiple. https://openstax.org/books/prealgebra-2e/pages/2-5-prime-factorization-and-the-least-common-multiple
- Your numbers 4, 6 gives Least common multiple 12.Source: OpenStax, Prealgebra 2e, §2.5 Prime Factorization and the Least Common Multiple. https://openstax.org/books/prealgebra-2e/pages/2-5-prime-factorization-and-the-least-common-multiple
- Your numbers 2, 3, 4, 5, 6 gives Least common multiple 60.Source: OpenStax, Prealgebra 2e, §2.5 Prime Factorization and the Least Common Multiple. https://openstax.org/books/prealgebra-2e/pages/2-5-prime-factorization-and-the-least-common-multiple
- Your numbers 1,000, 999 gives Least common multiple 999,000.Source: OpenStax, Prealgebra 2e, §2.5 Prime Factorization and the Least Common Multiple. https://openstax.org/books/prealgebra-2e/pages/2-5-prime-factorization-and-the-least-common-multiple
- Your numbers 0.5, 0.2 gives Least common multiple 1.Source: OpenStax, Prealgebra 2e, §2.5 Prime Factorization and the Least Common Multiple. https://openstax.org/books/prealgebra-2e/pages/2-5-prime-factorization-and-the-least-common-multiple
How it works
The least common multiple (LCM) of a list of numbers is the smallest positive number that each of them divides a whole number of times.
The calculator uses the greatest common factor (GCF, found with Euclid's algorithm):
- LCM(a, b) = |a × b| ÷ GCF(a, b).
- For more than two numbers, LCM(a, b, c) = LCM(LCM(a, b), c).
All the arithmetic is exact, with integers of any size, so an LCM larger than 2⁵³ keeps every digit.
Decimals. If any number has decimals, every number is multiplied by the same power of ten, 10ᵏ, where k is the largest number of decimal places. The LCM of those whole numbers, divided by 10ᵏ, is the answer.
Assumptions
- Negative numbers count by their absolute value: LCM(−4, 6) = LCM(4, 6) = 12. The LCM is never negative.
- If the list contains 0, the LCM is 0, because the only multiple of 0 is 0.
- Decimals are taken exactly as typed (0.1 is one tenth). A whole-number answer shows every digit; a decimal answer is shown to 6 decimal places.
- The answer sentence lists the numbers without thousands separators, the last two joined by "and": "The least common multiple of 123456789012 and 987654321098 is …". A comma inside a number would read as another list item.
- When a number has decimals, a note says so: every number is multiplied by 10^k (k is the largest number of decimal places) and the LCM of those whole numbers is divided by 10^k.
- Numbers are read as 64-bit floats, so whole numbers above 9,007,199,254,740,992 (2⁵³) may not be kept exactly as typed.
- Enter at least 2 and at most 100 numbers.
Worked examples by hand
12, 18 and 24. 12 = 2² × 3, 18 = 2 × 3², 24 = 2³ × 3. The highest power of each prime is 2³ and 3², so the LCM is 8 × 9 = 72.
4 and 6. GCF(4, 6) = 2, so LCM = 4 × 6 ÷ 2 = 24 ÷ 2 = 12.
2, 3, 4, 5 and 6. The highest powers are 2², 3 and 5, so the LCM is 4 × 3 × 5 = 60.
1,000 and 999. They share no factor (GCF 1), so LCM = 1,000 × 999 = 999,000.
0.5 and 0.2. Multiply by 10: 5 and 2. LCM(5, 2) = 10. Divide by 10: 1.
Other questions people ask
What is the Least Common Multiple (LCM)?
The Least Common Multiple (LCM) of two or more numbers is the smallest positive integer that is evenly divisible by all the given numbers. For example, the LCM of 4 and 6 is 12, because 12 is the smallest number that both 4 and 6 divide into evenly.
How do you find the LCM of two numbers?
The most efficient method uses the Greatest Common Divisor (GCD): LCM(a, b) = (a × b) / GCD(a, b). For example, to find LCM(12, 18): First find GCD(12, 18) = 6, then LCM(12, 18) = (12 × 18) / 6 = 216 / 6 = 36.
How do you find the LCM of more than two numbers?
For multiple numbers, use the associative property: LCM(a, b, c) = LCM(LCM(a, b), c). Find the LCM of the first two numbers, then find the LCM of that result with the third number, and so on.
What's the difference between LCM and GCD?
LCM (Least Common Multiple) is the smallest number that is a multiple of all given numbers, while GCD (Greatest Common Divisor) is the largest number that divides all given numbers evenly. They are related by the formula: LCM(a, b) × GCD(a, b) = a × b, for positive a and b.
Can you find the LCM of negative numbers?
LCM is typically defined for positive integers. For negative numbers, you find the LCM of their absolute values, and this calculator does that: LCM(−4, 6) = 12.
What are some real-world applications of LCM?
LCM is used in scheduling (finding when events repeat), music theory (finding common time signatures), engineering (synchronizing gears or cycles), and computer science (finding optimal buffer sizes or timing intervals).
How does prime factorization help find LCM?
Prime factorization can be used to find LCM by taking each prime factor to its highest power across all numbers. For example, for 12 (2²×3) and 18 (2×3²), the LCM is 2²×3² = 36, using the highest power of each prime factor.
What's the relationship between LCM and fractions?
LCM is essential for adding and subtracting fractions with different denominators. The LCM of the denominators becomes the common denominator. For example, to add 1/4 + 1/6, you need LCM(4, 6) = 12 as the common denominator.
Can the LCM be smaller than the largest number?
No, for positive whole numbers the LCM is always greater than or equal to the largest number in the set. The LCM equals the largest number only when all other numbers are factors of the largest number.
How do you verify if a number is the correct LCM?
To verify, check that the number is divisible by all the original numbers and that no smaller positive number has this property. You can also use the relationship: LCM(a, b) × GCD(a, b) = a × b (for positive a and b) to verify your result.
Can I find the LCM of decimals?
Yes. Multiply every number by the same power of ten so that all of them are whole numbers, find the LCM of those, then divide by the same power of ten. For example, for 0.5 and 0.2: multiply by 10 to get 5 and 2, whose LCM is 10, so the LCM of 0.5 and 0.2 is 1.