Presentation is loading. Please wait.

Presentation is loading. Please wait.

Section 1.5: Methods of Proof Now that we have covered propositional and predicate logic, we will introduce some formal rules of reasoning for constructing.

Similar presentations


Presentation on theme: "Section 1.5: Methods of Proof Now that we have covered propositional and predicate logic, we will introduce some formal rules of reasoning for constructing."— Presentation transcript:

1 Section 1.5: Methods of Proof Now that we have covered propositional and predicate logic, we will introduce some formal rules of reasoning for constructing proofs. Proof techniques will be introduced formally at first, but as we become more familiar with them, we will gradually start to use these techniques on a more casual and less explicit level. Of course the techniques and proof methods must still be observed in order for your proofs to be valid but you will develop less need to explicitly refer to the steps in order to construct a valid proof.

2 Definitions A theorem is a statement that can be shown to be true. A proof is a sequence of statements that forms an argument showing that a theorem is true. A fallacy is an incorrect form of reasoning that is often erroneously believed to be a valid argument. Fallacies are often found in “proofs” of an invalid “theorem”. A lemma is a simple theorem used in the proof of others. A corollary is a proposition that follows readily from a theorem that has been proved. A conjecture is a statement whose truth value is unknown. When a proof of a conjecture is found, it becomes a thm.

3 Rules of Inference We will introduce rules of inference for propositional logic. Rules of inference allow you to take steps in a proof toward your goal. A proof starts out with assumptions (usually) then by using rules of inference with the assumptions we move closer and closer to the desired result of the theorem. When we have reached the desired result by using only our assumptions and valid rules of inference then the theorem is proved.

4 Rule of Inference: Modus Ponens (p  (p  q))  q is a tautology. It states that if we know that both an implication p  q is true and that its hypothesis, p, is true, then the conclusion, q, is true. Ex: Suppose the implication “If the bus breaks down, then I will have to walk” and its hypothesis “the bus breaks down” are true. Then by modus ponens it follows that “I will have to walk”. Ex: Assume that the implication (n > 3)  (n 2 > 9) is true. [It actually is true, universal quantification]. Suppose also that n > 3. Then by modus ponens, it follows that n 2 > 9.

5 Fallacy: Affirming the Conclusion (q  (p  q))  p is a contingency. It states that if we know that both an implication p  q is true and that its conclusion, q, is true, then the hypothesis, p, is true. Ex: Suppose the implication “If the bus breaks down, then I will have to walk” and its conclusion “I will have to walk” are true. It does not follow that the bus broke down. Perhaps I simply missed the bus. Ex: Consider the implication (n > 3)  (n 2 > 9) which is true. Suppose also that n 2 > 9. It does not follow that n > 3. It might be that n = -4 for example.

6

7 Ex: Consider these statements “If I buy something, then I go to the store.” and “If I go to the store, then I drive my car.” If these two statements are true, then by hypothetical syllogism we can conclude that “If I buy something, then I drive my car.” Ex: Consider the statements “It is raining today or it is snowing today.” and “It is not snowing today or it is windy today.” If we know both of these statements are true then what can we conclude? By the rule of resolution, we know that “It is raining today or it is windy today.”

8 Valid Arguments An argument is called valid if whenever all of the hypotheses are true then the conclusion is true. So to show that q logically follows from p 1, p 2, …, p n is the same thing as showing that the implication p 1  p 2  …  p n  q is a tautology.

9 Ex: Show that [(  p  q)  (r  p)  (  r  s)  (s  t)]  t is a true statement. Proof: We assume the hypotheses (  p  q), (r  p), (  r  s), and (s  t). 1.By (  p  q) we know  p [simplification]. 2.By (r  p) we know  p   r [contrapositive]. 3.By 2 and (  r  s) we know (  p  s) [hypothetical syllogism]. 4.By 3 and (s  t) we know (  p  t) [hypothetical syllogism]. 5.By 1 and 4 we know t [modus ponens].

10 Resolution Resolution is a rule of inference that we saw earlier in our table: (p  q)  (  p  r)  q  r. This rule turns out to be very useful in the field of automated reasoning (trying to get a computer to draw conclusions based on observations). As it turns out the operators , , and  form a functionally complete logic system. What this means is that any statement in proposition that we wish to express, we could express the statement using only these three operators (though the statement might be substantially longer if we choose to do so). [Transform , ,  ] We won’t go into the details of automated resolution because this isn’t an algorithms course. However, we can use the technique of resolution to come up with a more structured approach to solving some logic puzzles.

11 (1)b  cor  b  c (2)  (c  g)or  c   g (3)  (  g   h)org  h (4)h   cor  h   c By combining (1) and (2) we get (5)  b   g By combining (1) and (4) we get (6)  b   h By combining (2) and (3) we get (7)  c  h By combining (3) and (4) we get (8) g   c

