Euclidean algorithm
Japanese school year: Math A
What you learn
You will learn an efficient algorithm to find the greatest common divisor of two integers using division remainders. It is especially useful when dealing with large numbers that are hard to factor. Familiarity with the division algorithm and properties of integer remainders is helpful before learning this.
Key points
This formula represents integer division. When an integer is divided by a positive integer , is the quotient and is the remainder, satisfying .
Use this formula to efficiently find the GCD of large numbers. The GCD of and equals the GCD of the divisor and the remainder .
This equation shows that there exist integers and satisfying this relationship. You can find a specific solution pair by tracing the Euclidean algorithm backward.
Choose a set to practice.