Toolstry Logo Toolstry.com

GCD & LCM Calculator

Calculate Greatest Common Divisor & Least Common Multiple

Greatest Common Divisor (GCD):

-

Least Common Multiple (LCM):

-

Calculation Steps:

Relationship:

GCD × LCM = Number1 × Number2

GCD & LCM Concepts

Greatest Common Divisor (GCD):

Definition:
The largest number that divides two or more numbers without remainder

Calculation Methods:

Euclidean Algorithm:
GCD(a,b) = GCD(b, a mod b)
Prime Factorization:
Multiply common prime factors

Example:

GCD(24, 36) = 12
Factors of 24: 1, 2, 3, 4, 6, 8, 12, 24
Factors of 36: 1, 2, 3, 4, 6, 9, 12, 18, 36
Common factors: 1, 2, 3, 4, 6, 12

Least Common Multiple (LCM):

Definition:
The smallest number that is a multiple of two or more numbers

Calculation Methods:

Using GCD:
LCM(a,b) = (a × b) ÷ GCD(a,b)
Prime Factorization:
Multiply highest powers of all primes

Example:

LCM(24, 36) = 72
Multiples of 24: 24, 48, 72, 96...
Multiples of 36: 36, 72, 108...
Common multiples: 72, 144...

Properties:

GCD(a,b) × LCM(a,b) = a × b
This relationship holds for any two numbers