Number Theory: The Euclidean Algorithm Emercado
Number Theory: The Euclidean Algorithm Emercado
EMERCADO
02/20/22
In mathematics, the Euclidean algorithm, or Euclid's algorithm, is an efficient method
for computing the greatest common divisor (GCD) of two integers (numbers), the largest
number that divides them both without a remainder.
24 = 2(9) + 6
(24, 9) = 3
(9, 6)= 3
02/20/22
Theorem 1: Let a, b Z, a > 0 by repeatedly applying the division algorithm, we
obtain a sequence of equations of the form:
b = q a+ r , 0≤r <r
1 1 1
r1= q r2 + r , 0 ≤ r < r2
3 3 3
r =q r + r , 0≤r <r
2 4 3 4 4 3
.
.
r =q r + r
k-3 k-1 k-2 k-1 02/20/22
Examples: Use Euclidean Algorithm, find
1. (72 162)
162 = 2(72) + 18
72 = 4(18) + 0
Therefore, the gcd (72, 162 ) = 18
Now, express 18 as a linear combination of 71 and 162
18 = 162 – 2 (72)
162(1) – 2(72) therefore, x =-2 and y = 1
02/20/22
2. (504, 1100) = 504x + 1100y
1100= 2(504) + 92
504 = 5 (92) + 44
92 = 2(44) +4
44 = 11(4) +0
gcd (504, 1100) = 4
4 = 92 – 2(44)
= 92 – 2 [ 504 – 5(92)]
= 92 – 2 (504) + 10(92)
= 11(92) – 2(504)
= 11 [ 1100 – 2(504)] - 2(504)
= 11 (1100) – 22(504) - 2(504)
= 11 (1100) – 24(504) therefore, x = -24 and y = 11 02/20/22
3. ( 4321, 2205) = 2205x+ 4321y
4312= 1(2205) + 2107
2205 = 1(2107) + 98
2107 = 21(98) +49
98 = 2(49) +0
gcd (2205, 4321) = 49
02/20/22
49 = 2107 – 21(98)
= 2107 – 21[ 2205 – 1(2107)]
= 2107 – 22 (2205) + 21(2107)
= 22(2107) – 21(2205)
= 22 [ 4312– 1(2205)] - 21(2205)
= 22(4312) – 22(2205) – 21(2205)
=22 (4312) – 43(2205) therefore, x = -43 and y = 22
02/20/22
4. ( 1680, 810) = 1680x+ 810y
1680= 2(810) + 60
810 = 13(60) + 30
60 = 2(30) + 0
gcd (1680, 810) = 30
30 = 810 – 13(60)
= 810 – 13 [ 1680 – 2(810)]
= 810 – 13 (1680) + 26(810)
= 27(810) – 13 (1680) therefore, x = 27 and y = -13
02/20/22
Theorem 2 : If c >0 then (ca, cb) = c(a,b)
02/20/22
Definition: Let a, b be nonzero Z. A positive integers m= [a,b] is called
the least common multiple.
02/20/22
02/20/22
02/20/22
02/20/22
02/20/22