(a) 14 and 42 (b) 33 and 18 (c) 45 and 108 (d) 24 and 2039, given that 2039 is a prime number

Similar documents
Ch 4.2 Divisibility Properties

All variables a, b, n, etc are integers unless otherwise stated. Each part of a problem is worth 5 points.

COMP239: Mathematics for Computer Science II. Prof. Chadi Assi EV7.635

4 Powers of an Element; Cyclic Groups

Number Theory Math 420 Silverman Exam #1 February 27, 2018

Lecture 11 - Basic Number Theory.

Homework #2 solutions Due: June 15, 2012

Congruence of Integers

Math Circle Beginners Group February 28, 2016 Euclid and Prime Numbers Solutions

Exercises Exercises. 2. Determine whether each of these integers is prime. a) 21. b) 29. c) 71. d) 97. e) 111. f) 143. a) 19. b) 27. c) 93.

MTH 346: The Chinese Remainder Theorem

a the relation arb is defined if and only if = 2 k, k

Intermediate Math Circles February 29, 2012 Linear Diophantine Equations I

2301 Assignment 1 Due Friday 19th March, 2 pm

The following is an informal description of Euclid s algorithm for finding the greatest common divisor of a pair of numbers:

Number Theory Alex X. Liu & Haipeng Dai

Number Theory Basics Z = {..., 2, 1, 0, 1, 2,...} For, b Z, we say that divides b if z = b for some. Notation: b Fact: for all, b, c Z:

Senior Math Circles Cryptography and Number Theory Week 2

WORKSHEET ON NUMBERS, MATH 215 FALL. We start our study of numbers with the integers: N = {1, 2, 3,...}

MATH FINAL EXAM REVIEW HINTS

Chuck Garner, Ph.D. May 25, 2009 / Georgia ARML Practice

2.3 In modular arithmetic, all arithmetic operations are performed modulo some integer.

The Euclidean Algorithm and Multiplicative Inverses

Chapter 5.1: Induction

Basic elements of number theory

Basic elements of number theory

An Algorithm for Prime Factorization

NOTES ON INTEGERS. 1. Integers

MATH 501 Discrete Mathematics. Lecture 6: Number theory. German University Cairo, Department of Media Engineering and Technology.

MATH 145 Algebra, Solutions to Assignment 4

Some Facts from Number Theory

D-MATH Algebra I HS18 Prof. Rahul Pandharipande. Solution 1. Arithmetic, Zorn s Lemma.

Number Theory. CSS322: Security and Cryptography. Sirindhorn International Institute of Technology Thammasat University CSS322. Number Theory.

Chapter 3 Basic Number Theory

3 The fundamentals: Algorithms, the integers, and matrices

10 Problem 1. The following assertions may be true or false, depending on the choice of the integers a, b 0. a "

Divisibility in the Fibonacci Numbers. Stefan Erickson Colorado College January 27, 2006

MATH 420 FINAL EXAM J. Beachy, 5/7/97

cse 311: foundations of computing Fall 2015 Lecture 12: Primes, GCD, applications

cse 311: foundations of computing Spring 2015 Lecture 12: Primes, GCD, applications

Chapter 3: The Euclidean Algorithm and Diophantine. Math 138 Burger California State University, Fresno

Writing Assignment 2 Student Sample Questions

NUMBER THEORY AND CODES. Álvaro Pelayo WUSTL

Solving Diophantine Equations With Unique Factorization

Math 4400 First Midterm Examination September 21, 2012 ANSWER KEY. Please indicate your reasoning and show all work on this exam paper.

M381 Number Theory 2004 Page 1

Number Theory Proof Portfolio

MATH 4400 SOLUTIONS TO SOME EXERCISES. 1. Chapter 1

Greatest Common Divisor MATH Greatest Common Divisor. Benjamin V.C. Collins, James A. Swenson MATH 2730

Math Circle Beginners Group February 28, 2016 Euclid and Prime Numbers

CHAPTER 6. Prime Numbers. Definition and Fundamental Results

Intermediate Math Circles February 26, 2014 Diophantine Equations I

Number Theory Marathon. Mario Ynocente Castro, National University of Engineering, Peru

Discrete Mathematics and Probability Theory Fall 2013 Vazirani Note 3

Practice Number Theory Problems

4 Number Theory and Cryptography

