# What is the LCM of my numbers?

Finds the least common multiple (LCM) of two or more numbers, exactly, however large the answer is.

- Page: https://www.acalculator.org/math/lcm-calculator
- JSON spec: https://www.acalculator.org/math/lcm-calculator.json
- Version: 77205f438fd0

## Default answer

Example with the default inputs (Your numbers [12, 18, 24]): The least common multiple of 12, 18 and 24 is 72.

## Inputs

| Key | Label | Description |
| --- | --- | --- |
| input | Your numbers | Two or more numbers, separated by commas, spaces, semicolons, or new lines. |

## Outputs

| Key | Label | Description |
| --- | --- | --- |
| lcm | Least common multiple | The smallest number that every number in the list divides a whole number of times. |
| numbers | Numbers | The numbers as read from the list, written without thousands separators. |
| note | Decimals | Shown when a number has decimals: how the LCM of decimals is found. |

## 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.

## Assumptions

- 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

1. input = 12 or 18 gives lcm = 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.
2. input = 4 or 6 gives lcm = 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.
3. input = 2 or 3 gives lcm = 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.
4. input = 1,000 or 999 gives lcm = 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.
5. input = 0.5 or 0.2 gives lcm = 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.

## FAQ

### 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.

## Sources

- 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
