Discussion #12 1/22 Discussion #12 Deduction, Proofs and Proof Techniques.

Slides:



Advertisements
Similar presentations
Propositional Equivalences
Advertisements

Introduction to Proofs
Review for CS1050. Review Questions Without using truth tables, prove that  (p  q)   q is a tautology. Prove that the sum of an even integer and an.
Introduction to Theorem Proving
1 Introduction to Abstract Mathematics Valid AND Invalid Arguments 2.3 Instructor: Hayk Melikya
Propositional Equivalences. L32 Agenda Tautologies Logical Equivalences.
Logic Concepts Lecture Module 11.
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sixth Edition, Mc Graw-Hill, 2007 Chapter 1: (Part 2): The Foundations: Logic and Proofs.
CS128 – Discrete Mathematics for Computer Science
Discussion #131/18 Discussion #13 Induction (the process of deriving generalities from particulars) Mathematical Induction (deductive reasoning over the.
Syllabus Every Week: 2 Hourly Exams +Final - as noted on Syllabus
1 CA 208 Logic PQ PQPQPQPQPQPQPQPQ
Logic: Connectives AND OR NOT P Q (P ^ Q) T F P Q (P v Q) T F P ~P T F
1 Section 1.2 Propositional Equivalences. 2 Equivalent Propositions Have the same truth table Can be used interchangeably For example, exclusive or and.
Proof by Deduction. Deductions and Formal Proofs A deduction is a sequence of logic statements, each of which is known or assumed to be true A formal.
Introduction to Logic Logical Form: general rules
Discussion #10 1/16 Discussion #10 Logical Equivalences.
Discussion #9 1/9 Discussion #9 Tautologies and Contradictions.
Mathematical Induction Assume that we are given an infinite supply of stamps of two different denominations, 3 cents and and 5 cents. Prove using mathematical.
Logic Truth Tables, Propositions, Implications. Statements Logic is the tool for reasoning about the truth or falsity of statements. –Propositional logic.
Methods of Proof & Proof Strategies
Inductive Proof (the process of deriving generalities from particulars) Mathematical Induction (reasoning over the natural numbers)
Introduction to Proofs
MATH 224 – Discrete Mathematics
CSE 311: Foundations of Computing Fall 2013 Lecture 8: More Proofs.
Conditional Statements CS 2312, Discrete Structures II Poorvi L. Vora, GW.
Review I Rosen , 3.1 Know your definitions!
Proofs1 Elementary Discrete Mathematics Jim Skon.
CSci 2011 Discrete Mathematics Lecture 6
10/17/2015 Prepared by Dr.Saad Alabbad1 CS100 : Discrete Structures Proof Techniques(1) Dr.Saad Alabbad Department of Computer Science
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.
COS 150 Discrete Structures Assoc. Prof. Svetla Boytcheva Fall semester 2014.
Advanced Topics in Propositional Logic Chapter 17 Language, Proof and Logic.
Propositional Calculus – Methods of Proof Predicate Calculus Math Foundations of Computer Science.
Natural Deduction CS 270 Math Foundations of CS Jeremy Johnson.
1 CMSC 250 Discrete Structures CMSC 250 Lecture 1.
CS201: Data Structures and Discrete Mathematics I
Chapter 3: Introduction to Logic. Logic Main goal: use logic to analyze arguments (claims) to see if they are valid or invalid. This is useful for math.
Propositional Logic. Propositions Any statement that is either True (T) or False (F) is a proposition Propositional variables: a variable that can assume.
1 Introduction to Abstract Mathematics Expressions (Propositional formulas or forms) Instructor: Hayk Melikya
1 Discrete Structures – CNS2300 Text Discrete Mathematics and Its Applications Kenneth H. Rosen (5 th Edition) Chapter 3 The Foundations: Logic and Proof,
Chapter 2 Logic 2.1 Statements 2.2 The Negation of a Statement 2.3 The Disjunction and Conjunction of Statements 2.4 The Implication 2.5 More on Implications.
The Foundations: Logic and Proof, Sets, and Foundations PROPOSITIONS A proposition is a declarative sentence that is either True or False, but not the.
Method of proofs.  Consider the statements: “Humans have two eyes”  It implies the “universal quantification”  If a is a Human then a has two eyes.
CSci 2011 Discrete Mathematics Lecture 4 CSci 2011.
CS104:Discrete Structures Chapter 2: Proof Techniques.
CSE 311: Foundations of Computing Fall 2013 Lecture 8: Proofs and Set theory.
Methods of Proof – Page 1CSCI 1900 – Discrete Structures CSCI 1900 Discrete Structures Methods of Proof Reading: Kolman, Section 2.3.
Week 4 - Friday.  What did we talk about last time?  Floor and ceiling  Proof by contradiction.
Outline Logic Propositional Logic Well formed formula Truth table
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.
CSE 311 Foundations of Computing I Lecture 8 Proofs Autumn 2012 CSE
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
Proof Review CS 202 Aaron Bloomfield Spring 2007.
Lecture 10 Methods of Proof CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
Foundations of Discrete Mathematics Chapter 1 By Dr. Dalia M. Gil, Ph.D.
Logic and Truth Tables Winter 2012 COMP 1380 Discrete Structures I Computing Science Thompson Rivers University.
Law of logic Lecture 4.
Sound Arguments and Derivations. Topics Sound Arguments Derivations Proofs –Inference rules –Deduction.
Chapter 1 Logic and proofs
Chapter 1 Logic and Proof.
Chapter 1 Logic and Proof.
2. The Logic of Compound Statements Summary
(CSC 102) Discrete Structures Lecture 2.
Methods of Proof A mathematical theorem is usually of the form pq
Information Technology Department
CS201: Data Structures and Discrete Mathematics I
CSE 311: Foundations of Computing
Section 2.1 Proof Techniques Introduce proof techniques:   o        Exhaustive Proof: to prove all possible cases, Only if it is about a.
CS201: Data Structures and Discrete Mathematics I
Presentation transcript:

