4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ......

77
4. Elementary Number Theory and Methods of Proof

Transcript of 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ......

Page 1: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4. Elementary Number Theory and Methods of Proof

Page 2: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.1. Direct proof and counter examples I: introduction

Page 3: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Statement

Statement is either true or false.

If it is true, then you need to prove.

If it is wrong, then you need to present counter example.

Page 4: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Review

For all objects A, B, and C,

1. A=A

2. If A=B, then B=A.

3. If A=B and B=C, then A=C.

1. 2=2, n=n

2. If 𝑥 = 2, then 2 = 𝑥.

3. If 𝑥 = 2 and 2 = 1 + 1, then 𝑥 = 1 + 1

Example

Page 5: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Definition of Even and odd integer

If n is an integer, then

n is even ↔ ∃ an integer k such that n=2k.

n is odd ↔ ∃ an integer k such that n =2k+1.

Page 6: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Remark: ( about bi-arrow ↔)

‘n is even ↔ ∃ an integer k such that n=2k.’ means

• If n is even, then there exists an integer k such that n =2k. AND

• If there exists an integer k such that n = 2k, then n is even.

Page 7: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Use the definitions of even and odd to justify your answers to the following questions:

1. Is 0 even?

2. Is -301 odd?

3. If a and b are integers, is 6𝑎2𝑏 even?

4. If a and b are integers, is 10a + 8b + 1 odd?

Page 8: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Definition of prime and composite

n is prime. ↔ 𝑛 > 1 𝑎𝑛𝑑 ∀ positive integer r and s, if n=rs, then either r=1 and s=n or r=n and s=1.

n is composite.

↔ ∃ positive integers r and s such that n=rs and 1<r<n and 1<s<n.

Remark:

1 is neither prime nor composite.

Page 9: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. Is 1 prime?

2. Write the first six prime numbers.

3. Write the first six composite numbers.

Page 10: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proving Existential Statement

∃𝑥 ∈ 𝐷 such that Q(𝑥) is true if, and only if,

𝑄(𝑥) is true for at least one 𝑥 in 𝐷.

Constructive proofs of existence:

1. Find an 𝑥 in 𝐷 that makes 𝑄(𝑥) true. OR

2. Give a set of directions for finding such an 𝑥.

Page 11: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove: ∃ an even integer n that can be written in two ways as a sum of two prime numbers.

Proof: (Find the actual number)

10=5+5 =3+7

Page 12: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Suppose that r and s are integers. Prove the following: ∃ an integer k such that 22r+18s=2k.

Proof. ( Provide the way to find all such integer k)

Let k=11r+9s. Then k is an integer because r and s are integers. Since 2k=2(11r+9s)=22r+18s, the statement is proved.

Page 13: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Disproving Universal Statements by Counterexample

To disprove the universal statement ‘∀𝑥 ∈ 𝐷, if P(x), then Q(x)’, show ′∃𝑥 in D such that P(x) and not Q(x).’

Such 𝑥 is called counterexample.

Page 14: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Disprove the following statement by finding a counterexample:

∀real numbers 𝑎 and 𝑏, if 𝑎2 = 𝑏2, 𝑡ℎ𝑒𝑛 𝑎 = 𝑏.

Page 15: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proving Universal Statement

Convert the given statement into a formal form, ∀𝑥 ∈ 𝐷, if P(x), then Q(x), if the statement is not given by a formal form. Then, use either A or B:

A. (Method of Exhaustion) If D has only finite elements, then check with each element.

B. If D has infinite elements, then use Method of generalizing from the generic particular:

Suppose 𝑥 is a particular but arbitrarily chosen element of the set and show that 𝑥 satisfies the property.

Page 16: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Use the method of exhaustion to prove the following statement:

∀𝑛 ∈ 𝒁, if 𝑛 is even and 4 ≤ 𝑛 ≤ 26, then 𝑛 can be written as a sum of two prime numbers.