12 (1)  b  c (5)  b   g (2)  c   g(6)  b   h (3)g  h (7)  c  h (4)  h   c (8) g   c By combining (1) and (7) we get (9)  b  h By combining (1) and (8) we get (10)  b  g By combining (2) and (8) we get (11)  c   c   c By combining (3) and (5) we get (9)  b  h By combining (3) and (6) we get(10)  b  g By combining (4) and (7) we get(11)  c   c   c By combining (5) and (8) we get(12)  b   c By combining (6) and (7) we get(12)  b   c

13 (1)  b  c (5)  b   g (9)  b  h (2)  c   g(6)  b   h (10)  b  g (3)g  h (7)  c  h (11)  c (4)  h   c (8) g   c (12)  b   c By combining (9) and (4) we get(12)  b   c By combining (9) and (6) we get (13)  b   b   b By combining (10) and (2) we get(12)  b   c By combining (10) and (5) we get(13)  b   b   b By combining (11) and (1) we get(13)  b By combining (12) and (1) we get(13)  b   b   b We can see that (13) won’t combine with anything so we’re done. We have come to the same conclusions as before  b and  c.

14 Fallacy: Denying the Hypothesis (  p  (p  q))   q is a contingency. It states that if we know that both an implication p  q is true and that its hypothesis, p, is false, then the conclusion, q, is also false. Ex: Suppose the implication “If the bus breaks down, then I will have to walk” is true but its hypothesis “the bus breaks down” is false. It does not follow that I will not have to walk. Perhaps I simply missed the bus. Ex: Consider the implication (n > 3)  (n 2 > 9) which is true. Suppose also that n  3. It does not follow that n 2  9. It might be that n = -4 for example.

15 Rules of Inference for Quantified Statements The rules of inference for quantified statements are very important. We use these rules when we construct proofs and they are the basis for proving or disproving a universally or existentially quantified statement.

16 Universal Instantiation If we know that  xP(x) is true, then we can conclude that P(c) is true for a particular member c of the universe of discourse. This is called universal instantiation because we are taking an instance, c, from the universe of discourse. This rule is useful when we are given  xP(x) as a premise and we know that c is an element of the universe of discourse for x. Then we know P(c) is true. Ex: We know  x(x 2  0). So by universal instantiation 2 2  0.

17 Universal Generalization If we know that P(c) is true for all elements c in the universe of discourse, then we can conclude that  xP(x) is true. This is called universal generalization. This rule is often used to prove statements of the form  xP(x) by taking an arbitrary element c from the universe of discourse and showing that P(c) is true. It is crucial that c is an arbitrary element from the universe of discourse for this technique to be valid. Ex: Let c be an integer. We know that c 2 is not negative. So c 2  0. Now by universal generalization (since c was an arbitrary integer) we conclude  x(x 2  0).

18 Existential Instantiation If we know that  xP(x) is true, then we can conclude that P(c) is true for a some member c of the universe of discourse. This is called existential instantiation because we are taking an instance, c, from the universe of discourse for which P(c) is true. This rule is particularly useful when we are given  xP(x) as a premise but we need to discuss a particular element. We can simply give a name, c, for an element of the universe of discourse for which P(c) is true. We may not know anything else about c. Ex: We know  x(x 2 = 1). So by existential instantiation c 2 = 1 for some integer c. Now we can talk about c.

19 Existential Generalization If we know that P(c) is for some particular c in the universe of discourse, then we can conclude that  xP(x) is true. This is called existential generalization. This rule is often used to prove statements of the form  xP(x) by finding a particular c in the universe of discourse such that P(c) is true. The alternative to this is to directly show that some element x must exist in the u.d. for which P(x) is true without actual finding a particular element. Ex: 1 2 = 1. So  x(x 2 = x) is true.

20 Often these four rules are used without explicit reference in a proof. We don’t explicitly say, “… by universal generalization …”. But we need to be clear enough in our arguments that it is evident what rule we are using. A proof that uses universal generalization to establish  xP(x) usually starts off “Let x be an integer”. This really means, “Let x be an arbitrary integer”. Then we proceed to show that P(x) is true. Once we reach this conclusion, we don’t usually go on to state that “since x was an arbitrary integer, then P(x) is established for all integers.” We usually just leave it at that once we get to P(x). By the same token, mathematicians use implicit universal quantification. So the statement “The sum of two odd integers is even” means ”for all odd integers x and y, x + y is even”. It does not mean that there exists two odd integers whose sum is even. We will now move on to proof techniques and start putting all of this machinery we have developed to good use.

21 HW #3 We are not done with section 1.5 yet HW #3 is posted to the toolkit now –Due on Monday, February 10, in class –Section 1.4: 3, 8, 10, 15, 19, 26, 32, 37 –Section 1.5: 1, 5, 11, 15, 17, 20, 23, 24, 25, 26 We will have more problems from section 1.5 on HW #4 Let’s continue with section 1.5 now

