propositional equivalences
DESCRIPTION
Propositional Equivalences. From Aaron Bloomfield.. Used by Dr. Kotamarti. 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). - PowerPoint PPT PresentationTRANSCRIPT
1
Propositional Equivalences
From Aaron Bloomfield..Used by Dr. Kotamarti
2
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 ¬pT T FF T F
3
Logical Equivalence
A logical equivalence means that the two sides always have the same truth values Symbol is ≡or (we’ll use ≡)
4
p T ≡ p Identity law
p F ≡ F Domination law
Logical Equivalences of And
p T pTT T TF T F
p F pFT F FF F F
5
p p ≡ p Idempotent law
p q ≡ q p Commutative law
Logical Equivalences of And
p p ppT T TF F F
p q pq qpT T T TT F F FF T F FF F F F
6
(p q) r ≡ p (q r) Associative law
Logical Equivalences of And
p q r pq (pq)r qr p(qr)T T T T T T TT T F T F F FT F T F F F FT F F F F F FF T T F F T FF T F F F F FF F T F F F FF F F F F F F
7
p T ≡ T Identity lawp F ≡ p Domination lawp p ≡ p Idempotent lawp q ≡ q p Commutative law(p q) r ≡ p (q r) Associative law
Logical Equivalences of Or
8
Corollary of the Associative Law
(p q) r ≡ p q r(p q) r ≡ p q rSimilar to (3+4)+5 = 3+4+5Only works if ALL the operators are the same!
9
¬(¬p) ≡ p Double negation lawp ¬p ≡ T Negation lawp ¬p ≡ F Negation law
Logical Equivalences of Not
10
Sidewalk chalk guy
Source: http://www.gprime.net/images/sidewalkchalkguy/
11
DeMorgan’s Law
Probably the most important logical equivalenceTo negate pq (or pq), you “flip” the sign, and negate BOTH p and q
Thus, ¬(p q) ≡ ¬p ¬q Thus, ¬(p q) ≡ ¬p ¬q
p q p q pq (pq) pq pq (pq) pqT T F F T F F T F FT F F T F T T T F FF T T F F T T T F FF F T T F T T F T T
12
Yet more equivalences
Distributive:p (q r) ≡ (p q) (p r)p (q r) ≡ (p q) (p r)
Absorptionp (p q) ≡ pp (p q) ≡ p
13
How to prove two propositions are equivalent?
Two methods: Using truth tables
Not good for long formulaIn this course, only allowed if specifically stated!
Using the logical equivalencesThe preferred method
Example: Rosen question 23, page 35 Show that: rqprqrp )()()(
14
Using Truth Tables
p q r p→r q →r (p→r)(q →r) pq (pq) →r
T T T T T T T TT T F F F F T F
T F T T T T F T
T F F F T T F T
F T T T T T F T
F T F T F T F T
F F T T T T F T
F F F T T T F T
rqprqrp )()()(
(pq) →rpq(p→r)(q →r)q →rp→rrqp
15
Idempotent Law
Associativity of Or
rqprqrp )()()( Definition of implication
Using Logical Equivalences
rqprqrp )()()(
rqprqp rqprrqp
rqprqrp )()()(
rqprqrp
Re-arranging
Original statement
DeMorgan’s Law
qpqp
qpqp )(
rqrprqrp )()(
rrr
16
Quick survey I understood the logical
equivalences on the last slidea) Very wellb) Okayc) Not reallyd) Not at all
18
Logical ThinkingAt 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 innocentStatements are:
¬s f ¬b → ¬f f (¬b ¬s)
19
Can all of their statements be true?Show: (¬s f) (¬b → ¬f) (f (¬b ¬s))
b f s ¬b ¬f ¬s ¬sf ¬b→¬f ¬b¬s f(¬b¬s)
T T T F F F F T F FT T F F F T T T T T
T F T F T F F T F F
T F F F T T F T T F
F T T T F F F F T T
F T F T F T T F T T
F F T T T F F T T F
F F F T T T F T T F
¬b ¬f ¬s ¬b→¬f f(¬b¬s)¬b¬s¬sfsfb
20
Are all of their statements true?Show values for s, b, and f such
that the equation is trueOriginal statementDefinition of implicationAssociativity of ANDRe-arrangingIdempotent lawRe-arrangingAbsorption lawRe-arrangingDistributive lawNegation lawDomination lawAssociativity of ANDTsbf
Tsbffbfs ))(()()(Tsbffbfs ))(()()(Tsbffbfs )()(Tsbfbffs )()(Tsbfbfs )()(Tbssfbf )()(Tsfbf )(
Tsfbf )( Tsffbf )()(
TsFbf )(Tsbf )(
21
What if it weren’t possible to assign such values to s, b, and f?
Original statementDefinition of implication... (same as previous slide)Domination lawRe-arrangingNegation lawDomination lawDomination lawContradiction!
Tssbf
Tssbffbfs ))(()()(Tssbffbfs ))(()()(
Tssbf )(
TFbf TFf TF
22
Quick survey I feel I can prove a logical
equivalence myselfa) Absolutelyb) With a bit more practicec) Not reallyd) Not at all
23
Logic PuzzlesRosen, page 23, questions 19-23Knights always tell the truth, knaves always lieA says “At least one of us is a knave” and B says nothingA 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 nothingBoth A and B say “I am a knight”A says “We are both knaves” and B says nothing
24
Sand Castles
25
Quick survey I felt I understood the material in this
slide set…a) Very wellb) With some review, I’ll be goodc) Not reallyd) Not at all
26
Quick survey The pace of the lecture for this
slide set was…a) Fastb) About rightc) A little slowd) Too slow