Skip to content

GCD & LCM Calculator

Calculate Greatest Common Divisor and Least Common Multiple with steps

Simplify Fractions, Sync Schedules, and More

You’ve got 48/36 and you need it in lowest terms. What’s the biggest number that divides both evenly? That’s the GCD, Greatest Common Divisor. For 48 and 36, it’s 12, so the fraction reduces to 4/3.

Now flip it: you’re adding fractions with denominators 8 and 12. You need the smallest number both divide into, the LCM, or Least Common Multiple. That’s 24. Now you can add them.

This calculator finds both the GCD and LCM using the Euclidean algorithm, and it shows you each step so you can follow the logic. It works with two or more numbers at once, not just pairs.

How the Euclidean Algorithm Works (It’s Elegant, Actually)

GCD(48, 36): divide 48 by 36, remainder is 12. Now GCD(36, 12): divide 36 by 12, remainder is 0. Done, GCD is 12. Three lines of work for a problem that would take much longer with prime factorization.

The step-by-step display shows this process for every calculation, which makes it genuinely useful as a learning tool. You’re not just getting an answer, you’re seeing the method.

LCM comes from the GCD via a simple relationship: LCM(a, b) = |a x b| / GCD(a, b). Much faster than listing out multiples until you find a match.

When You’ll Actually Need This

Simplifying fractions. Divide both parts by the GCD and you’re in lowest terms. Basic but comes up constantly.

Adding fractions. The LCM of the denominators gives you the least common denominator. If you’re tutoring someone through pre-algebra, this is half the battle.

Scheduling. Machine A needs maintenance every 15 days, Machine B every 20 days. When do they both need maintenance on the same day? LCM(15, 20) = 60 days. This same logic applies to traffic light synchronization, rotating shift schedules, and gear ratio calculations.

Engineering. Signal synchronization, timing intervals, gear teeth calculations, anywhere you need to find common periods or common factors in real systems.

Enter more than two numbers by separating them with commas or spaces. The calculator chains the results: GCD(a, b, c) = GCD(GCD(a, b), c).

The Prime Number Checker is useful for related number theory exploration, and the Ratio Calculator actually uses GCD under the hood to simplify ratios. All math runs in your browser.

gcd lcm euclidean math calculator

Related Tools

More in Math & Calculators