Exercise 747Number theory › Divisibility and gcdL1Added 2 Nov 2026
Why the Euclidean algorithm works
#Euclidean algorithm#proof#division
Statement
Let with . Prove that .
Hint
Show that the set of common divisors of equals the set of common divisors of .
Show solutionHide solution
Solution
Inclusion 1. If and , then . So is a common divisor of and .
Inclusion 2. If and , then . So is a common divisor of and .
Conclusion. The two pairs have the same common divisors, hence the same greatest one. The Euclidean algorithm terminates because the remainders strictly decrease: , and each new remainder is strictly smaller than the previous one. It stops when the remainder is , and the last nonzero remainder is the divisibility.