22 Methods of Proving Theorems We will now discuss approaches to proving theorems. These approaches will use the rules of inference that we have just discussed. Many theorems to be proved are implications. So we will concentrate on methods of proving implications.

23 Direct Proof To prove the implication, p  q, we must show that whenever the hypothesis (p) is satisfied, then the conclusion (q) must also be true. Remember that an implication is only false in the one case where p is true and q is false. So we must rule out this possibility to show that p  q is a tautology. With a direct approach, we first assume that p is true. Then we use our rules of inference, logical equivalences, and previously proved theorems to show that q must also be true. Note that it may not be the case that p is true. If p is false then the implication holds. We assume that p is true so that we can explore this scenario and show that q must necessarily be true as well.

24 Unrelated Definition Def: The integer n is even if there exists an integer k such that n = 2k. That is, the integer n is even if  k(n = 2k) where the universe of discourse for k is all integers. [  k(n = 2k)  n is even] Def: The integer n is odd if there exists an integer k such that n = 2k + 1. That is, the integer n is odd if  k(n = 2k + 1) where the universe of discourse for k is all integers. [  k(n = 2k + 1)  n is odd] Note that an integer is either even or odd (but not both). [n is even  n is not odd] Ex: 7 = 2*3 + 1[7 is odd]16 = 2*8[16 is even] -11 = 2*(-6) + 1[-11 is odd]-6 = 2*(-3)[-6 is even]

25 Ex: Give a direct proof of “If n is odd, then n 2 is odd.” First off, recall that this statement is implicitly a universal quantification “  n(n is odd  n 2 is odd).” [What rule do we need?] Proof: [step 1: Write assumptions] Let n be an odd integer. [Implicitly arbitrary, set up for U.G.] [step 2: Translate assumptions into a form we can work with] Then n = 2k + 1 for some integer k. [Definition of odd] [step 3: Work with it until it is in a form we need for concl.] So n 2 = (2k + 1) 2 = 4k 2 + 4k + 1 = 2(2k 2 + 2k) + 1. [step 4: Realize that you’re there and state your conclusion.] So n 2 = 2*m + 1 where m = (2k 2 + 2k), so n 2 is odd.  2k 2 + 2k is an integer because k is and the integers are closed for +,*,-,^

26 Proof Simplified Theorem: If n is odd, then then n 2 is odd. Proof: Let n be an odd integer. Then n = 2k + 1 for some integer k. So n 2 = (2k + 1) 2 = 4k 2 + 4k + 1 = 2(2k 2 + 2k) + 1. So n 2 = 2*m + 1 where m = (2k 2 + 2k), so n 2 is odd. 

27 Proof Complicated Theorem: If n is odd, then then n 2 is odd. Proof: Assume the hypothesis: let n be an odd integer. Then n = 2k + 1 for some integer k by the definition of an odd integer. So by squaring both sides we see that n 2 = (2k + 1) 2 = 4k 2 + 4k + 1 = 2(2k 2 + 2k) + 1. Now by letting m = 2k 2 + 2k, we see that n 2 = 2*m + 1. Now m is an integer since 2 and k were integers. So n 2 is odd by the definition of an odd integer. Now by universal generalization, since n was chosen as an arbitrary odd integer, then the statement is true for all integers n. 

28 Einstein Simplified “Make everything as simple as possible, but not simpler.” -Albert Einstein

29 Proof Reversed (meet in the middle) Theorem: If n is odd, then then n 2 is odd. Proof: Let n be an odd integer. [Assume the hypothesis as always] We wish to show that n 2 is odd. [State what we desire to conclude] To show that n 2 is odd, we must show that n 2 = 2*m + 1 for some integer m. [Now we realize that we need to know what n 2 equals] Well since n is odd then n = 2k + 1 for some integer k. So n 2 = (2k + 1) 2 = 4k 2 + 4k + 1 = 2(2k 2 + 2k) + 1. So n 2 = 2*m + 1 where m = (2k 2 + 2k), which is what we wanted to show. So n is odd. 

30 Indirect Proof To prove the implication, p  q, we can take advantage of the fact that the contrapositive,  q   p, is logically equivalent to the original statement. We can prove  q   p via the direct approach and then the original implication, p  q, is proven. With an indirect approach, we first assume that q is false. Then we use our rules of inference, logical equivalences, and previously proved theorems to show that p must also be false. Note that it may not be the case that q is false. If q is true then the implication holds. We assume that q is false so that we can explore this scenario and show that p must necessarily be false as well.

31 Ex: Give an indirect proof of “If 3n + 2 is odd, then n is odd.” Recall again that this statement is implicitly a universal quantification “  n(3n + 2 is odd  n is odd).” Proof: We will prove the contrapositive, “If n is not odd, then 3n + 2 is not odd. That is, “If n is even, then 3n + 2 is even.” [step 2: Translate assumptions into a form we can work with] Then n = 2k for some integer k. [Definition of even] [step 3: Work with it until it is in a form we need for concl.] So 3n + 2 = 3(2k) + 2 = 6k + 2 = 2(3k + 1). [step 4: Realize that you’re there and state your conclusion.] So 3n + 2 = 2*m where m = (3k + 1), so 3n + 2 is even.  [step 1: Write assumptions] Let n be an even integer.

