Presentation is loading. Please wait.

Presentation is loading. Please wait.

Section 2.1 Proof Techniques Introduce proof techniques:   o        Exhaustive Proof: to prove all possible cases, Only if it is about a.

Similar presentations


Presentation on theme: "Section 2.1 Proof Techniques Introduce proof techniques:   o        Exhaustive Proof: to prove all possible cases, Only if it is about a."— Presentation transcript:

1 Section 2.1 Proof Techniques Introduce proof techniques:   o        Exhaustive Proof: to prove all possible cases, Only if it is about a finite collection   o        Direct Proof: to prove PQ is true, Assume P is true, and deduce Q (like what we have done in Chap1)   o        Contraposition: to prove P Q is true By proving Q P   CS130 Young

2 k[ P(k) true  P(k+1) true] P(n) true,n
o       Contradiction: to prove PQ is true, (indirect proof) Assume both the hypothesis and the negation of the conclusion are true, then try to deduce some contradiction from this assumption.   o        Counterexample: to disprove something   o        Induction: to prove that P(n) is true, n Use the principle of mathematical induction:   P(1) is true k[ P(k) true  P(k+1) true] P(n) true,n CS130 Young

3 n n! 2n 1 2 4 3 6 8 · Proof by Exhaustion:
eg: “For any positive integer n less than or equal to 3, n! < 2n” n n! 2n 1 2 4 3 6 8 CS130 Young

4 eg:. “If an integer between 5and 15 is divisible by 6, then it
eg: “If an integer between 5and 15 is divisible by 6, then it is also divisible by 3” (Note: If the above problem is about all integers, then we cannot use exhaustive proof) Number Divisible by 6 Divisible by 3 5 No 6 Yes: 6 = 1X6 Yes: 6 = 2X3 7 8 9 Yes 10 11 12 Yes: 12 = 2X6 Yes: 12 = 4X3 13 14 15 CS130 Young

5 eg: “Every integer less than 10 is bigger than 5”
Proof by Counterexample: eg: “Every integer less than 10 is bigger than 5” To prove the statement is not true, find a counterexample, integer = 4 < 10, but not > 5. eg: disprove that “the sum of any three consecutive integers is even.” counterexample : 2+3+4=9 CS130 Young

6 eg: “for all x [x is divisible by 6  x is divisible by 3]”
·        Direct Proof: eg: “for all x [x is divisible by 6  x is divisible by 3]” X is divisible by 6  x = k*6, for some integer k (hypothesis)  x = k*2*3  x = (k*2)*3 (k*2) is some integer x is divisible by 3 CS130 Young

7 eg: “the product of two even integers is even”
Let x = 2m, y = 2n for some integer m, n (hypothesis)  xy = (2m)(2n) = 2(2mn), which is even. eg: “the sum of two odd integers is even” Let x = 2m+1, y = 2n+1 for some integer m,n (hypothesis)  x + y = 2m + 2n+ 2 = 2(m+n+1), where m+n+1 is an integer x+y is even. CS130 Young

8 Prove: n even  n2 even (P  Q  Q  P)
·        Contraposition: eg: “If the square of an integer is odd, then the integer must be odd.” “n2 odd  n odd” Prove: n even  n2 even (P  Q  Q  P) Let n = 2m for some integer m (hypothesis)  n2 = n * n = 2m*2m = 2(2m2)  n2 is even. CS130 Young

9 · eg: “xy is odd iff both x and y are odd.”
() by direct proof: Let x = 2m+1, y=2n+1 for some m, n  integers  xy = (2m+1)(2n+1) = 4mn + 2m + 2n +1 = 2(2mn+m+n) +1  since 2mn + m + n is an integer, xy is odd. () by contraposition: to prove that : x even or y even, then xy even case1 x even, y odd: Let x = 2m, y = 2n+1 xy = 2(2mn + m), which is even case2 x odd, y even: similar to case1. case3 x even, y even: Let x = 2m, y = 2n xy = 2(2mn), which is even CS130 Young

10 · Proof by Contradiction: Since (P  Q F)  (P  Q) is a tautology,
It is sufficient to prove P  Q F, then P  Q is true. eg: “If a number added to itself gives itself, then the number is 0.” i.e. “x + x = x, then x = 0”: Assume x + x = x and x  0  2x = x and x  0  2 = 1, which is a contradiction the assumption must be wrong CS130 Young

11  4 + 4 – 3 = 0 or 5 = 0, which is a contradiction.
·eg: “if x2 + 2x – 3 = 0, then x  2” Let x2 + 2x – 3 = 0 and assume x = 2,  – 3 = 0 or 5 = 0, which is a contradiction. ( by direct proof: if x2 + 2x – 3 = 0  (x + 3)(x –1)= 0  x = -3 or x = 1  x  2 ) (by contraposition: if x = 2  x2 + 2x – 3 = 5  0 ) CS130 Young


Download ppt "Section 2.1 Proof Techniques Introduce proof techniques:   o        Exhaustive Proof: to prove all possible cases, Only if it is about a."

Similar presentations


Ads by Google