PROBLEM SET 3: PROOF TECHNIQUES

Similar documents
CS Module 1. Ben Harsha Apr 12, 2017

CS 340: Discrete Structures for Engineers

MATH CSE20 Homework 5 Due Monday November 4

Mat 243 Exam 1 Review

Proof by Contradiction

MATH 135 Fall 2006 Proofs, Part IV

Proofs. Chapter 2 P P Q Q

Carmen s Core Concepts (Math 135)

Homework 3: Solutions

Midterm Exam Solution

Lecture Notes 1 Basic Concepts of Mathematics MATH 352

MATH 2200 Final LC Review

ANALYSIS EXERCISE 1 SOLUTIONS

First order Logic ( Predicate Logic) and Methods of Proof

Math 10850, fall 2017, University of Notre Dame

9/5/17. Fermat s last theorem. CS 220: Discrete Structures and their Applications. Proofs sections in zybooks. Proofs.

MAS114: Solutions to Exercises

Some Review Problems for Exam 1: Solutions

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication

Proofs. Joe Patten August 10, 2018

MATH 271 Summer 2016 Practice problem solutions Week 1

Strategies for Proofs

For all For every For each For any There exists at least one There exists There is Some

3 The language of proof

means is a subset of. So we say A B for sets A and B if x A we have x B holds. BY CONTRAST, a S means that a is a member of S.

Solutions to Homework I (1.1)

Computer Science Section 1.6

COT 2104 Homework Assignment 1 (Answers)

Writing Mathematical Proofs

Integer-Valued Polynomials

1. Prove that the number cannot be represented as a 2 +3b 2 for any integers a and b. (Hint: Consider the remainder mod 3).

Logic, Sets, and Proofs

Tools for reasoning: Logic. Ch. 1: Introduction to Propositional Logic Truth values, truth tables Boolean logic: Implications:

«Infuse mathematical thinking in a lesson on Pythagoras Theorem»

Writing proofs for MATH 61CM, 61DM Week 1: basic logic, proof by contradiction, proof by induction

Mathematical Logic Part One

Steinhardt School of Culture, Education, and Human Development Department of Teaching and Learning. Mathematical Proof and Proving (MPP)

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example

MATH 2200 Final Review

Ch 3.2: Direct proofs

and problem sheet 1

Foundations of Mathematics MATH 220 FALL 2017 Lecture Notes

Proofs: A General How To II. Rules of Inference. Rules of Inference Modus Ponens. Rules of Inference Addition. Rules of Inference Conjunction

Discrete Mathematics and Probability Theory Summer 2014 James Cook Note 5

Introducing Proof 1. hsn.uk.net. Contents

STRATEGIES OF PROBLEM SOLVING

Packet #1: Logic & Proofs. Applied Discrete Mathematics

2/2/2018. CS 103 Discrete Structures. Chapter 1. Propositional Logic. Chapter 1.1. Propositional Logic

EECS 1028 M: Discrete Mathematics for Engineers

Discrete Structures & Algorithms. Propositional Logic EECE 320 // UBC

What is a proof? Proofing as a social process, a communication art.

Predicate Logic & Quantification

Logical Operators. Conjunction Disjunction Negation Exclusive Or Implication Biconditional

Deduction by Daniel Bonevac. Chapter 3 Truth Trees

Chapter III. Basic Proof Techniques. Proving the obvious has never been easy. Marty Rubin

Discrete Mathematics & Mathematical Reasoning Predicates, Quantifiers and Proof Techniques

Inference and Proofs (1.6 & 1.7)

Introduction to Basic Proof Techniques Mathew A. Johnson

Discrete Mathematics and Probability Theory Spring 2016 Rao and Walrand Note 1

Proofs. Chapter 2 P P Q Q

Proof Terminology. Technique #1: Direct Proof. Learning objectives. Proof Techniques (Rosen, Sections ) Direct Proof:

MAT2345 Discrete Math

CHMC: Finite Fields 9/23/17

Seminaar Abstrakte Wiskunde Seminar in Abstract Mathematics Lecture notes in progress (27 March 2010)

MATH10040: Numbers and Functions Homework 1: Solutions

Proof Worksheet 2, Math 187 Fall 2017 (with solutions)

Lecture Notes on DISCRETE MATHEMATICS. Eusebius Doedel

Sec$on Summary. Mathematical Proofs Forms of Theorems Trivial & Vacuous Proofs Direct Proofs Indirect Proofs

Propositional and Predicate Logic

Announcement. Homework 1

Guide to Proofs on Discrete Structures

Basic Logic and Proof Techniques

Preparing for the CS 173 (A) Fall 2018 Midterm 1

MATH 341, Section 001 FALL 2014 Introduction to the Language and Practice of Mathematics

Proof by contrapositive, contradiction