32 Vacuous and Trivial Proof To prove the implication, p  q, we must show that whenever the hypothesis (p) is satisfied, then the conclusion (q) must also be true. Remember that an implication is only false in the one case where p is true and q is false. If we can show that p is not ever true then the implication is proved. This is called vacuous proof. Similarly, if we can show that q is always true then the implication is proved. This is called trivial proof.

33 Ex: Use a vacuous proof to show that “If 2n is odd, then 3n is even.” Recall again that this statement is implicitly a universal quantification “  n(2n is odd  3n is even).” Proof: Let n be an integer. Then 2n is even by the definition of even. So 2n is not odd. Hence the hypothesis is not satisfied and the implication is shown to be true.  Ex: Use a trivial proof to show that “If n is odd, then 2n is even.” Recall again that this statement is implicitly a universal quantification “  n(n is odd  2n is even).” Proof: Let n be an integer. Then 2n is even by the definition of even. [It doesn’t matter if n is odd, which is precisely why this is a trivial proof. I could have started off assuming the hypothesis (n is odd).] Hence the conclusion is satisfied, so the implication is true. 

34 Office Hours Summary Me –Olsson Hall, Office 228D –M/T: 3:30-5:00pm and W: 3:30-4:30pm Pascal –Olsson Hall, Conference Room in 113 –R: 9:30-11:00am Emmanuel –Olsson Hall, Classroom 011 –R: 7:00-8:00pm and F: 3:00-4:00pm

35 Another Unrelated Definition PseudoDef: A real number is some number that can be expressed as x 1 x 2 … x n  y 1 y 2 y 3 … where the x i ’s and y i ’s are decimal digits (0,1,2,3,4,5,6,7,8,9) and n is a positive integer. Note that the number of digits to the left of the decimal point must be finite, but the digits to the right of the decimal point extend endlessly and need not repeat. Ex: Any integer n is also a real number [n.000…] 1/2 is a real number [0.5000…] Any quotient of integers, n/m is a real number [use long division]  is a real number [ …] [never repeats]  2 is a real number [ …] [never repeats]

36 Def: A real number r that can be expressed as a quotient of integers, p/q, with q  0 is called rational. A real number that is not rational is called irrational. [r is rational iff  p  Z  q  Z( r = p/q  (q  0))] Ex: Any integer n is a rational number [n/1] 1/2 is a rational number [1/2]  is an irrational number [This is a deep result we will not prove]  2 is an irrational number [We will prove this, but not yet] Ex: Is 0.75 a rational number? Yes. It can be expressed as 3/4. [Note that this is not unique, 6/8, etc.] Ex: Is 5/0.2 a rational number? Yes. It can be expressed as 25/1. This is a very important point. To know that a number is irrational, it is not enough that the number is expressed as a/b but a or b is not an integer. You must know that there is no way to express it as a quotient of integers. [canonical form?]

37 Ex: Prove that the sum of two rational numbers is rational. Restated:  x  y[(x is rat.)  (y is rat.)   z[(z is rat.)  (x + y = z)]] Proof: [State the assumptions] Let x and y be rational numbers. [Translate the assumptions into something we can work with. Remember that we are trying to find out about the sum x + y.] Since x is rational then x = p/q for some integers p and q where q  0. Since y is rational then y = r/s for some integers r and s where s  0. [Work with it until we get to a form where we need for our concl.] Then x + y = p/q + r/s= ps/qs + qr/qs = (ps + qr)/qs [Realize that we have what we need and state the concl. (x + y is rat.)] (ps + qr) and qs are integers since p,q,r, and s were integers. qs  0 since q  0 and p  0. [This is something we haven’t proved] So x + y is rational. 

38 Which method/technique to use? We’ve seen a number of proof techniques so far for proving an implication. Our list of techniques will grow further as we go along. So far we’ve seen direct proof, indirect proof, vacuous proof, and trivial proof. The question arises, when faced with an implication to prove, “which method should I use to prove it?” As we gain more experience with constructing proofs, you will develop an intuition about how to choose. For now, it is mostly a trial and error process. You have a number of techniques because often one technique is most suitable to proving a particular theorem. So if you get stuck, try another technique.

39 Ex: Prove that if n is an integer and n 2 is odd, then n is odd. Direct Approach: Let n be an integer such that n 2 is odd. Then (by the definition of odd), n 2 = 2k + 1 for some integer k. Now we want to know something about n (namely that n is odd). It is difficult to go from information about n 2 to information about n. It is much easier to go in the other direction. Let’s try an indirect approach. Indirect Approach: The original statement is  n  Z(n 2 is odd  n is odd). So the contrapositive is  n  Z(n is not odd  n 2 is not odd). Recalling that a number is not odd iff the number is even, we have:  n  Z(n is even  n 2 is even). Let n be an even integer. Then (by the definition of even), n = 2k for some integer k. So n 2 = (2k) 2 = 4k 2 = 2(2k 2 ). Now 2k 2 is an integer since k is and so we have expressed n 2 as 2(some integer). So by the definition of even, n 2 is even. 