Discussion #12 1/22 Discussion #12 Deduction, Proofs and Proof Techniques

Discussion #12 2/22 Topics Proofs = Sound Arguments, Derivations, Deduction Proof Techniques 1.Exhaustive 2.Equivalence to Truth 3.If and only if (iff) 4.Contrapositive Proof 5.Contradiction (or Indirect) 6.Conditional 7.Case Analysis 8.Induction 9.Direct

Discussion #12 3/22 1. Exhaustive Truth Proof Show true for all cases. –e.g.Prove x < 20 for integers 0  x  = 5< 20T = 6< 20T = 9< 20T = 14< 20T –Thus, all cases are exhausted and true. –Same as using truth tables  when all combinations yield a tautology.

Discussion #12 4/22 2. Equivalence to Truth 2a.Transform logical expression to T. Prove: R  S   (  R   S) R  S   (  R   S)  R  S   R   S de Morgan’s law  R  S  R  S double negation   (R  S)  (R  S) implication (P  Q   P  Q)  T law of excl. middle (P   P)  T

Discussion #12 5/22 2. Equivalence to Truth (continued…) 2b.Or, transform lhs to rhs or vice versa. Prove: P  Q   P  Q  Q P  Q   P  Q  (P   P)  Q distributive law (factoring)  T  Q law of excluded middle  Q identity

Discussion #12 6/22 3. If and only if Proof Also called necessary and sufficient If we have P  Q, then we can create two standard deductive proofs, namely, (P  Q) and (Q  P). i.e. P  Q  (P  Q)  (Q  P) Transforms proof to a standard deductive proof  actually two of them

Discussion #12 7/22 3. If and only if Proof: Example Prove: 2x – 4 > 0 iff x > 2. Thus, we can do two proofs: (1) If 2x – 4 > 0 then x > 2. (2) If x > 2 then 2x – 4 > 0. Proof: (1) Suppose 2x – 4 > 0. Then 2x > 4 and thus x > 2. (2) Suppose x > 2. Then 2x > 4 and thus 2x – 4 > 0. Note that we could have also simply converted the lhs to the rhs. Proof: 2x – 4 > 0  2x > 4  x > x – 4 > 0premise 2. 2x > 4algebraic equiv. 3. x > 2algebraic equiv.

Discussion #12 8/22 4. Contrapositive Proof Remember: T T F F T T F T T F T F T T T T T T F T FF TF FT TT  P)  (Q(Q  (P  Q) QP

Discussion #12 9/22 4. Contrapositive Proof (continued…) Prove: if s is not a multiple of 3, then s is not a solution of x 2 + 3x – 18 = 0. P = s is a multiple of 3 Q = s is a solution of x 2 + 3x – 18 = 0. Instead of proving  P   Q, we can prove Q  P (because of the contrapositive equivalence) Thus, we prove: if s is a solution of x 2 + 3x – 18 = 0, then s is a multiple of 3.

Discussion #12 10/22 4. Contrapositive Proof: Example Prove: if s is a solution of x 2 + 3x – 18 = 0, then s is a multiple of 3. Proof: The solutions of x 2 + 3x – 18 = 0 are 3 and – 6. Both 3 and – 6 are multiples of 3. Thus, every solution s is a multiple of 3. Note: Using a contrapositive proof helps get rid of the not’s and makes the problem easier to understand  indeed, the contrapositive turns this into a simple proof we can do exhaustively. Note: In the proof we make true statements. Recall: we can always make any true statement we wish in a proof.

Discussion #12 11/22 5. Proof by Contradiction Note: P P   P  F TT F T FT T F Thus,  P  F  P. By substituting R  S for P, we can prove R  S by proving  (R  S)  F.  (R  S)  F   (  R  S)  F implication   R   S  F de Morgan’s law  R   S  F double negation