Practice Test III, Math 314, Spring 2016

Example ( x.(p(x) Q(x))) ( x.p(x) x.q(x)) premise. 2. ( x.(p(x) Q(x))) -elim, 1 3. ( x.p(x) x.q(x)) -elim, x. P(x) x.

Section 1.2: Propositional Logic

WUCT121. Discrete Mathematics. Logic. Tutorial Exercises

The following techniques for methods of proofs are discussed in our text: - Vacuous proof - Trivial proof

Math 13, Spring 2013, Lecture B: Midterm

Big-oh stuff. You should know this definition by heart and be able to give it,

Chapter 2. Mathematical Reasoning. 2.1 Mathematical Models

Compound Propositions

Lines, parabolas, distances and inequalities an enrichment class

Lecture 2. Logic Compound Statements Conditional Statements Valid & Invalid Arguments Digital Logic Circuits. Reading (Epp s textbook)

CSC Discrete Math I, Spring Propositional Logic

Chapter 1: The Logic of Compound Statements. January 7, 2008

Math Lecture 18 Notes

Proofs. 29th January 2014

MATH10040: Chapter 0 Mathematics, Logic and Reasoning

Propositional Logic: Semantics

Theorem. For every positive integer n, the sum of the positive integers from 1 to n is n(n+1)

Boolean Algebra and Proof. Notes. Proving Propositions. Propositional Equivalences. Notes. Notes. Notes. Notes. March 5, 2012

MAS114: Exercises. October 26, 2018

1.1 Language and Logic

Math /Foundations of Algebra/Fall 2017 Foundations of the Foundations: Proofs

Cool Results on Primes

Mathematical Reasoning & Proofs

Propositional and Predicate Logic

Transcription:

PROBLEM SET 3: PROOF TECHNIQUES CS 198-087: INTRODUCTION TO MATHEMATICAL THINKING UC BERKELEY EECS FALL 2018 This homework is due on Monday, September 24th, at 6:30PM, on Gradescope. As usual, this homework is graded on participation, but it is in your best interest to put full effort into it. This is a good opportunity to learn how to use LaTeX. 1. Prove that if x 2 6x + 5 is odd, then x is even, using: a. Proof by Contraposition b. Direct Proof Solution: a. The contrapositive of this statement is, if x is odd, then x 2 6x + 5 is even. If x is odd, we can write x = 2k + 1 for k Z. Then: x 2 6x + 5 = (2k + 1) 2 6(2k + 1) + 5 = 4k 2 + 4k + 1 12k 6 + 5 = 2(2k 2 4k) We ve shown that when x is odd, x 2 6x + 5 can be written as 2 (some integer), therefore by contraposition, the original statement holds. b. There are several ways to do this directly. We can factor x 2 6x + 5 into (x 1)(x 5). If this product is odd, then each of x 1 and x 5 has to be odd (the only way for a product of two integers to be odd is if both integers are odd). But if x 1 is odd, then x has to be even (same with x 5), as adding one to any odd integer makes it even. We can break this into two cases: when x is even and when x is odd. For each, we can evaluate x 2 6x + 5; this will show that when x is even, x 2 6x + 5 is odd, and when x is odd, x 2 6x + 5 is even. This also proves the original statement. 2. Prove that if P = Q and R = Q, then P = R, using: 1

a. Proof by Contradiction b. Proof by Contraposition (Hint: You may need to use the fact that A = B A B.) Solution: It may help to think of the statement P = Q and R = Q as A, and P = R as B. a. The negation of the statement A = B is A B (this was seen in lecture, but you should prove it to yourself). So, the negation of our statement is that P = Q and R = Q, but (P = R). We can rewrite (P = R) as ( P R) P R. In other words, we are now assuming that all of the following are true: P = Q R = Q P R From the statement P R, we know that P and R both must be true. If P is true, then Q must be true in order for P = Q to be true. However, this means the statement R = Q is false, as a true value (R) does not imply a false value ( Q). This is a contradiction. This means that the negation of our original statement cannot be true, and therefore our original statement was true. b. The contraposition of our original statement is (P = R) = ((P = Q) (R = Q)) (P R) = (( P Q) ( R Q)) (P R) = ((P Q) (R Q)) We now need to show that this implication has a true value. This implication is true when: P R is true and ((P Q) (R Q)) is true P R is false There isn t a whole lot to prove when P R is false (as false = true and false = false are both true). Suppose P R is true, meaning P and R are both true. We have to consider both cases of Q: Q could either be true or false. P R Q (P Q) (R Q) T T T T T T F T 2