40 Proof by Contradiction We have already worked with the concept of proof by contradiction on an informal basis. The essence of proof by contradiction if the this: Let’s say that we want to prove some proposition r. We may have initial assumptions that we have made and can use to prove this. An approach that we may try is to assume that r does not hold. That is, assume  r. Then if we can use our original assumptions, along with what  r tells us, to come to a logical contradiction then we know that  r can not possibly be the case. So r must be true. This is a very detailed and strict proof technique. You must be extremely careful when applying this technique that you follow the rules. Misapplication of this technique leads to all sorts of invalid reasoning.

41 Let’s consider for a moment the specific case where the statement r that you are trying to prove is an implication of the form p  q. If we apply proof by contradiction to such a statement, we want to prove r (which is p  q). So we assume  r, and then show that this assumption leads to a contradiction. Hence we will have shown that  r can’t possibly be the case, so we can conclude that r must be true. What is  r?  r =  (p  q)   (  p  q)   p   q  p   q. So to assume  r, we assume p   q (this is exactly the only case when the implication p  q is false, when p is true and q is false). Then we show that this assumption leads to a contradiction, and hence we can’t ever encounter this situation, so the implication must be true. In summary, if we wish to prove an implication p  q using the technique of proof by contradiction then we: Assume p. Assume  q. Derive a contradiction from these assumptions.

42 Ex: Give proof by contradiction that “If 3n + 2 is odd, then n is odd.” Since n is even, then n = 2k for some integer k. So 3n + 2 = 3(2k) + 2 = 6k + 2 = 2(3k + 1). So 3n + 2 = 2*m where m = (3k + 1), so 3n + 2 is even. Proof: [As always, we begin by writing our assumptions]. Let n be an integer such that 3n + 2 is odd. Now we wish to show that n is odd. So let us assume to the contrary that n is not odd. That is, we are assuming that n is even. But our original assumption was that 3n + 2 is odd. We know that an integer is either even or odd but not both, so this is a contradiction. 3n + 2 can not be both odd and even. So our assumption (to the contrary) that n was even, must have been in error. So n must be odd. 

43 Observations about the proof We assumed two things in the proof. We first assumed our hypothesis that “n is an integer such that 3n + 2 is odd”, then we further assumed that “n is not odd”. At the end (after we had reached a contradiction based on these two assumptions) we concluded that the assumption that “n is not odd” was in error. Why is it necessarily this assumption that was in error? Could it have been the assumption “n is an integer such that 3n + 2 is odd”? Of course it could have been either assumption that was in error! All we know is that by assuming both things, we come to a contradiction. So what we have shown is that both things can’t be true at once. But remember that we wanted to show “If 3n + 2 is odd, then n is odd.” So assuming that 3n + 2 is odd, we concluded that it can’t also be true that n is not odd. So if 3n + 2 is odd, then n must be odd. This is what we wanted to show.

44 So remember that with a proof by contradiction you make some assumptions. When you reach a contradiction based on these assumptions then you know that at least one of the assumptions you made can’t be. That is, not all of your assumptions can be true at the same time. So if you are trying to prove p  q, then you would first assume p. If you were going to use a direct approach, then you would proceed to use the assumption p to show that q necessarily follows. But a proof by contradiction would instead (after assuming p) now assume  q. Then you would proceed to find a contradiction from these two assumptions. So you would know that p and  q can’t both be true at the same time. Or equivalently, if p is true, then  q can’t be true. That is, if p is true then q must be true as well.

45 Indirect vs. Contradiction You should realize that if you are trying to prove an implication, p  q, then an indirect approach follows essentially the same reasoning (but a very different approach) to proving the theorem. Recall that an indirect proof would assume  q. Then you would follow reasoning to conclude  p. A proof by contradiction, on the other hand, would first assume the hypothesis p. Then you would assume, to the contrary,  q. Then you would be able to [insert indirect proof here]. That is you would use  q to, by the very same reasoning you used in the indirect approach, conclude  p. But you assumed p, and p can’t be both true and not true, so you’ve reached the desired contradiction. So you’re assumption to the contrary of  q must have been in error. So q must be the case.

46 This is a very important point. When you are proving an implication, p  q, the indirect approach and the proof by contradiction will lead you down the same line of reasoning. But the philosophical approach is very different. Proof by contradiction, hence, doesn’t really provide a usefully new approach to proving an implication. It is when you are trying to prove something other than an implication that proof by contradiction really shines. However, by proving the same statement (as we did) with both techniques, you will gain an appreciation for the similarities and the differences between the two different techniques. You will have a homework problem where you are asked to use all 3 approaches to prove the same implication. Be very careful to use the approach asked for in each part of this problem. This is the only problem you will see all semester in which using the asked for proof technique is what you are being graded on.

