Math.3336: Discrete Mathematics Propositional Equivalences Instructor: Dr. Blerina Xhabli Department of Mathematics, University of Houston https://www.math.uh.edu/ blerina Email: blerina@math.uh.edu Fall 2018 Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 1/22
Assignments to work on Homework #1 due Wednesday, 8/29, 11:59pm No credit unless turned in by 11:59pm on due date Late submissions not allowed, but lowest homework score dropped when calculating grades Homework will be submitted online in your CASA accounts. You can find the instructions on how to upload your homework in our class webpage. Read Sections 1.4, 1.5, 1.6 for next week. Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 2/22
Overview to Part I - The Propositional Logic Propositional Logic Summary The Language of Propositions Connectives Truth Values Truth Tables Applications Translating English Sentences System Specifications Logic Puzzles/Circuits Logical Equivalences Important Equivalences Showing Equivalence Satisfiability Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 3/22
Section 1.3 Propositional Equivalences Tautologies, Contradictions, and Contingencies. Logical Equivalence Important Logical Equivalences Showing Logical Equivalence Propositional Satisfiability Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 4/22
Tautologies, Contradictions and Contingencies The truth value of a propositional formula depends on truth assignments to variables. Some formulas evaluate to true for every assignment, e.g., p p. Such formulas are called tautologies or valid formulas Some formulas evaluate to false for every assignment, e.g., p p Such formulas are called contradictions or unsatisfiable formulas A propositional formula that is neither a tautology, nor a contradiction is called a contingency, e.g.,p. p p p p p p T F T F F T T F Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 5/22
Logical Equivalence Equivalent statements are important for logical reasoning since they can be substituted and can help us to: make a logical argument infer new propositions Two compound propositions p and q are logically equivalent if p q is a tautology. We write this as p q or as p q where p and q are compound propositions. Example: Show that p q is equivalent to p q. Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 6/22
Important Equivalences Some important equivalences are useful to know! Law of double negation: p p Identity Laws: p T p p F p Domination Laws: p T T p F F Idempotent Laws: p p p p p p Negation Laws: p p F p p T Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 7/22
Commutativity and Distributivity Laws Commutative Laws: p q q p p q q p Distributivity Law #1: (p (q r)) (p q) (p r) Distributivity Law #2: (p (q r)) (p q) (p r) Associativity Laws: p (q r) (p q) r p (q r) (p q) r Absorption Laws: p (p q) p, p (p q) p Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 8/22
De Morgan s Laws Let Math3325 be the proposition John took Math3325 and Math3336 be the proposition John took Math3336 In simple English what does (Math3325 Math3336) mean? Either did not take Math3325 or Math3336, i.e. Math3325 Math3336 DeMorgan s law expresses exactly this equivalence! De Morgan s Law #1: (p q) ( p q) De Morgan s Law #2: (p q) ( p q) When you push negations in, becomes and vice versa Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 9/22
More Logical Equivalences Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 10/22
Why are These Equivalences Useful? Use known equivalences to prove that two formulas are equivalent i.e., rewrite one formula into another using known equivalences Examples: Prove following formulas are equivalent: 1 (p ( p q)) and p q 2 (p q) and p q Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 11/22
Formalizing English Arguments in Logic We can use logic to prove correctness of English arguments. For example, consider the argument: If Joe drives fast, he gets a speeding ticket. Joe did not get a ticket. Therefore, Joe did not drive fast. Let f be the proposition Joe drives fast, and t be the proposition Joe gets a ticket How do we encode this argument as a logical formula? ((f t) t) f Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 12/22
Example, cont If Joe drives fast, he gets a speeding ticket. Joe did not get a ticket. Therefore, he did not drive fast. : ((f t) t) f How can we prove this argument is valid? by showing the formula is valid Can do this in two ways: 1 Use truth table to show formula is tautology 2 Use known equivalences to rewrite formula to true Let s use equivalences Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 13/22
Example, cont 1 ((f t) t) f 2 (( f t) t) f (remove ) 3 ( ( f t) t) f (De Morgan) 4 (( f t) t) f (De Morgan) 5 ((f t) t) f (double negation) 6 ((f t) ( t t)) f (distribute) 7 ((f t)) f (negation, identity) 8 f t f (distributivity) 9 true (negation, domination) Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 14/22
Another Example Can also use to logic to prove an argument is not valid. Suppose your friend George make the following argument: If Jill carries an umbrella, it is raining. Jill is not carrying an umbrella. Therefore it is not raining. Let s use logic to prove George s argument doesn t hold water. Let u = Jill is carrying an umbrella, and r = It is raining How do we encode this argument in logic? ((u r) u) r Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 15/22
Example, cont. If Jill carries an umbrella, it is raining. Jill is not carrying an umbrella. Therefore it is not raining. : ((u r) u) r How can we prove George s argument is invalid? Give interpretation under which formula evaluates to false Falsifying interpretation: u= false, r= true Note: Showing that you cannot rewrite it to true using equivalences is not sufficient to prove formula is not tautology because you may not have picked the right rewrite rules! Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 16/22
Examples Consider the formula F : p q p q Determine whether this formula is a tautology, contradiction or contigency. Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 17/22
Satisfiability, Validity A formula F is satisfiable iff there exists interpretation I s.t. F is true. A formula F is valid iff for all interpretations I, F is true. A formula F is unsatisfiable iff for all interpretations I, F is false. A formula F is contingent if it is satisfiable, but not valid. Valid formulas also called tautologies Unsatisfiable formulas called contradictions Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 18/22
True/False Questions Are the following statements true or false? If a formula is valid, then it is also satisfiable. true If a formula is satisfiable, then its negation is unsatisfiable. false, e.g. p If F 1 and F 2 are satisfiable, then F 1 F 2 is also satisfiable. false, e.g. F 1 = p, F 2 = p If F 1 and F 2 are satisfiable, then F 1 F 2 is also satisfiable. true, if F 1 true, then F 1 F 2 true. Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 19/22
Proving Validity Question: How can we prove that a propositional formula is a tautology? Construct a truth table for the formula and show it is true for any interpretation Exercise: Which formulas are tautologies? Prove your answer. 1 (p q) ( q p) 2 (p q) p 3 (p q) ( p q) Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 20/22
Proving Satisfiability, Unsatisfiability, Contingency Similarly, can prove satisfiability, unsatisfiability, contingency using truth tables: Satisfiable: There exists a row where formula evaluates to true Unsatisfiable: In all rows, formula evaluates to false Contingent: Exists a row where formula evaluates to true, and another row where it evaluates to false Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 21/22
Summary A formula is valid if it is true for all interpretations. A formula is satisfiable if it is true for at least one interpretation. A formula is unsatisfiable if it is false for all interpretations. A formula is contingent if it is true in at least one interpretation, and false in at least one interpretation. Two formulas F 1 and F 2 are equivalent, written F 1 F 2, if F 1 F 2 is valid Instructor: Dr. Blerina Xhabli, University of Houston Math.3336: Discrete Mathematics Propositional Equivalences 22/22