You should verify the above two cases yourself. In short, when Q is true, P Q is false and R Q is true. When Q is false, P Q is true and R Q is false. Since these two conditions are joined by a disjunction, only one needs to be true for the entire expression to be true. Therefore, by contraposition, the original statement holds true. Which of these methods do you think was more straightforward? 3. In the previous problem set, we had you prove De Morgan s Laws for conjunctions and disjunctions. (P Q) ( P ) ( Q) (P Q) ( P ) ( Q) a. (Optional) Using truth tables, prove both of the statements above. b. In terms of the symbols,,, re-write the negation of P = Q. (Hint: We did this in lecture, but try and derive it on your own.) c. Now, let s consider the statement if a b is even, then a is even or b is even. First, rewrite this statement using mathematical notation. (Hint: you will need the implication symbol.) d. Find the contrapositive of the statement in (c), and write it using mathematical notation. e. Prove the statement in (c) by contraposition. f. Prove the statement in (c) using a direct proof. (Hint: You may need to consider multiple cases.) g. Why do you think we included this problem? Solution: a. Done in lecture. b. (P = Q) P Q c. ( k N : a b = 2k) = ( k 1 N : a = 2k 1 ) ( k 2 N : a = 2k 2 ) Note: We could ve used k instead of k 1 and k 2, as in this case, the ks are local to the parenthesis. d. ( k 1 N : a 2k 1 ) ( k 2 N : a 2k 2 ) = ( k N : a b 2k) e. Suppose a = 2k + 1 and b = 2l + 1 (meaning they re both odd). Then, a b = (2k +1)(2l +1) = 4kl +2(k +l)+1 = 2(2kl +k +l)+1. Since we wrote a b as an even number plus one, we know the product has to be odd. Therefore, by contraposition, the original statement holds. f. a and b can each be either even, or odd. Let s look at all four possibilities: a even, b even: a b is even 3

a even, b odd: a b is even a odd, b even: a b is even a odd, b odd: a b is odd In all cases where a b is even, at least one of a or b is even, proving the statement. g. For two reasons: (1) to illustrate that the negation of a for all is a there exists (and vice versa) and the fact that the negation of a conjunction is a disjunction (and vice versa), and (2) to show that there are usually multiple ways to prove any statement. 4. In this problem, we ll look at how to prove statements of the form P if and only if Q. Recall, the statement P Q is equivalent to (P = Q) (Q = P ). To show that P is true if and only if Q is true, we need to prove both directions of the implication, i.e. that P implies Q and that Q implies P. We can use any proof technique we like for each of the two sub-proofs. For example: Suppose we want to prove that A B = A + B if and only if A and B are disjoint. We need to prove two directions: if A B = A + B, then A and B are disjoint (1), and if A and B are disjoint, then A B = A + B (2). a. Complete the proof above. b. We say (a, b, c) is a Pythagorean triplet if a 2 + b 2 = c 2. Prove that (a, b, c) can only be Pythagorean triplet if and only if at least one of a, b, c are even. (This question originally had a significant typo, which made this proof impossible, but that has now been fixed.) Solution: a. First, let s prove the statement if A B = A + B, then A, B are disjoint. We know that normally, A B = A + B A B. By what we are allowed to assume, we have that A + B A B = A + B, implying that A B = 0. However, this is only true when A, B are disjoint. Now, let s prove the statement if A, B are disjoint, then A B = A + B. If A, B are disjoint, we know that A B = 0. Then, A B = A + B A B = A + B, as required. Since both directions hold, we have that the entire statement holds. QED. b. First, let s prove the statement (a, b, c) can only be a Pythagorean triplet if at least one of a, b, c are even. Let s do this by contradiction, that is, let s assume that there exists a triplet of odd integers a, b, c such that a 2 + b 2 = c 2 (the negation of at least one of a, b, c is even is all a, b, c, are odd ). Then, we can say a = 2k + 1, b = 2l + 1 and c = 2m + 1. 4

c 2 = a 2 + b 2 (2m + 1) 2 = (2k + 1) 2 + (2l + 1) 2 2(2m 2 + 2m) + 1 = 4k 2 + 4k + 1 + 4l 2 + 4l + 1 2(2m 2 + 2m) + 1 = 2(2k 2 + 2k + 2l 2 + 2l + 1) Here, we have a contradiction, as on the left side we have an odd number and on the right side we have an even number. Therefore, by contradiction, we ve shown that (a, b, c) can only be a Pythagorean triplet if at least one of a, b, c are even. Now, let s prove the statement if at least one of a, b, c are even, then a, b, c can be a Pythagorean triplet. Since we re simply being asked to show the existence of such a triplet ( can be a Pythagorean triplet ), we can just give one example, i.e. (3, 4, 5). We ve shown both directions of our if and only proof, therefore the entire statement holds. 5. When we are presented with the task of proving the uniqueness of two elements (where elements could be numbers, sets, vectors, etc.) we usually use a proof by contradiction. We assume that there exist two different instances of such an element, and show that they must be the same. For example, suppose we want to prove that additive inverses are unique. (The inverse of some real number x for the operation of addition is x, as x + ( x) = 0.) We could start by assuming that there exist two inverses, a and b, such that a b. This means that x + a = 0 and x + b = 0. Then: a = a = a + (x + b) = (a + x) + b = 0 + b = b We started by assuming a b, but showed that a = b, disproving the notion that additive inverses are unique. Sometimes, the notation! is used to mean there exists a unique / there exists exactly one. For example,! x R x 2 4x + 4 = 0 translates to there exists a unique real solution to x 2 4x + 4 = 0. a. Prove, using a technique similar to that above, that there only exists a single positive integer solution to a 2 + 4 2 = 5 2. b. Prove that ( x R, x 0)(! y R)(x y = 1). 5