47 Ex: Prove that  2 is irrational. Any rational number can be expressed as a reduced fraction in lowest terms. That is, we can reduce the fraction c/d by dividing common factors out of the top and bottom until c and d have no common factors. This is a general property of rational numbers [stronger]. So  2 = a/b for some integers a and b with no common factors & b  0. Squaring both sides we get (  2) 2 = (a/b) 2. So 2 = a 2 /b 2. So 2b 2 = a 2. Proof: Let us assume, to the contrary, that  2 is rational. Since  2 is rational then  2 = c/d for some integers c and d with d  0. Now b 2 is an integer since b is. So a 2 is even. So a is even. [Recall our first proof: if n is odd, then n 2 is odd.] So 2 is a factor of a. Also since a is even, then a = 2k for some integer k. Now substituting 2k for a above, we get 2b 2 = (2k) 2. So 2b 2 = 4k 2. So b 2 = 2k 2. Hence So b 2 is even. So b is even. So 2 is a factor of b. But now 2 is a factor of both a and b which have no common factors. This is a contradiction, so  2 must be irrational, after all. 

48 Administrative Pass back HW2 –Average:88.4%(HW1 87.5%) –Median:90%(HW1 91%) –Grading Key: –Emmanuel graded 1.2: 6, 10a, and 12 (green ink) –Pascal graded the rest (red ink) HW3 is due on Monday (Emmanuel has hours 3-4) Exam 1 will be given on Friday, Feb. 21, in class –Notify me ASAP if you can’t attend to take in advance –Will cover sections

49 Refresher We have introduced a number of proof techniques that can be used to prove implications. These include direct proof, indirect proof, vacuous proof, and trivial proof. It is usually the case that any true implication could be established using any one of these proof methods, but often one technique provides the easiest, most straightforward approach. We have also discussed a powerful method called proof by contradiction. I indicated that you need to take great care when applying the proof techniques to be sure you apply them correctly. Incorrectly applying a proof technique can lead to incorrect arguments. Now we will turn to some approaches to proving more complicated statements. These approaches will often use the methods we have already introduced to help establish the desired result.

50 Proof by Cases To prove an implication of the form: (p 1  p 2  …  p n )  q we can use the tautology [(p 1  p 2  …  p n )  q]  [(p 1  q)  (p 2  q )  …  (p n  q)] Realize that we then have to prove all of the implications on the right. This is often useful when it is difficult to prove an implication, p  q, based on the hypothesis p. If we can break p up into a set of cases which cover all possibilities then we can prove the equivalent statement by proving each case.

51 Ex: Show that |x  y| = |x|  |y| for all real numbers x and y. [Recall from calculus that |x| = x when x  0 and |x| = -x when x < 0] So we wish to show  x  y[(x is real)  (y is real)  (|x  y| = |x|  |y|)]. Let us break the hypothesis up so we can apply proof by cases. All possibilities for the hypothesis, (x is real)  (y is real), can be covered by the 4 cases: (1) x  0  y  0 (2) x  0  y < 0 (3) x < 0  y  0 (4) x < 0  y < 0 So we want to prove  x  y[(x  0  y  0)  (x  0  y < 0)  (x < 0  y  0)  (x < 0  y < 0)  (|x  y| = |x|  |y|)].

52 Ex: Show that |x  y| = |x|  |y| for all real numbers x and y. Proof: Let x and y be real numbers [state the initial hypothesis]. Case 1: If x  0  y  0 then x  y  0 so |x  y| = x  y = |x|  |y|. Case 2: If x  0  y < 0 then x  y < 0 so |x  y| = -(x  y) = -(|x|  -|y|) = -(-(|x|  |y|)) = |x|  |y|. Case 3: If x < 0  y  0 then x  y < 0 so |x  y| = -(x  y) = -(-|x|  |y|) = -(-(|x|  |y|)) = |x|  |y|. Case 4: If x < 0  y < 0 then x  y  0 so |x  y| = x  y = (-|x|  -|y|) = |x|  |y|. Each case has been successfully proved, so this completes the proof by cases and the statement is proved. 

53 Proof of Equivalence To prove a biconditional p  q we can use the tautology p  q  (p  q)  (q  p) Then we must prove both of the implications on the right. But we already know how to prove implications, so we can apply those methods now. Notice that we have taken a problem we wish to solve (prove a biconditional) and reduced it into a problem that we already know how to solve. This is a very important mathematical skill.

