

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The extended euclidean algorithm, which is used to find the greatest common divisor (gcd) of two integers and determines the bezout coefficients. It also covers the concept of modular arithmetic, including the definition of congruence and theorems related to it. Examples and proofs to illustrate the concepts.
Typology: Study notes
1 / 2
This page cannot be seen from the preview
Don't miss anything!


Extended Euclidean Algorithm After finding the GCD with the Euclidean Algorithm, start by solving for the remainder of the step next to the last step. From the previous example, it would be the 3rd^ step: 4=3(1)+ Solve for 1. 1=4-3(1) Next, you want to go to the step before the one that was worked on and solve for that remainder. For the example, solve for 3 from the second step. 2 nd^ step: 7=4(1)+ 3=7-4(1) Substitute the result into the 3 in the previous equation, 1=4-3(1) 1=4-(7-4) 1=4-3(1)
your GCD equaling to your arguments Modular Definition 1: If a and b are integers with a≠0, we say that a divides b if there is an intger c such that b =ac. When a divides b we say that a is a factor of b and that b is a multiple of a. The notation a|b denotes that a divides b. We write a ∤b when a does not divide b.b when a does not divide b. Ex1: a|b a|bc a|b: b=a(t) b is equal to a times some num t b(c)=a(t)(c) Therefore, a|bc Ex2: Premise: a|b, b|a, a and b are some integers Therefore, a=b or a=-b For a|b, a=b(t) For b|a, b=a(s) a=a(s)(t), then divide both sides by a (a≠0) 1=st, with s=t=1, or s=t=- Then, go to the previous formulas. a mod m a=q1m + r Euclidean Algorithm GCD(someNum1, someNum2) Whichever number is greater, put it on the left hand side of the equation. For the other number, have it multiply as many times as it can into the greater number and add the remainder. Ex: GCD(7, 25) 1 st^ step: 25=7(3) + 4 Afterwards, you want to shift everything to the left. Take the 7 and put it on the left hand side and multiply 4 into 7 as many times as it can without going over and add the remainder. 2 nd^ step: 7=4(1) + 3 Just rinse and repeat from here until you get a remainder of zero. Once you get to that point, then the number added to zero is the GCD. 3 rd^ step: 4=3(1) + 1 4 th^ step: 3=1(3) + 0 GCD= Modular Theorems
k = 0 n
k
n + 1
k = 1 n
k = 1 n
2
k = 1 n
2
2
Prove by induction that 5|3^2n + 4^n+1 for n≥ N=0, 3^20 + 4^0+1 = 5 5| Induction hypothesis Assume that for n=k, kϵZ+ is followsZ+ is follows 5|[3^2k + 4^(k+1)] Induction step Based on the IH we have to show that 5|[3^2(k+1) + 4^(k+2)] 5|[3^(k+2)+4^(k+2)=3^2k * 3^2 + 4^(k+1) * 4] 5|[3^(k+2) + 4^(k+2) = 93^(2k) + 4^(k+1)4] (5+4)3^(2k) + 4^(k+1) 5(3^2k) + 3^(2k)4 + 4^(k+1) 5[3^(2k) + 4(3^(2k) + 4^(k+1))] 53^(2k) + 45someConstant 5(3^(2k) + 4someConstant) POOF
Modular proof examples Ex a(mod m) = b(mod m) a=q1m+r b=q2m+r a-b=(q1-q2)m a=b+(q1-q2)m q1-q2 = k a=b+km a=b(mod m) Ex a≡b(mod m) a = b + km c≡d(mod m) c = d + jm Theorem: a-c≡b-d(mod m) a-c ≡ b-d + (km-jm) a-c ≡ b-d+(k-j)m a-c ≡ b-d + qm a-c ≡ b-d(mod m) Set notation examples 1 ____ _ _ A∩B = A U B = {x | x ∉ A∩B} A∩B} Definition of set notation = {x | ⌐(xϵZ+ is follows(A∩B))} Definition of the negation sign = {x | ⌐(x ϵZ+ is follows A ∧ x xϵZ+ is follows B)} Definition of intersection/Distributive law = {x | ⌐(x ϵZ+ is follows A) v ⌐(x ϵZ+ is follows B)} DeMorgan’s Law = {x | x ∉ A∩B} A v x ∉ A∩B} B} Definition of negation sign _ _ = {x | x ϵZ+ is follows A v x ϵZ+ is follows B} Definition of negation sign _ _ = {x| x ϵZ+ is follows A U B } Definition of union _ _ = A U B Answer 2 A ∩ (B U C) = (A ∩ B) U (A ∩ C) ={x | x ϵZ+ is follows A ∩ (B U C)} Definition of set notation ={x | x ϵZ+ is follows A ∧ x x ϵZ+ is follows (B U C)} Definition of intersection ={x | x ϵZ+ is follows A ∧ x (x ϵZ+ is follows B v x ϵZ+ is follows C)} Definition of union ={x | (x ϵZ+ is follows A ∧ x x ϵZ+ is follows B) v (x ϵZ+ is follows A ∧ x x ϵZ+ is follows C)} Distributive law ={x | x ϵZ+ is follows (A ∩ B) U (A ∩ C)} Definitions of union and intersection = (A ∩ B) U (A ∩ C) Answer. Inductive proofs Basis step: usually P(1). -Solve for P(1) and verify that both sides are equal. Inductive hypothesis: Assume P(k) is true. -Replace n in P(n) with k. Inductive step: P(k) P(k+1) -Find P(k+1). -For the left side: Just add the next iteration to the summation. *Ex (For the left side): P(k)=1 + 2 + … + k P(k+1)=1 + 2 + … + k + (k+1) -For the right side, just plug in (k+1) for every k *Ex (For the right side): P(k)=k^ P(k+1) = (k+1)^ -Next, take the solution for P(k+1) of the right side and equate it to the P(k) of the right side plus the last term of the P(k+1) of the left side. *Ex: Consider the examples above.
P(n, r) = n! ( n − r )!
C(n, r) = n! r! ( n − r )! List of primes 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97