Solution: a. Suppose there are two positive integer solutions x, y, such that x y. They must both satisfy a 2 = 5 2 4 2 = 9. Suppose x 2 = y 2. Then, either x = y or x = y. The latter case cannot be true, as it implies either x or y is negative. That means x = y, which contradicts what we assumed in the beginning. Therefore, there is only one such a. b. Suppose there exist two such values of y, y 1 and y 2, such that y 1 y 2, and that x, y 1, y 2 0. Then: x y 1 = 1 = y 1 = 1 x x y 2 = 1 = y 2 = 1 x = y 1 = y 2 which again contradicts what we assumed in the beginning. Therefore, multiplicative inverses are unique. 6. Over the summer, Billy spent all day thinking about math (same!) and trying to come up with the next big proof. After a few months, he presents this proof to you to proofread. Verify that his proof is correct, or explain the error. Theorem: If n is an integer and 2n + 2 is even, then n is odd. Proof: Proceed by contraposition. Assume that n is odd. We will now prove that 2n + 2 is even. Clearly, 2n must be an even number, since it is divisible by 2. Furthermore, 2 is an even number, so 2n + 2 must be even. This concludes the proof. Solution: This is a statement that is false. For example, when n = 4, 2n + 2 = 10 which is even, but n is still an even number. Bob attempted to prove this statement by contraposition, but instead of taking the contrapositive, he took the converse. In general, an implication P Q is not logically equivalent with its contrapositive, Q P. 7. The following problems involve parity arguments that is, reasoning about whether some combinations of integers are even or odd. a. Prove that if a, b and c are odd integers, then there are no integer solutions to ax 2 +bx+c = 0. (Hint 1: You should consider two different cases for x. Hint 2: Negative integers can still be even or odd. Hint 3: Is it possible for the sum of a few integers to be a non-integer?) b. Prove that there are no integer solutions to a 2 4b = 2. Solution: 6

a. We will actually prove a stronger statement: that if a, b, c are odd integers, then there are no rational solutions to ax 2 + bx + c = 0. Since all integers are rational numbers, if we prove this statement for all rationals, we ve proven it for all integers as well. Let s proceed by contradiction, by assuming that there are rational solutions to p(x) = ax 2 + bx + c = 0 with all a, b, c odd. This would mean we can factor p(x) into p(x) = (Ax+B)(Cx+D). Expanding this out yields p(x) = ACx+(AD+BC)x+BD, where a = AC, b = AD + BC and c = BD. Since a and c are both odd, we have that A, C, B and D must all also be odd. If that s the case, though, then that would mean b = AC + BD is even, as it is the sum of two odd numbers. This contradicts our initial assumption that all a, b, c are odd, and therefore the original statement holds by proof by contradiction. b. We will proceed by contradiction. Let s assume there are integral solutions for a, b. We can rearrange to have a 2 = 2 + 4b = 2(1 + 2b). This means that a 2 is even, and thus a is even, meaning we can say a = 2k. Then, (2k) 2 = 2(1 + 2b) 4k 2 = 2(1 + 2b) 2k 2 = 1 + 2b Here, we have a contradiction, as 2k 2 is even, but 1 + 2b must be odd. Therefore, there cannot be any integer solutions for a, b. 8. Prove that... 2 2 2 2 = 2. (This is a challenging problem. Try not to search for it online. Hint: Define some variable x recursively.) Solution: Let x = 2 x. Then: ln x = x ln 2 1 2 1 x ln x = 1 2 ln 2 It now becomes clear that x = 2 satisfies the above relationship. However, it isn t necessarily the only solution. Suppose that g(x) = ln x x. By differentiating g(x) it becomes clear that g(x) has a local maximum at x = e and begins decreasing after, implying that there are two solutions potential values of x that could satisfy this equation. It turns out that x = 4 is also a solution to g(x). 7

How do we know that x = 4 is not the correct answer? Suppose we consider some recursive sequence defined by a 0 = 2, a n = 2 a n 1, it can be shown by induction that a n 2. Do this as an exercise! 8