54 Ex: Prove the theorem  n(n is odd  n 2 is odd). Proof: Let n be an integer [First state the overall hypothesis]. Now we want to show (n is odd  n 2 is odd). This entails showing both (n is odd  n 2 is odd) and (n is odd  n 2 is odd). (  ) Assume that n is odd [Assume the hypothesis]. Then by the definition of odd, n = 2k + 1 for some integer k. So n 2 = (2k + 1) 2 = 4k 2 + 4k + 1 = 2(2k 2 + 2k) + 1. So n 2 is odd. (  ) We will prove the contrapositive: (n is not odd  n 2 is not odd). That is, we will show (n is even  n 2 is even). Assume n is even. Then by the definition of even, n = 2k for some integer k. So n 2 = (2k) 2 = 4k 2 = 2(2k 2 ). So n 2 is even. Now each implication has been proved, so this completes the proof of the biconditional statement. So n is odd if and only if n 2 is odd.  Corollary:  n(n is even  n 2 is even). Just negate both sides of the biconditional that we just proved.

55 We just saw how to show that two statements are logically equivalent. That is, we saw how to show p  q. What if we wanted to show that more than two statements are logically equivalent? That is, we want to show p 1  p 2 ...  p n. Of course we could just generalize our previous technique and show all of the implications: p 1  p 2, p 2  p 1, p 1  p 3, p 3  p 1, …, p 1  p n, and p n  p 1. This would cover showing that p 1 is logically equivalent to all of the other statements. Then it would follow that the rest of the statements were logically equivalent with one another as well. However, we can be more clever here. If we show all of the equivalences p 1  p 2, p 2  p 3, p 3  p 4, …, p n-1  p n, and p n  p 1, then we can use hypothetical syllogism to get p j  p k for any i and k. We have just cut the number of implications we need to prove in half. This works because we have the chain: p 1  p 2  …  p n  p 1.

56 Ex: Show that these three statements are equivalent: (1) n is an even integer (2) n + 1 is an odd integer (3) n 2 is an even integer Proof: (1  2) Assume that n is an even integer. Then n = 2k for some integer k. So n + 1 = 2k + 1. So n + 1 is odd. (2  3) Assume that n + 1 is an odd integer. Then n + 1 = 2k + 1 for some integer k. So n = 2k. So n 2 = (2k) 2 = 4k 2 = 2(2k 2 ). So n 2 is even. (3  1) We will show the contrapositive, (  1   3). That is, we will show (n is not an even integer)  (n 2 is not an even integer). That is, (n is an odd integer)  (n 2 is an odd integer). But we have already proved this before so we are done. We have formed a chain, 1  2  3  1, so the proof is complete. 

57 Theorems and Quantifiers As we have seen, many theorems are stated as propositions with quantifiers. To prove or disprove (prove the negation) such a statement, there are various approaches. It is important that you choose a valid approach, otherwise you will not have proved the statement correctly.

58 Existence Proofs Consider an existentially quantified statement  xP(x). This statement says that there exists some element x in the universe of discourse for which the predicate P(x) holds. To prove this statement, we must show that such an element does indeed exist. If we can point out a particular x for which P(x) is satisfied, then we have given a constructive existence proof. Sometimes we can not find a particular element x for which P(x) is true, but we can otherwise show that there must exist one. For example, we could show that assuming that there does not exist an x which satisfies P(x) leads us to a contradiction. Such a method that proves existence without actually exhibiting a particular element is called a nonconstructive existence proof.

59 Ex: Show that  x  Z(x + x = x * x). Proof: Consider x = 0. Then = 0 and 0 * 0 = 0. So the statement is true. This is a constructive existence proof.  Ex: Show that  x  I  y  I(x y is rational). Proof: Consider x =  2 and y =  2. Then x y =  2  2. I don’t know whether this number is rational or irrational. I do know that  2 is irrational though because we proved it. If  2  2 is rational, then we have found what we are looking for and we are done. What if  2  2 is irrational? Then I haven’t found what I’m looking for. But then let’s consider x =  2  2 and y =  2. Then x y = (  2  2 )  2 =  2  2*  2 =  2 2 = 2. I know that 2 is rational. So now I have found what I am looking for. This is a curious sort of argument. I have given two scenarios. I’m not sure which exhibits an example I’m looking for, but I know that one or the other does. This is a nonconstructive existence proof. 

60 Uniqueness Proofs Some theorems say that there is a unique element in the universe of discourse for which P(x) is true. Such a theorem says two things: (1) There exists an element x for which P(x) is true. [We’ve just seen some types of existence proofs.] (2) No other element in the universe of discourse satisfies P. Or, equivalently, any element y for which P(y) is true satisfies y = x. [This second statement is what we usually use to establish uniqueness.]

61 Ex: Show that every integer has a unique additive inverse. That is, show  m  Z  !n  Z[m + n = 0]. Proof: Let m be an integer [state the assumption, set up for U.G.]. Then consider n = -m. Now m + -m = 0. So we have shown that there exists some n satisfying m + n = 0. Now we need uniqueness. Now suppose that there is some integer s for which m + s = 0. Then we have m + n = m + s. Subtracting m from both sides we see that n = s. So uniqueness is proved.  Note the two parts to the proof above. First we showed that for every m there exists some integer n for which m + n = 0. Then we took s to be an (arbitrary) integer which satisfied m + s = 0 (again for any m). Then we showed that it follows that s = n.

