CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.

Slides:



Advertisements
Similar presentations
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
Advertisements

Introduction to Proofs
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
PROOF BY CONTRADICTION
Chapter 3 Elementary Number Theory and Methods of Proof.
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
Prof. Shachar Lovett Clicker frequency: CA CSE 20 Discrete math Prof. Shachar Lovett
Proofs, Recursion and Analysis of Algorithms Mathematical Structures for Computer Science Chapter 2 Copyright © 2006 W.H. Freeman & Co.MSCS SlidesProofs,
OXYMORON “What in the Sam Hill is that?”. OXYMORON DEFINITION QUIZ IS IT: A.) OXYMORON: the guy who invented that stuff that takes stains out of clothes.
“What in the Sam Hill is that?”
 The Yin-Yang is an ancient Chinese symbol that represents the duality of nature and attempt to explain how everything works. The outer circle represents.
Copyright © Cengage Learning. All rights reserved.
Logic and Proof. Argument An argument is a sequence of statements. All statements but the first one are called assumptions or hypothesis. The final statement.
Logic: Connectives AND OR NOT P Q (P ^ Q) T F P Q (P v Q) T F P ~P T F
Copyright © Zeph Grunschlag,
Introduction to Proofs ch. 1.6, pg. 87,93 Muhammad Arief download dari
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
Methods of Proof Lecture 4: Sep 16 (chapter 3 of the book)
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
Methods of Proof & Proof Strategies
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Methods of Proof. This Lecture Now we have learnt the basics in logic. We are going to apply the logical rules in proving mathematical theorems. Direct.
Conditional Statements CS 2312, Discrete Structures II Poorvi L. Vora, GW.
Chapter 3 Elementary Number Theory and Methods of Proof.
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
CS 173, Lecture B August 27, 2015 Tandy Warnow. Proofs You want to prove that some statement A is true. You can try to prove it directly, or you can prove.
Proofs1 Elementary Discrete Mathematics Jim Skon.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
10/17/2015 Prepared by Dr.Saad Alabbad1 CS100 : Discrete Structures Proof Techniques(1) Dr.Saad Alabbad Department of Computer Science
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
 Definition- Oxymoron, plural oxymora, is a figure of speech in which two opposite ideas are joined to create an effect. The common oxymoron phrase is.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Methods of Proof Lecture 3: Sep 9. This Lecture Now we have learnt the basics in logic. We are going to apply the logical rules in proving mathematical.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CSE 20 – Discrete Mathematics Dr. Cynthia Bailey Lee Dr. Shachar Lovett Peer Instruction in Discrete Mathematics by Cynthia Leeis licensed under a Creative.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Fall 2008/2009 I. Arwa Linjawi & I. Asma’a Ashenkity 11 The Foundations: Logic and Proofs Introduction to Proofs.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Week 4 - Monday.  What did we talk about last time?  Divisibility  Quotient-remainder theorem  Proof by cases.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CS104:Discrete Structures Chapter 2: Proof Techniques.