Input Decidable Language -- Program Halts on all Input Encoding of Input -- Natural Numbers Encoded in Binary or Decimal, Not Unary

Algorithmic number theory. Questions/Complaints About Homework? The division algorithm. Division

MATH 361: NUMBER THEORY FOURTH LECTURE

Lecture 7.4: Divisibility and factorization

4.4 Solving Congruences using Inverses

Proofs. Methods of Proof Divisibility Floor and Ceiling Contradiction & Contrapositive Euclidean Algorithm. Reading (Epp s textbook)

MATH 433 Applied Algebra Lecture 4: Modular arithmetic (continued). Linear congruences.

SOLUTIONS Math 345 Homework 6 10/11/2017. Exercise 23. (a) Solve the following congruences: (i) x (mod 12) Answer. We have

Discrete Mathematics with Applications MATH236

Rings and modular arithmetic

Mat Week 8. Week 8. gcd() Mat Bases. Integers & Computers. Linear Combos. Week 8. Induction Proofs. Fall 2013

2. THE EUCLIDEAN ALGORITHM More ring essentials

Introduction to Cryptography CS 355 Lecture 3

Applied Cryptography and Computer Security CSE 664 Spring 2017

Solution Sheet (i) q = 5, r = 15 (ii) q = 58, r = 15 (iii) q = 3, r = 7 (iv) q = 6, r = (i) gcd (97, 157) = 1 = ,

Student Responsibilities Week 8. Mat Section 3.6 Integers and Algorithms. Algorithm to Find gcd()

Mathematical Foundations of Public-Key Cryptography

Chapter 14: Divisibility and factorization

Mathematical Foundations of Cryptography

LECTURE NOTES IN CRYPTOGRAPHY

Chapter 4 Finite Fields

ICS141: Discrete Mathematics for Computer Science I

The Structure of Z p when p is Prime

MATH10040 Chapter 1: Integers and divisibility

Outline. Some Review: Divisors. Common Divisors. Primes and Factors. b divides a (or b is a divisor of a) if a = mb for some m

Outline. AIT 682: Network and Systems Security. GCD and Euclid s Algorithm Modulo Arithmetic Modular Exponentiation Discrete Logarithms

Do not open this exam until you are told to begin. You will have 75 minutes for the exam.

The Fundamental Theorem of Arithmetic

CSC 474 Information Systems Security

An integer p is prime if p > 1 and p has exactly two positive divisors, 1 and p.

Discrete Structures Lecture Primes and Greatest Common Divisor

Ma/CS 6a Class 2: Congruences

Number Theory Marathon. Mario Ynocente Castro, National University of Engineering, Peru

CSC 474 Network Security. Outline. GCD and Euclid s Algorithm. GCD and Euclid s Algorithm Modulo Arithmetic Modular Exponentiation Discrete Logarithms

Proof 1: Using only ch. 6 results. Since gcd(a, b) = 1, we have

The Euclidean Algorithm

PROBLEM SET 1 SOLUTIONS 1287 = , 403 = , 78 = 13 6.

CS Asymptotic Notations for Algorithm Analysis

NOTES ON SIMPLE NUMBER THEORY

MATH 3240Q Introduction to Number Theory Homework 4

Numbers. Çetin Kaya Koç Winter / 18

Notes for Recitation 6

Number Theory Solutions Packet

MATH 3330 ABSTRACT ALGEBRA SPRING Definition. A statement is a declarative sentence that is either true or false.

Transcription:

Math 236: Discrete Mathematics with Applications Tutorial 2: 23 February 2012 1. Determine which of the following pairs of integers are relatively prime (give reasons for your answers): (a) 14 and 42 (b) 33 and 18 (c) 45 and 108 (d) 24 and 2039, given that 2039 is a prime number (a) Note that 14 = 2 7 and 42 = 2 3 7. Thus, 2 14 and 2 42, gcd(14, 42) 2 1. Hence 14 and 42 are not relatively prime. (b) Similarly to (a.), 3 33 and 3 18. Thus, gcd(33, 18) 3 1. Hence 33 and 18 are not relatively prime. (c) Note that 45 = 3 3 5 and 108 = 2 2 3 3 3. Thus, gcd(45, 108) = 6 1. Hence, 45 and 108 are not relatively prime. (d) We are told that 2039 is a prime number. Thus, the only positive divisors of 2039 are 1 and 2039. Therefore, the only divisor of 24 which is also a divisor of 2039 is 1. Hence, gcd(24, 2039) = 1 and 24 and 2039 are relatively prime. 2. Let R be a relation dened on Z by arb if gcd(a, b) = 1. Determine, with justication, whether R is: (i) reexive, (ii) symmetric, (iii) transitive In this case, R is not reexive. We prove this by giving the following counter-example: 2 Z and gcd(2, 2) = 2. Thus, 2 R 2. Let x, y Z. To prove that R is symmetric, we assume that xry and we must show that yrx. By our assumption that xry, it follows that gcd(x, y) = 1. Thus, the greatest common divisor of x and y is 1. But this means that the greatest common divisor of y and x is 1. Hence, gcd(y, x) = 1. Thus, yrx. In this case, R is not transitive. We prove this by giving the following counter-example: 2, 3, 4 Z and 2R3 and 3R4. But, 2 R 4. 3. Use the Division Algorithm to nd the following: (a) gcd(8, 21) (b) gcd(331, 1324) (c) gcd(67942, 4209) (a) Applying the Division algorithm: 0 21 8 5 21 = 2 8 + 5 1 8 5 3 8 = 5 + 3 2 5 3 2 5 = 3 + 2 3 3 2 1 3 = 2 + 1 4 2 1 0 2 = 2 1 + 0

Thus, gcd(8, 21) = 1 (b) Applying the Division algorithm: Thus, gcd(1324, 331) = 331 (c) Applying the Division algorithm: Thus, gcd(67942, 4209) = 23 0 1324 331 0 1324 = 4 331 + 0 0 67942 4209 598 67942 = 16 4209 + 598 1 4209 598 23 4209 = 7 598 + 23 2 598 23 0 598 = 26 23 + 0 4. For each pair a, b of integers in the previous question, use the Extended Division Algorithm to nd integers s, t such that gcd(a, b) = sa + tb (a) From the previous question we get: gcd(8, 21) = 1 = 3 2 = 3 (5 3) = 2 3 5 = 2(8 5) 5 = 2 8 3 5 = 2 8 3(21 2 8) = 8 8 3 21 Therefore, s = 8 and t = 3 (b) From the previous question we get that gcd(1324, 331) = 331. Therefore, s = 0 and t = 1 (c) From the previous question we get: gcd(67942, 4209) = 23 = 4209 7 598 = 4209 7(67942 16 4209) = 7 67942 + 113 4209 Therefore, s = 7 and t = 113 5. Find, where possible, each of the following: (a) 8 1 Z 21 (b) 331 1 Z 1324 (c) 4209 1 Z 67942 (d) 337 1 Z 490256 (e) 110 1 Z 273

Hint: Make use of questions 3 and 4, where applicable (a) From (3.a) and (4.a), gcd(8, 21) = 1 = 8 8 3 21. Thus, 8 1 exists in Z 21 and 8 1 = 8. (b) From (3.b), gcd(1324, 331) = 331. Thus, 331 1 does not exist in Z 1324. (c) From (3.c), gcd(67942, 4209) = 23. Thus, 4209 1 does not exist in Z 67942. (d) Applying the Division algorithm: 0 490256 337 258 490256 = 1454 337 + 258 1 337 258 79 337 = 258 + 79 2 258 79 21 258 = 3 79 + 21 3 79 21 16 79 = 3 21 + 16 4 21 16 5 21 = 16 + 5 5 16 5 1 16 = 3 5 + 1 Thus, gcd(490256, 337) = 1. So, 337 1 exists in Z 490256. Applying the Extended Division Algorithm, Thus, 337 1 = 93105 in Z 490256. 1 = 16 3 5 = 16 3(21 16) = 3 21 + 4 16 = 3 21 + 4(79 3 21) = 4 79 15 21 = 4 79 15(258 3 79) = 15 258 + 49 79 = 15 258 + 49(337 258) = 49 337 64 258 = 49 337 64(490256 1454 337) = 64 490256 + 93105 337 6. Let a and b be relatively prime integers. Assume that a c and b c, where c is an integer. Prove that (ab) c Since a and b are relatively prime, gcd(a, b) = 1. Thus, there exist integers s and t such that Multiplying this equation by c, we get that 1 = sa + tb. (1) c = sac + tbc. (2) By the assumption that a c and b c, it follows that there exist integers u and v such that c = ua and c = vb. This allows us to rewrite equation 2 as follows: Since sv + tu Z, ab c. c = savb + tbua = ab(sv + tu).