Page 17: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. Write the formal statement of ‘ the sum of any two even integers is even.’

2. Prove: the sum of any two even integers is even.

Page 18: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Showing that an existential statement is false.

Existential statement: ∃𝑥 ∈ 𝐷 such that Q 𝑥 .

Negation: ∀𝑥 ∈ 𝐷 such that 𝑥 doesn’t satisfy Q(𝑥).

Therefore, it is enough to show that its negation is true.

Page 19: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. What is the negation of the statement ‘There is a positive integer 𝑛 such that 𝑛2 + 3𝑛 + 2 is prime.’?

2. Prove the following statement is false: There is a positive integer 𝑛 such that 𝑛2 + 3𝑛 + 2 is prime.

Page 20: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Poincare Conjecture

Watch the video.

Page 21: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Conjecture

Statement which is not proven which appears correct.

Mathematicians try to prove or disprove. After a conjecture is proven, the conjecture becomes a Theorem.

Example of conjecture: ( Fermat’s Theorem, Proven by Andrew Wiles)

𝑎𝑛 + 𝑏𝑛 = 𝑐𝑛 for any integer value of 𝑛 greater than two.

Page 22: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Axiom( also called, Postulate)

1. a self-evident truth that requires no proof.

2. a universally accepted principle or rule.

3. Logic, Mathematics: a proposition that is assumed without proof for the sake of studying the consequences that follow from it.

Example:

It is possible to draw a straight line from any point to any other point.

Page 23: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.2. Direct Proof and Counterexample II: Rational

Numbers

Page 24: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Definition: rational, irrational

𝑟 is rational ↔ ∃ integers 𝑎 and 𝑏 such that

𝑟 =𝑎

𝑏 and 𝑏 ≠ 0.

A real number that is not rational is irrational.

Page 25: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. Is 103 a rational number?

2. Is −5

39 a rational number?

3. Is 0.281 a rational number?

4. Is 7 a rational number?

5. Is 0 a rational number?

6. Is 2/0 a rational number?

7. Is 2/0 an irrational number?

Page 26: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. Is 0.12121212… a rational number ( where the digits 12 are assumed to repeat forever)?

2. If m and n are integers and neither m nor n is zero, is (m+n)/mn a rational number?

Hint for 1: Use 100x –x=12

Page 27: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Zero Product Property

If neither of two real numbers is zero, then their product is also not zero.

Remark:

1. What is the contrapositive statement of Zero product property given above?

2. Write the zero product property formally.

Page 28: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Theorem (Prove the following theorems)

1. Every integer is a rational number.

2. The sum of any two rational numbers is rational.

Page 29: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Corollary

The double of a rational number is rational.

Remark:

Corollary is a statement whose truth can be immediately deduced from a theorem that has already been proved.

Page 30: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.3. Direct Proof and Counterexample III: Divisibility

Page 31: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Definition: Divisible

If n and d are integers and 𝑑 ≠ 0, then

n is divisible by d if, and only if, n equals d times some integer.

Equivalently,

• n is a multiple of d

• d is a factor of n

• d is a divisor of n

• d divides n.

Page 32: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Notation of d|n

The notation d|n is read ‘d divides n’.

Symbolically, if a and d are integers and 𝑑 ≠ 0,

d|n ↔ ∃ an integer k such that n=dk.

Page 33: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

1. Is 21 divisible by 3?

2. Does 4 divide 40?

3. Does 7|42?

4. Is 32 a multiple of -16?

5. Is 6 a factor of 54?

6. Is 7 a factor of -7?

7. Does 4|15?

8. If a and b are integers, is 3a+3b divisible by3?

Page 34: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Theorem(Transitivity of Divisibility)

For al integers a, b, and c, if a divides b and b divides c, then a divides c.

Page 35: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Is the following statement true or false?

For all integers a and b, if a|b and b|a, then a=b.

Page 36: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Theorem (Unique Factorization of Integers Theorem)