62 Counterexamples Recall that to show that a statement of the form  xP(x) is false, all we need to do is to exhibit an element s from the universe of discourse such that P(s) is false. Such an s is called a counterexample to the statement  xP(x). Note that no matter how many examples we come up with from the universe of discourse for which P(x) is true, we can not prove this statement in such a fashion (unless the universe of discourse is finite and we have exhaustively shown P(x) to be true for every x in the U.D.).

63 Ex: Show that  n  Z(n 2 > 0) is false. (Dis)Proof: Consider n = 0. Then 0 2 = 0 which is not greater than 0. So the statement is false.  Ex: Show that  x  I  y  I(x y is irrational) is false. (Dis)Proof: We showed that there is a pair of irrational numbers x and y such that x y is rational. Hence we have already found a counter example to this statement (we just aren’t sure which of the two is the counter example, but we know one exists). 

64 Mistakes in Proofs There are many common mistakes made in proofs –Begging the question (circular reasoning) –Arithmetic errors –Not taking all possibilities into account accidentally dividing by zero (or what could be zero) –Misapplication of a rule of inference Read this mini-section in the text (pp ) –Examples 31 through 35 illustrate flawed proofs –I will try to point out particularly subtle points in a proof –I’ll also make some mistakes for you to catch

65 Ex: What is wrong with this “proof” that 2 = 1? Proof: Let a and b be integers such that a = b. (1)a = b (2)a 2 = ab[multiply both sides by a] (3)a 2 - b 2 = ab - b 2 [subtract b 2 from both sides] (4)(a + b)(a - b) = b(a - b)[factor out (a - b)] (5)a + b = b[divide out (a - b)] (6)2b = b[substitute b in for a since a = b] (7)2 = 1[divide out b]  There are really two mistakes here both involving division by 0. The first mistake in step 5 is a clear mistake. We know a = b so a - b = 0. We have divided by 0. The second mistake is step 7 when we divide out b. We don’t know that b is not 0 so we can’t simply divide by it.

66 Ex: What is wrong with this “proof” that the sum of two even integers is even? The result is true, but the proof is incorrect. I wanted to show that the sum of two arbitrary even integers is even. What I have implicitly assumed by saying that both a and b equal 2k for some integer k is that a = b. So I have shown that 2*(an even integer) is even. This is not what I wanted to show. I need to be careful not to reuse a name (k) that has already been introduced. By reusing it, I am implicitly assuming that it is the same k, which for this proof it shouldn’t be. Proof: Let a and b be even integers. [State assumptions, set up U.G.] Then a = 2k for some integer k and b = 2k for some integer k. [even] So a + b = 2k + 2k = 4k = 2(2k). So a + b is even. 

67 Ex: What is wrong with this “proof” the product of an irrational number and a rational number is irrational? We weren’t careful about our definition of rational numbers. Recall that a rational number is expressible as a/b for ints a and b, with b  0. As it turns out, we have once again (perhaps) divided by zero when we multiplied both sides by (b/a). What if a were 0? We would have caught this had we verified that ad  0 before proclaiming w*r rational. Proof: Let w be an irrational number and let r be a rational number. Assume, to the contrary, that w*r is rational. [We use proof by contr.] Since r is rational, then r = a/b for some integers a and b. Since w*r is rational, then w*r = c/d for some integers c and d. So w*(a/b) = c/d. So w = bc/ad. Now bc and ad are integers since a,b,c, and d were and the integers are closed under multiplication. So w is rational. But this is a contradiction since w is irrational. So our assumption that w*r is rational was in error. So w*r is irrat. 

68 Ex: Here is the correct proof the product of an irrational number and a nonzero rational number is irrational? Proof: Let w be an irrational number and let r be a nonzero rational number. Assume, to the contrary, that w*r is rational. [We use proof by contr.] Since r is a nonzero rational, then r = a/b for some a,b  Z with b  0 and a  0. Since w*r is rational, then w*r = c/d for some c,d  Z with d  0. So w*(a/b) = c/d. So w = bc/ad. Now bc and ad are integers since a,b,c, and d were and ad  0 since a  0 & d  0. So w is rational. But this is a contradiction since w is irrational. So our assumption that w*r is rational was in error. So w*r is irrational, after all. 

69 Problems from 1.5 for HW #4 HW #4 hasn’t been assigned yet but it will include problems from sections 1.5, 1.6, and 1.7 Section 1.5: 27, 29, 30, 34, 38, 43, 51, 64, 71


Download ppt "Section 1.5: Methods of Proof Now that we have covered propositional and predicate logic, we will introduce some formal rules of reasoning for constructing."

Similar presentations


Ads by Google