Discussion #12 12/22 5. Proof by Contradiction (continued…) Thus, since R   S  F  R  S, from R  S, we negate the conclusion, add it as a premise, and derive a contradiction, i.e. derive F. Any contradiction (e.g. P   P) is equivalent to F, so deriving any contradiction is enough. BTW, in our project we will implement the semantics of Datalog by programming the computer to do a proof by contradiction.

Discussion #12 13/22 5. Proof by Contradiction: Example Prove: the empty set is unique. Since P  (  P  F), we can prove  P  F instead. i.e. We can prove: if the empty set is not unique, then there is a contradiction, or, in other words, assuming the empty set is not unique leads (deductively) to a contradiction. Proof: –Assume the empty set is not unique. –Then there are at least two empty sets  1 and  2 such that  1   2. –Since an empty set is a set and an empty set is a subset of every set,  1   2 and  2   1 and thus  1 =  2. –But now we now have  1   2 and  1 =  2  a contradiction.

Discussion #12 14/22 Informal Proofs in English vs. Formal Proofs Compare vs. 1.Empty set not uniqueassumed premise 2.Empty set not unique   1 and  2 exist   1   2 uniqueness definition 3.  1 and  2 exist   1   2 1&2, modus ponens 4.  1   2 3 simplification 5.  1   2   2   1 property of empty sets 6.  1   2   2   1   1 =  2 set equality definition 7.  1 =  2 5&6, modus ponens 8.  1   2   1 =  2 4&7 combination 9.F8 contradiction law (P  P  F) Assume the empty set is not unique. Then there are at least two empty sets  1 and  2 such that  1   2. Since an empty set is set and an empty set is a subset of every set,  1   2 and  2   1 and thus  1 =  2. But now we now have  1   2 and  1 =  2  a contradiction.

Discussion #12 15/22 6. Conditional Proof P  (Q  R)  (P  Q)  R Much simpler form Simple implication extra premise Easy to remember: make lhs of conclusion a premise. PQR P  (Q  R)  (P  Q)  R TTTTTTTT TTFFFTTF TFTTTTFT TFFTTTFT FTTTTTFT FTFTFTFT FFTTTTFT FFFTTTFT

Discussion #12 16/22 6. Conditional Proof: Example Prove: If A  B and B  C, then A  C.  If (x  A)  (x  B) and (x  B)  (x  C) then (x  A)  (x  C)  ((P  Q)  (Q  R))  (P  R)  (P  Q)  (Q  R)  P  R Proof: 1.Ppremise (assumed) 2.P  Qpremise 3.Q1&2, modus ponens 4.Q  Rpremise 5.R3&4, modus ponens

Discussion #12 17/22 6. Conditional Proof: Example Prove: If A  B and B  C, then A  C.  If (x  A)  (x  B) and (x  B)  (x  C) then (x  A)  (x  C)  ((P  Q)  (Q  R))  (P  R)  (P  Q)  (Q  R)  P  R Proof: 1.x  A premise (assumed) 2.(x  A)  (x  B) premise 3.x  B 1&2, modus ponens 4.(x  B)  (x  C) premise 5.x  C 3&4, modus ponens Let x  A. Then since (x  A)  (x  B), x  B. Thus, since x  B and (x  B)  (x  C), x  C.

Discussion #12 18/22 6. Conditional Proof: Example Prove: If A  B and B  C, then A  C.  If (x  A)  (x  B) and (x  B)  (x  C) then (x  A)  (x  C)  ((P  Q)  (Q  R))  (P  R)  (P  Q)  (Q  R)  P  R Proof: 1.x  A premise (assumed) 2.(x  A)  (x  B) premise 3.x  B 1&2, modus ponens 4.(x  B)  (x  C) premise 5.x  C 3&4, modus ponens Let x  A. Then since A  B, x  B. Thus, since x  B and B  C, x  C.

Discussion #12 19/22 7. Case Analysis P  (Q  P)  (  Q  P) PQ P  (Q  P)  (Q(Q  P) TTTTT FT TFTTT TT FTTFF FT FFTTF TF We can prove P by doing two proofs: (Q  P) and (  Q  P). And, we can choose any Q  presumably one that’s helpful.

Discussion #12 20/22 7. Case Analysis: Example Prove: There are no even primes except 2. If n is a prime, then n=2 or n is odd. Now add cases: u  (x  y  z)where u is n=2  u  (x  y  z)where  u is n  2 Now observe that we can use a conditional proof: u  x  y  z if n=2 and n is prime, then n=2 or n is odd  u  x  y  z if n  2 and n is prime, then n=2 or n is odd x y z  

Discussion #12 21/22 7. Case Analysis: Example Prove: If n is a prime, then n=2 or n is odd. Proof: Case 1: n=2: Since n=2, n=2 or n is odd holds. Case 2: n  2: Since n  2 and n is prime, n>2. Now n must be odd, for suppose that n is even, then n = 2k for some integer k>1. But then n is composite (not prime)  a contradiction. Thus, n is odd and hence n=2 or n is odd holds. Subproof

Discussion #12 22/22 8. Proof by Induction To be continued….