Given any integer n>1, there exist a positive integer k, distinct prime numbers 𝑝1, 𝑝2, … , 𝑝𝑘, and positive integers 𝑒1, 𝑒2, … , 𝑒𝑘 such that

𝑛 = 𝑝1𝑒1𝑝2

𝑒2 … 𝑝𝑘𝑒𝑘

And any other expression for n as a product of prime numbers is identical to this except, perhaps, for the order in which the factors are written. Remark: Unique factorization of integers theorem is also called fundamental theorem of arithmetic.

Page 37: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Standard factored form

Given and integer n>1, the standard factored form of n is an expression of the form

𝑛 = 𝑝1𝑒1𝑝2

𝑒2 … 𝑝𝑘𝑒𝑘

Where k is a positive integer; 𝑝1, 𝑝2, … , 𝑝𝑘 are prime numbers; 𝑒1, 𝑒2, … , 𝑒𝑘 are positive integers; and 𝑝1 < 𝑝2 < ⋯ < 𝑝𝑘

Page 38: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Write 3,300 in standard factored form.

Page 39: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.4. Direct Proof and Counterexample IV:

Division into cases and the quotient-remainder theorem

Page 40: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Quotient Remainder Theorem

For any integer n and any positive integer d( that is, d>0), there exist unique integers q and r

such that

𝑛 = 𝑑𝑞 + 𝑟 where 0 𝑟 < 𝑑.

Definition: Notation

q is called the quotient : q=n div d

r is called the remainder : r=n mod d

Page 41: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

For each of the following values of n and d, find the divisor and remainder.

1. 𝑛 = 54, 𝑑 = 4

2. 𝑛 = −54, 𝑑 = 4

3. 𝑛 = 54, 𝑑 = 60

Page 42: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Compute 32 div 9 and 32 mod 9 by hand and with a calculator.

Page 43: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Suppose today is Tuesday, and neither this year nor next year is a leap year. What day of the week will it be 1 year from today?

Page 44: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Suppose m is an integer. If m mod 11= 6, what is 4m mod 11?

Page 45: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Parity Property

Parity of an integer: whether the integer is even or odd.

Parity Property:

Any integer is either even or odd.

Page 46: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Theorem( The Parity Property)

Any two consecutive integers have opposite parity.

Proof:

Page 47: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Theorem

The square of any odd integer has the form 8m+1 for some integer m.

Proof:

Use the fact: any integer can be written in one of the four forms:

n=4q, n=4q+1, n=4q+2, n=4q+3 for some integer q.

Page 48: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.6. Indirect Argument:

Contradiction and Contraposition

Page 49: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Method of Proof by Contradiction

1. Suppose the statement to be proved is false. That is, suppose that the negation of the statement is true.

2. Show that this supposition leads logically to a contradiction.

3. Conclude that the statement to be proved is true.

Page 50: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Remark

Method of Proof by Contradiction is based on the fact that either a statement is true or false but not both.

Example

Jane didn’t steal an i-phone at Best Buy on December 20, 2012.

Proof by contradiction: Suppose that Jane stole an i-phone at Best Buy on December 20, 2012. She had a car accident and was in coma on that day. Thus, the statement cannot be true.

Page 51: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove the following theorem by contradiction.

1. There is no greatest integer.

2. There is no integer that is both even and odd.

3. The sum of any rational number and any irrational number is irrational.

Page 52: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof 3. Suppose not. Then, there is a rational number r and an irrational number s such that r+s is rational.

By definition of rational, r=a/b and 𝑟 + 𝑠 = 𝑐/𝑑 for some integers a, b(≠ 0), c and d(≠ 0).

By substitution, 𝑎

𝑏+ 𝑠 =

𝑐

𝑑, and so

𝑠 =𝑐

𝑑−

𝑎

𝑏=

𝑏𝑐 − 𝑎𝑑

𝑏𝑑.

Since 𝑏𝑐 − 𝑎𝑑 and 𝑏𝑑 (≠ 0) are integers, 𝑠 is a rational number. Contradiction!

