Propositional Equivalences

Slides:



Advertisements
Similar presentations
Propositional Equivalences
Advertisements

Propositional Equivalences
CSE 311: Foundations of Computing Fall 2013 Lecture 3: Logic and Boolean algebra.
Logic 1 Statements and Logical Operators. Logic Propositional Calculus – Using statements to build arguments – Arguments are based on statements or propositions.
Syllabus Every Week: 2 Hourly Exams +Final - as noted on Syllabus
1 Section 1.2 Propositional Equivalences. 2 Equivalent Propositions Have the same truth table Can be used interchangeably For example, exclusive or and.
EE1J2 – Discrete Maths Lecture 5
1 Set Operations CS/APMA 202, Spring 2005 Rosen, section 1.7 Aaron Bloomfield.
Propositional Equivalence Goal: Show how propositional equivalences are established & introduce the most important such equivalences.
Rosen 1.6. Approaches to Proofs Membership tables (similar to truth tables) Convert to a problem in propositional logic, prove, then convert back Use.
CSci 2011 Discrete Mathematics Lecture 3 CSci 2011.
Chapter 1 Section 1.4 More on Conditionals. There are three statements that are related to a conditional statement. They are called the converse, inverse.
Chapter 1 The Logic of Compound Statements. Section 1.1 Logical Form and Logical Equivalence.
Propositional Equivalences
Chap. 2 Fundamentals of Logic. Proposition Proposition (or statement): an declarative sentence that is either true or false, but not both. e.g. –Margret.
Logical Form and Logical Equivalence Lecture 2 Section 1.1 Fri, Jan 19, 2007.
1 Boolean Logic CS 202, Spring 2007 Epp, sections 1.1 and 1.2 Aaron Bloomfield.
1 Proof Strategies CS/APMA 202 Rosen section 3.1 Aaron Bloomfield.
Lecture Propositional Equivalences. Compound Propositions Compound propositions are made by combining existing propositions using logical operators.
CS 381 DISCRETE STRUCTURES Gongjun Yan Aug 25, November 2015Introduction & Propositional Logic 1.
Lecture 2.2: Set Theory* CS 250, Discrete Structures, Fall 2011 Nitesh Saxena *Adopted from previous lectures by Cinda Heeren.
Lecture 9 Conditional Statements CSCI – 1900 Mathematics for Computer Science Fall 2014 Bill Pine.
Section 1.2: Propositional Equivalences In the process of reasoning, we often replace a known statement with an equivalent statement that more closely.
Propositional Logic ITCS 2175 (Rosen Section 1.1, 1.2)
Logical Form and Logical Equivalence Lecture 1 Section 1.1 Wed, Jan 12, 2005.
Chapter 1: The Foundations: Logic and Proofs
1 Boolean Logic CS/APMA 202, Spring 2005 Rosen, section 1.1 Aaron Bloomfield.
CSci 2011 Recap ^Propositional operation summary not andorconditionalBi-conditional pq ppqqpqpqpqpqpqpqpqpq TTFFTTTT TFFTFTFF FTTFFTTF FFTTFFTT.
Symbolic Logic The Following slide were written using materials from the Book: The Following slide were written using materials from the Book: Discrete.
Spring 2003CMSC Discrete Structures1 Let’s get started with... Logic !
3/6/20161 Let’s get started with... Logic !. 3/6/20162 Logic Crucial for mathematical reasoningCrucial for mathematical reasoning Used for designing electronic.
Mathematics for Comter I Lecture 3: Logic (2) Propositional Equivalences Predicates and Quantifiers.
1 Georgia Tech, IIC, GVU, 2006 MAGIC Lab Rossignac Lecture 01: Boolean Logic Sections 1.1 and 1.2 Jarek Rossignac.
CS 270 Lecture 1 In Class Problems. Q1: Logic Puzzle You arrive at the end of a long hallway. There are two knights guarding two doors. One knight always.
Law of logic Lecture 4.
2. The Logic of Compound Statements Summary
Discrete Structures – CNS 2300
Lecture 1.2: Equivalences, and Predicate Logic
The Foundations: Logic and Proofs
Advanced Algorithms Analysis and Design
Propositional Equivalence
DISCRETE MATHEMATICS CHAPTER I.
CS 2210:0001 Discrete Structures Introduction and Scope: Propositions
CSNB 143 Discrete Mathematical Structures
CS 202, Spring 2008 Epp, sections 1.1 and 1.2
Proof methods We will discuss ten proof methods: Direct proofs
Logical Equivalence of Propositions
How do I show that two compound propositions are logically equivalent?
COT 3100, Spr Applications of Discrete Structures
(CSC 102) Discrete Structures Lecture 2.
Discussion #10 Logical Equivalences
Permutations and Combinations
Boolean Algebra A Boolean algebra is a set B of values together with:
Discrete Mathematics Lecture # 2.
Mathematics for Computing
Discrete Structures for Computer Science
Propositional Equivalences
Information Technology Department
Propositional Equivalence (§1.2)
CS 220: Discrete Structures and their Applications
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett
Propositional Equivalences
CSE 311 Foundations of Computing I
Propositional Logic.
CSS 342 Data Structures, Algorithms, and Discrete Mathematics I
Lecture 2: Propositional Equivalences
CS 250, Discrete Structures, Fall 2013
Discrete Mathematics Lecture # 3.
Discrete Structures Prepositional Logic 2
A THREE-BALL GAME.
Presentation transcript:

