How to find the GCF and LCM
- Type two or more whole numbers in Numbers, separated by commas or spaces.
- Read the greatest common factor and the least common multiple, with the prime factors of each number underneath. Everything updates as you type.
- Use the GCF to simplify a fraction or ratio, and the LCM to find a common denominator.
Working it out with prime factors
Break each number into primes, then compare:
| Number | Prime factors |
|---|---|
| 12 | 2² × 3 |
| 18 | 2 × 3² |
| 30 | 2 × 3 × 5 |
For the GCF, take only the primes that appear in every number, at the lowest power: 2 × 3 = 6. For the LCM, take every prime that appears anywhere, at the highest power: 2² × 3² × 5 = 180.
For big numbers, Euclid’s method is faster. Divide the larger number by the smaller and keep the remainder, then repeat with the smaller number and that remainder until the remainder is 0. For 48 and 18: 48 leaves 12, 18 leaves 6, 12 leaves 0, so the GCF is 6. This is the method the calculator uses.
Where GCF and LCM come up
- To simplify a fraction, divide the top and bottom by their GCF. 18/24 has a GCF of 6, so it simplifies to 3/4.
- Adding fractions needs a common denominator. For 1/12 + 1/18, the LCM of 12 and 18 is 36, so it becomes 3/36 + 2/36 = 5/36.
- Things that repeat line up at the LCM. If one bus leaves every 12 minutes and another every 18, they leave together every 36 minutes.
- Splitting into equal groups uses the GCF: 12 apples and 18 oranges make at most 6 identical bags, with 2 apples and 3 oranges in each.