7. If a and b are positive integers with a > b, show that gcd(a, b) = gcd(a, a b) Let d = gcd(a, b). Thus, d a and d b. Therefore, there exist integers s and t such that a = ds and b = dt. Thus, a b = ds dt = d(s t). Since s t Z, d (a b). Therefore, d is a common divisor of a and a b. All we need to show is that d the the greatest common divisor of a and a b. To do that, let p be a common divisor of a and a b. We will show that d p. Since p is a common divisor of a and a b, p a and p (a b). Therefore, there exist integers u and v such that a = pu and a b = pv. Now, b = a pv = pu pv = p(u v). 8. Hence, p b. Thus, p is a common divisor of a and b. But since d is the greatest of a and b, it follows that d p. This proves the result. common divisor (a) Give an example of positive integers p, a, and b where p ab, but p a and p b (b) Show that if p is a prime number, and a and b are positive integers such that p ab, then p a or p b (a) Consider p = 6, a = 4 and b = 3. Now, 6 (4 3) and 6 4 and 6 3. (b) Let a and b be positive integers and let p be a prime number such that p ab. Assume that p does not divide a (that is, assume that p a). We will prove that p b. By our assumption, p { }a. This implies that p is not a common factor of p and a. Since p is prime, the only positive factors of p are 1 and p. Thus the only common factor of p and a is 1. Hence, gcd(p, a) = 1 This implies that there exist integers s and t such that Multiplying the equation by b we get that 1 = sp + ta b = spb + tab Since p ab, there exists and integer u such that ab = up. Hence, b = spb + tup = p(sb + tu) Since sb + tu Z, p b and the result is proved.

9. Let m and n be relatively prime positive integers. Let f : Z m Z m be a function dened by f(x) = nx mod m. Prove that f is one-to-one. See page 88 for a denition of mod m To prove that f is one-to-one, let x, y Z m such that f(x) = f(y). We show that x = y.by dention of f, f(x) = f(y) implies that This implies that Since gcd(m, n) = 1, n 1 exists in Z m. Hence, and nx mod m = ny mod m nx ny (mod m) n 1 nx n 1 ny (mod m) x y (mod m) Therefore, m (x y). That is, x = y + mt for some t Z. Since x and y are both elements of Z m, t must equal 0. Hence, x = y and f is one-to-one. 10. Calculate each of the following: (a) φ(14), φ(15), (16), φ(17), φ(25) (b) φ(123) (c) φ(2 11 ) (d) φ(6889): Note 6889 = 83 2 and 83 is prime (e) φ(4657) (f) φ(15600) (g) φ(23328) (a) φ(14) = 6, φ(15) = 8, (16) = 8, φ(17) = 16, φ(25) = 20 (b) φ(123) = 80 (c) φ(2 11 ) = 1024 (d) φ(6889) = 6806 (e) φ(4657) = 4656 (f) φ(15600) = 3840 (g) φ(23328) = 7776 11. Estimate the number of prime numbers that are less than or equal to 999 999 π(999 999 ) 999999 ln(999 999 ) = 999998 ln(999) 12. Use Fermat's Little Theorem to answer the following question: Is 1720 prime? Hint: 2 1720 mod 1720 = 656 If 1720 where prime, then gcd(2, 1720) would be 1 and hence 2 1720 1 1 (mod 1)720 This would imply that 2 1720 2 (mod 1)720. But this is not true, since 2 1720 mod 1720 = 656.

13. Use the Square and Multiply Algorithm to determine the remainder when 15 61 is divided by 26 Note that 61 = 2 5 + 2 4 + 2 3 + 2 2 + 1. So, 15 61 = 15 25 +2 4 +2 3 +2 2 +1 = 15 25 15 24 15 23 15 22 15 1 = ( 15 2) 2 4 15 24 15 23 15 22 15 1 (17 15) 24 15 23 15 22 15 1 (mod 2)6 ( 21 2 15 ) 2 3 15 22 15 1 (mod 2)6 ( 11 2 15 ) 2 2 15 1 (mod 2)6 21 22 15 1 (mod 2)6 15 (mod 2)6 Hence, the remainder when 15 61 is divided by 26 is 15.