Propositional Equivalences CS/APMA 202, Spring 2005 Rosen, section 1.2 Aaron Bloomfield

Tautology and Contradiction A tautology is a statement that is always true p  ¬p will always be true (Negation Law) A contradiction is a statement that is always false p  ¬p will always be false (Negation Law) p p  ¬p p  ¬p T F

Logical Equivalence A logical equivalence means that the two sides always have the same truth values Symbol is ≡or  (we’ll use ≡)

Logical Equivalences of And p  T ≡ p Identity law p  F ≡ F Domination law p T pT F p F pF T

Logical Equivalences of And p  p ≡ p Idempotent law p  q ≡ q  p Commutative law p pp T F p q pq qp T F

Logical Equivalences of And (p  q)  r ≡ p  (q  r) Associative law p q r pq (pq)r qr p(qr) T F

Logical Equivalences of Or p  T ≡ T Identity law p  F ≡ p Domination law p  p ≡ p Idempotent law p  q ≡ q  p Commutative law (p  q)  r ≡ p  (q  r) Associative law

Corollary of the Associative Law (p  q)  r ≡ p  q  r (p  q)  r ≡ p  q  r Similar to (3+4)+5 = 3+4+5 Only works if ALL the operators are the same!

Logical Equivalences of Not ¬(¬p) ≡ p Double negation law p  ¬p ≡ T Negation law p  ¬p ≡ F Negation law

Sidewalk chalk guy Source: http://www.gprime.net/images/sidewalkchalkguy/

DeMorgan’s Law Probably the most important logical equivalence To negate pq (or pq), you “flip” the sign, and negate BOTH p and q Thus, ¬(p  q) ≡ ¬p  ¬q Thus, ¬(p  q) ≡ ¬p  ¬q p q p q pq (pq) pq pq (pq) pq T F

Yet more equivalences Distributive: Absorption p  (q  r) ≡ (p  q)  (p  r) p  (q  r) ≡ (p  q)  (p  r) Absorption p  (p  q) ≡ p p  (p  q) ≡ p

How to prove two propositions are equivalent? Two methods: Using truth tables Not good for long formula In this course, only allowed if specifically stated! Using the logical equivalences The preferred method Example: Rosen question 23, page 27 Show that:

Using Truth Tables (pq) →r pq (p→r)(q →r) q →r p→r r q p p q r p→r F

Using Logical Equivalences Original statement Definition of implication DeMorgan’s Law Associativity of Or Re-arranging Idempotent Law

Quick survey I understood the logical equivalences on the last slide Very well Okay Not really Not at all

Logical Thinking At a trial: Bill says: “Sue is guilty and Fred is innocent.” Sue says: “If Bill is guilty, then so is Fred.” Fred says: “I am innocent, but at least one of the others is guilty.” Let b = Bill is innocent, f = Fred is innocent, and s = Sue is innocent Statements are: ¬s  f ¬b → ¬f f  (¬b  ¬s)

Can all of their statements be true? Show: (¬s  f)  (¬b → ¬f)  (f  (¬b  ¬s)) ¬b ¬f ¬s ¬b→¬f f(¬b¬s) ¬b¬s ¬sf s f b b f s ¬b ¬f ¬s ¬sf ¬b→¬f ¬b¬s f(¬b¬s) T F

Are all of their statements true Are all of their statements true? Show values for s, b, and f such that the equation is true Original statement Definition of implication Associativity of AND Re-arranging Idempotent law Absorption law Distributive law Negation law Domination law

What if it weren’t possible to assign such values to s, b, and f? Original statement Definition of implication ... (same as previous slide) Domination law Re-arranging Negation law Contradiction!

Quick survey I feel I can prove a logical equivalence myself Absolutely With a bit more practice Not really Not at all

Logic Puzzles Rosen, page 20, questions 51-55 Knights always tell the truth, knaves always lie A says “At least one of us is a knave” and B says nothing A says “The two of us are both knights” and B says “A is a knave” A says “I am a knave or B is a knight” and B says nothing Both A and B say “I am a knight” A says “We are both knaves” and B says nothing

Sand Castles

Functional completeness Functional completeness is discussed on page 27 (questions 37-39) of the text All the “extended” operators have equivalences using only the 3 basic operators (and, or, not) The extended operators: nand, nor, xor, conditional, bi-conditional Given a limited set of operators, can you write an equivalence of the 3 basic operators? If so, then that group of operators is functionally complete

Rosen, § 1.2 question 46 Show that | (NAND) is functionally complete Equivalence of NOT: p | p ≡ p (p  p) ≡ p Equivalence of NAND (p) ≡ p Idempotent law

Rosen, § 1.2 question 46 Equivalence of AND: Equivalence of OR: p  q ≡ (p | q) Definition of nand p | p How to do a not using nands (p | q) | (p | q) Negation of (p | q) Equivalence of OR: p  q ≡ (p  q) DeMorgan’s equivalence of OR As we can do AND and OR with NANDs, we can thus do ORs with NANDs Thus, NAND is functionally complete

Quick survey I felt I understood the material in this slide set… Very well With some review, I’ll be good Not really Not at all

Quick survey The pace of the lecture for this slide set was… Fast About right A little slow Too slow