GCD Calculator
Calculate the Greatest Common Divisor (GCD) of two numbers using the Euclidean algorithm
Enter Numbers
Enter two non-negative integers to find their GCD
How to Use
What is GCD?
The Greatest Common Divisor (GCD), also known as the Greatest Common Factor (GCF), is the largest positive integer that divides both numbers without a remainder.
Examples:
Example 1:
GCD(48, 18) = 6
Because 6 is the largest number that divides both 48 and 18
Because 6 is the largest number that divides both 48 and 18
Example 2:
GCD(100, 50) = 50
Because 50 divides both 100 and 50
Because 50 divides both 100 and 50
Example 3:
GCD(17, 19) = 1
Because 17 and 19 are coprime (share no common factors except 1)
Because 17 and 19 are coprime (share no common factors except 1)
Use Cases:
- Simplifying fractions to their lowest terms
- Finding common factors in number theory
- Solving problems in cryptography and computer science
- Determining tile sizes that fit perfectly in a space
- Scheduling problems with repeating events
Special Cases:
- GCD(n, 0) = n (any number with 0)
- GCD(n, 1) = 1 (any number with 1)
- GCD(n, n) = n (a number with itself)