Week 4 - Friday.  What did we talk about last time?  Floor and ceiling  Proof by contradiction.
Week 4 - Wednesday.  What did we talk about last time?  Divisibility  Proof by cases.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Section 1.7. Definitions A theorem is a statement that can be shown to be true using: definitions other theorems axioms (statements which are given as.
5-5 Indirect Proof. Indirect Reasoning: all possibilities are considered and then all but one are proved false. The remaining possibility must be true.
Methods of Proof Lecture 4: Sep 20 (chapter 3 of the book, except 3.5 and 3.8)
CS 173, Lecture B August 27, 2015 Tandy Warnow. Proofs You want to prove that some statement A is true. You can try to prove it directly, or you can prove.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
Direct Proof by Contraposition Direct Proof by Contradiction
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
Chapter 1: The Foundations: Logic and Proofs
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
An indirect proof uses a temporary assumption that
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
PROOF BY CONTRADICTION
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
CS 220: Discrete Structures and their Applications
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
Foundations of Discrete Mathematics
Proof: [We take the negation and suppose it to be true.]
Presentation transcript:

CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett

Today’s Topics: 1. A second look at contradictions 2. Proof by contradiction template 3. Practice negating theorems 2

1. A second look at contradictions Q: Do you like MATH15A? A: Yes and no... 3

P AND  P = Contradiction  It is not possible for both P and NOT P to be true  This simply should not happen!  This is logic, not Shakespeare Here’s much to do with hate, but more with love. Why, then, O brawling love! O loving hate! O anything, of nothing first create! O heavy lightness! Serious vanity! Mis-shapen chaos of well-seeming forms! Feather of lead, bright smoke, cold fire, Sick health! Still-waking sleep, that is not what it is! This love feel I, that feel no love in this. [Romeo and Juliet] 4

Contradictions destroy the entire system that contains them  Draw the truth table: 5 pq (p ∧ ¬p)(p ∧ ¬p)  q A. 0,0,0,0 B. 1,1,1,1 C. 0,1,0,1 D. 0,0,1,1 E. None/more/other

Contradictions destroy the entire system that contains them  Draw the truth table:  Here’s the scary part: it doesn’t matter what q is!  q=“All irrational numbers are integers.”  q=“The Beatles were a terrible band.”  q=“Dividing by zero is totally fine!”  All these can be “proved” true in a system that contains a contradiction! 6 pq (p ∧ ¬p)(p ∧ ¬p)  q

Proof by contradiction template  Thm. [write theorem]  Proof (by contradiction): Assume not. That is, suppose that [  theorem] (Don’t just write  (theorem). For example,  changes to , use DeMorgan’s law if needed, etc.) [write something that leads to a contradiction: “… [p] … so [  p]. But [p], a contradiction”] Conclusion: So the assumed assumption is false and the theorem is true. QED. 7

Example 1  Thm. There is no integer that is both even and odd.  Proof (by contradiction)  Assume not. That is, suppose A. All integers are both odd and even B. All integers are not even or not odd. C. There is an integer n that is both odd and even. D. There is an integer n that is neither even nor odd. E. Other/none/more than one 8

Be careful about doing negations  Theorem: “there is no integer that is both even and odd”    n  Z (n  E  n  O)   n  Z  (n  E  n  O)  Negation:  n  Z (n  E  n  O)  “There is an integer n that is both even and odd” 9

Example 1  Thm. There is no integer that is both even and odd.  Proof (by contradiction) Assume not. That is, suppose there exists an integer n that is both even and odd. 10 Try by yourself first

Example 1  Thm. There is no integer that is both even and odd.  Proof (by contradiction) Assume not. That is, suppose there exists an integer n that is both even and odd.  Conclusion: The assumed assumption is false and the theorem is true. QED. 11 Since n is even n=2a for an integer a. Since n is odd n=2b+1 for an integer b. So 2a=2b+1. Subtracting, 2(a-b)=1. So a-b=1/2 but this is impossible for integers a,b. A contradiction.

Example 2  A number x is rational if x=a/b for integers a,b.  E.g. 3=3/1, 1/2, -3/4, 0=0/1  A number is irrational if it is not rational  E.g (proved in textbook)  Theorem: If x 2 is irrational then x is irrational. 12

Example 2  Theorem: If x 2 is irrational then x is irrational.  Proof: by contradiction. Assume that A. There exists x where both x,x 2 are rational B. There exists x where both x,x 2 are irrational C. There exists x where x is rational and x 2 irrational D. There exists x where x is irrational and x 2 rational E. None/other/more than one 13

Example 2  Theorem: If x 2 is irrational then x is irrational.  Proof: by contradiction. Assume that there exists x where x is rational and x 2 irrational. 14 Try by yourself first

Example 2  Theorem: If x 2 is irrational then x is irrational.  Proof: by contradiction. Assume that there exists x where x is rational and x 2 irrational. 15 Since x is rational x=a/b where a,b are integers. But then x 2 =a 2 /b 2. Both a 2,b 2 are also integers and hence x 2 is rational. A contracition.

Example 3  Theorem: is irrational  Proof (by contradiction). THIS ONE IS MORE TRICKY. TRY BY YOURSELF FIRST IN GROUPS. 16

Example 3  Theorem: is irrational  Proof (by contradiction).  Assume not. Then there exist integers a,b such that  Squaring gives So also is rational since [So, to finish the proof it is sufficient to show that is irrational. ] 17

Example 3  Theorem: is irrational  Proof (by contradiction).  is rational … is rational.  =c/d for positive integers c,d. Assume that d is minimal such that c/d= Squaring gives c 2 /d 2 =6. So c 2 =6d 2 must be divisible by 2. Which means c is divisible by 2. Which means c 2 is divisible by 4. But 6 is not divisible by 4, so d 2 must be divisible by 2. Which means d is divisible by 2. So both c,d are divisible by 2. Which means that (c/2) and (d/2) are both integers, and (c/2) / (d/2) = Contradiction to the minimality of d. 18