Page 53: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Method of Proof by Contraposition

1. Express the statement to be proved in the form: ∀𝑥 in D, if P(x), then Q(x).

2. Rewrite this statement in the contrapositive form: ∀𝑥 in D, if Q(x) is false, then P(x) is false.

3. Prove the contrapositive by a direct proof:

a. Suppose x is a particular but arbitrarily chosen element of D such that Q(x) is false.

b. Show that P(x) is false.

Page 54: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove the following Proposition by using contraposition:

For all integers 𝑛, if 𝑛2 is even, then 𝑛 is even.

Remark:

‘Proposition’ refers to a statement that is somewhat less consequential but nonetheless worth writing down.

Page 55: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof by contraposition

Suppose 𝑛 is odd. Then 𝑛 = 2𝑘 + 1 for some integer 𝑘.

𝑛2 = (2𝑘 + 1)2= 4𝑘2 + 4𝑘 + 1= 2 2𝑘2 + 2𝑘 + 1.

Thus, 𝑛2 is odd.

Page 56: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof by contradiction

Suppose that 𝑛2 is even but 𝑛 is odd. Then 𝑛 = 2𝑘 + 1 for some integer 𝑘.

𝑛2 = (2𝑘 + 1)2= 4𝑘2 + 4𝑘 + 1= 2 2𝑘2 + 2𝑘 + 1.

Thus, 𝑛2 is odd.

By the parity property, no integer can be both even and odd. Thus, we have contradiction.

Page 57: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.7. Indirect Argument

Two Classical Theorems

Page 58: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove the Theorem ‘ 2 is irrational.’

Hint:

Use contradiction method to prove.

Use facts:

1. For all integers 𝑛, if 𝑛2 is even, then 𝑛 is even.

2. For any integer q, there exist integers m and n such that gcd(m, n) =1 and q= m/n.

Page 59: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof

Suppose that 2 is rational. Then, there exists integers 𝑚 and 𝑛 such that gcd (𝑚, 𝑛) = 1 and 2 =

𝑚

𝑛.

Thus, 2 =𝑚2

𝑛2 . Therefore, 𝑚2 = 2𝑛2.

Thus, 𝑚2 is even. It implies 𝑚 is even because of the proposition we proved.

Let 𝑚 = 2𝑘 for some integer 𝑘. Then, 𝑚2 = (2𝑘)2=4𝑘2 = 2𝑛2.

Thus, 𝑛2 = 2𝑘2. It implies that 𝑛2 is even. Thus, 𝑛 is even. It contradicts to the assumption gcd (𝑚, 𝑛) = 1.

Page 60: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove the Proposition ‘For any integer a and any prime number p, if p|a, then p∤ 𝑎 + 1 .′ Hint: 1. Prove by contradiction. 2. Useful facts: a. The only divisors of 1 are 1 and -1. b. Prime numbers are positive integers greater

than 1 that has no positive divisors other than 1 and itself.

Page 61: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof Suppose not. Then, there exists an integer a and a prime number 𝑝 such that 𝑝|𝑎 and 𝑝|𝑎 + 1. Then, there exist integers r and s such that 𝑎 = 𝑝 × 𝑟 and 𝑎 + 1 = 𝑝 × 𝑠.

1 = (𝑎 + 1) − 𝑎 = 𝑝 × 𝑠 − 𝑝 × 𝑟 = 𝑝(𝑠 − 𝑟) . Since the only divisors of 1 are 1 and -1, we have two possibilities: i. 𝑝 = 1 and 𝑠 − 𝑟 = 1 or ii. 𝑃 = −1 and 𝑠 − 𝑟 = −1. Since we assumed that 𝑝 is prime, 𝑝 must be greater than 1. Contradiction!

Page 62: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Prove the Theorem: The set of prime numbers is infinite.

Hint:

1. Prove by contradiction.

2. Use:

a. Any integer>1 is divisible by a prime numbers.

