GCD/LCM Calculator
Free online GCD/LCM Calculator.
Calculator
How to Use
- Enter two or more positive integers separated by commas
- The calculator applies the Euclidean algorithm to find the GCD
- It then uses the GCD to compute the LCM via the product formula
- View step-by-step Euclidean divisions and final results
Formula
GCD (Euclidean): gcd(a,b) = gcd(b, a mod b), repeat until remainder = 0\nLCM: lcm(a,b) = |a x b| / gcd(a,b)\nExtended: gcd(a,b,c) = gcd(gcd(a,b), c)\nExample: gcd(48,36) = 12, lcm(48,36) = 144
Example Calculations
Two numbers
Input: 48 and 36
Result: GCD = 12, LCM = 144
Three numbers
Input: 12, 18, 24
Result: GCD = 6, LCM = 72
About This Calculator
Find the greatest common divisor and least common multiple of two or more numbers. Free GCD and LCM calculator with Euclidean algorithm steps shown.
Our gcd/lcm calculator is free, easy to use, and provides instant results. All calculations are performed in your browser for privacy and speed.
Related Calculators
Frequently Asked Questions
What is the GCD of 48 and 36?
Euclidean algorithm: 48=1x36+12, 36=3x12+0. GCD = 12, the last non-zero remainder.
How are GCD and LCM related?
GCD(a,b) x LCM(a,b) = a x b. So LCM(48,36) = 48x36/12 = 144.
Why is GCD useful for simplifying fractions?
Divide numerator and denominator by GCD. 48/36: GCD=12, so 48/12=4, 36/12=3, giving 4/3.
How do you find LCM for adding fractions?
LCM of denominators is the common denominator. For 1/6 + 1/8: LCM(6,8)=24. Convert: 4/24 + 3/24 = 7/24.