b. For any integer a and any prime number p, if p|a, then p∤ 𝑎 + 1 .

Page 63: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof

Suppose not. Then, there exists the largest prime number N. Let 𝑎 = 2 × 3 × 5 × ⋯ × 𝑁.

Then, a+1 is either a composite number or a prime number.

If a+1 is a prime number, then it contradicts to our assumption because N<a+1.

If a+1 is a composite number, then a+1 is divided by a prime number bigger than N because any prime number less than or equal to N divides a, which implies that any prime number less than or equal to N doesn’t divides a+1. Thus, it contradicts to our assumption.

Page 64: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Test for Primality

Given an integer n>1, to test whether n is prime check to see if it is divisible by a prime number less than or equal to its square root. If it is not divisible by any of these numbers, then it is prime.

Page 65: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Remark

Are they prime numbers?

2 × 3 + 1 = 7

2 × 3 × 5 + 1 = 31 2 × 3 × 5 × 7 + 1 = 211

2 × 3 × 5 × 7 × 11 + 1 = 2311 2 × 3 × 5 × 7 × 11 × 13 + 1 = 30031

Page 66: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

30031 is not a prime number. 300031 = 59 × 509

Page 67: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

4.8. Application

The Euclidean Algorithms

Page 68: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Definition: gcd(a, b)

Let a and b be integers that are not both zero. The greatest common divisor of a and b, denoted gcd(a, b), is that integer d with the following properties: 1. d is a common divisor of both a and b. In other

words, d|a and d|b 2. For all integers c, if c is a common divisor of both

a and b, then c is less than or equal to d. In other words,

For all integers c, if c|a and c|b, then 𝑐 ≤ 𝑑.

Page 69: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Brute-force method to find gcd(a,b)

Factor into prime numbers and list the factors of each number a and b.

List the common factors(divisors)

Find the greatest one

Page 70: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Brute-force method is useful when two integers are small.

How about gcd(4131, 2431)?

Use Euclidean Algorithm!

Page 71: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Find

a. gcd(72, 63)

b. gcd(1020, 630)

Answer:

a. 9

b. 220

Page 72: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Lemma

1. If 𝑟 is a positive integer, then gcd (𝑟, 0) = 𝑟.

2. If 𝑎 and 𝑏 are any integers not both zero, and if 𝑞 and 𝑟 are any integers such that

a=b∙ q+ r, then gcd(a,b)=gcd(b,r).

Page 73: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Proof

1. Let r be a positive integer. Then,

𝑟 = 𝑟 ∙ 1 and 0 = 𝑟 ∙ 0.

Thus, r is the common divisor of r and 0. Any divisor of r cannot be bigger than r. Therefore, r =gcd(r,0).

2. ( Application is more important. So, we will skip the proof. The proof of this has two steps:

a. Show gcd 𝑎, 𝑏 ≤ gcd 𝑏, 𝑟

b. Show gcd 𝑏, 𝑟 ≤ gcd 𝑎, 𝑏 )

Page 74: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Euclidean Algorithm

1. It is used to find gcd(a, b) where a and b are non-negative integers.

2. We use Lemma 1 and 2 in the slide in the previous page repeatedly until we get

gcd(a, b).

Page 75: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Example

Use the Euclidean algorithm to find

gcd(330, 156).

Solution:

gcd(330, 156)=gcd( 156, 18)=gcd(18, 12)=gcd(12, 6)=gcd(6,0)=6.

Page 76: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

At the exam, when you find gcd(a,b)

You have to show the number you find is the greatest and common divisor.

If you use brute force method, then your factorization will show that.

If you use the Euclidean algorithm, then gcd(a,b)=…..=gcd(d, 0)( in the last line).

Show your calculation in detail!

Page 77: 4. Elementary Number Theory and Methods of Proof · Use the method of exhaustion to prove the ... Theorem. Example of conjecture: ( Fermat ... Zero Product Property

Group Activity

Find gcd(1188, 385).