You are on page 1of 4

Truth table for EXCLUSIVE OR EXCLUSIVE OR

In English when we use OR in this sense, when we say p or q.


(p ∨ q) ∧ ~ (p ∧ q) It means either p is true or q is true or possibly both are true.
p q p ∨ q p ∧ ~ (p∧q) (p ∨ q) ∧ ~ (p ∧
q q) E.g.: Give me a book or bag. It means either give me a book
T T T T F F or bag or possibly give him both bag and book.
In the above statement, we are using OR in Inclusive sense.
T F T F T T
DOUBLE F T T F T T
E.g.: Tomorrow at 9’o clock, I will be in Lahore or Islamabad.
IMPLICATION/BICONDITIONAL F F F F T F In the above statement, we are using OR in Exclusive sense.
Lecture # 04

Exclusive OR Symbols for EXCLUSIVE OR Examples of Implication


When OR is used in exclusive sense, the statement “p or p⊕q p = “Aslam lives in Multan”
q” means “p or q but not both” q = “Aslam lives in Pakistan”
or
or “if p then q”
p XOR q “p implies q”
“p or q and not p and q” which translates into symbols Note: “if p, q”
as: Basically “p only if q”
p ⊕ q ≡ (p ∨ q) ∧ ~ (p ∧ q) “p is sufficient for q”
(p ∨ q) ∧ ~ (p ∧ q)

Note: Examples:
IMPLICATION is logically equivalent to its If you work hard you get good grades. If we sum up the implication (w g) and its converse
CONTROPOSITIVE. w = “You work hard” (g w) we get
g = “You get good grades”
IMPLLICATION and its CONVERSE they are not “You get good grades if and only if you work hard.”
equivalent to each other logically. w g = If w then g
= “If you work hard then you get good grades”. By summing up we get a new connective and we called
Implication’s INVERSE and CONVERSE are logically Converse: True this new connective BICONDITIONAL.
equivalent to each other.
g w = If g then w
= g only if w
IMPLICATION and its CONTROPOSITIVE are
= “You get good grades only if you work hard.”
equivalent to each other.
Bi-Conditional Connective TRUTH TABLE FOR EXAMPLES:
If p and q are statement variables, the biconditional of p p↔q “1 + 1 = 3 if and only if earth is flat.”
and q is TRUE
p q p↔q
T T T
“p if, and only if, q” and is denoted p ↔ q. “Sky is blue iff 1 = 0”
T F F
FALSE
F T F
if and only if abbreviated iff.
F F T
“Milk is white iff birds lay eggs.”
TRUE

p ↔ q ≡ (p → q) ∧ (q → p) REPHRASING BICONDITIONAL:
“33 is divisible by 4 if and only if horse has four p ↔ q is also expressed as:
legs.” p q p ↔ q p → q q → p (p → q) ∧ (q → p)
FALSE T T T T T T
“p is necessary and sufficient for q”
T F F F T F
“if p then q, and conversely”
“x > 5 iff x² > 25” F T F T F F
FALSE “p is equivalent to q”
F F T T T T

Note: Note:
same truth values
Biconditional is logically equivalent to conjunction of p ↔ q and q ↔ p are EQUIVALENT.
two implications: p iff q and q iff p are EQUIVALENT.
p ↔ q ≡ (p → q) ∧ (q → p)

REPHARASING ENGLISH SENTENCES IN


BICONDITIONAL CONECTIVE. TRUTH TABLE FOR (p → q) ↔ (~ q→ ~ p)
If it is hot outside you buy an ice cream cone, and If you read the news paper every day, you will be
informed and conversely. p q p → q ~q ~p ~ q→ ~ p (p → q) ↔ (~ q→ ~ p)
if you buy an ice cream cone it is hot outside.
You will be informed if and only if you read the newspaper T T T F F T T
You buy an ice cream cone if and only if it is hot every day.
outside. T F F T F F T
It rains if it is a weekend day, and it is a weekend day if F T T F T T T
For you to win the contest it is necessary and it rains. F F T T T T T
sufficient that you have the only winning ticket. It rains if and only if it is a weekend day.
Note:
You win the contest if and only if you have the only The result is TAUTOLOGY, It means both the expressions involved in statement
winning ticket. This number is divisible by 6 precisely when it is form are equivalent.
divisible by both 2 and 3.
This number is divisible by 6 if and only if it is divisible by
both 2 and 3.
(p ↔ q) ↔ (r ↔ q) HIERARCY OF CONNECTIVES p ∧ ~r ↔ q ∨ r
Resolve Innermost parenthesis, outmost parenthesis,. In this statement form we have no parenthesis.
p q r p ↔ q r ↔ q (p ↔ q) ↔ (r ↔ q)
Negation Here p ∧ ~ r ↔ q ∨ r means (p ∧ (~ r)) ↔ (q ∨ r)
T T T T T T
T T F T F F
Conjunction and Disjunction p q r ~r p ∧~r q ∨ r p ∧ ~r ↔ q ∨ r
T F T F F T Implication or Biconditional. T T T F F T F
T F F F T F T T F T T T T
F T T F T F T F T F F T F
F T F F F T T F F T T F F
F F T T F F F T T F F T F
F F F T T T F T F T F T F
F F T F F T F
F F F T F F T

Show that ~p ↔ q and p ↔ ~q are logically


equivalent EXERCISE: Laws of Logic
Show that ~(p ⊕ q) and p ↔ q are logically equivalent Commutative Law: p↔q≡q↔p
p q ~p ~q ~p ↔ q p ↔ ~q
T T F F F F p q p ⊕ q ~(p ⊕ q) p↔q
T T F T T
Implication Laws: p →q ≡ ~p ∨ q
T F F T T T
≡ ~(p ∧ ~q)
F T T F T T T F T F F
F F T T F F F T T F F
Exportation Law: (p ∧ q)→r ≡ p →(q →r)
F F F T T
same truth values
same truth values
Equivalence: p ↔ q ≡ (p →q) ∧ (q →p)

Reductio ad absurdum p →q ≡ (p ∧ ~q) →c

APPLICATION:
Rewrite the statement forms without using the 2. (p→r)↔(q →r) Rewrite the statement form ~p ∨ q → r ∨ ~q to a
symbols → or ↔ logically equivalent form that uses only ~ and ∧.
1. p∧~q→r 2. (p→r)↔(q →r) (p→r)↔(q →r) ≡ (~p ∨ r)↔(~q ∨ r) implication law
SOLUTION
Solution: ≡ [(~p ∨ r) →(~q ∨ r)] ∧ [(~q ∨ r) →(~p ∨ r)] ~p ∨ q → r ∨ ~q Given statement form
p∧~q → r ≡ (p ∧ ~q)→r order of operations equivalence of biconditional ≡ (~p ∨ q) → (r ∨ ~q) Order of operations
≡ ~(p∧~q) ∨ r implication law ≡ ~[(~p ∨ q) ∧ ~ (r ∨ ~q)] Implication law
≡ [~(~p ∨ r) ∨ (~q ∨ r)] ∧ [~(~q ∨ r) ∨ (~p ∨ r)] p → q ≡ ~(p∧~ q)
implication law ≡ ~[~(p ∧ ~q) ∧ (~r ∧ q)] De Morgan’s law
Show that ~(p → q) → p is a tautology
without using truth tables. EXERCISES: EXERCISE:
SOLUTION Show that (p ∧ q) → (p ∨ q) is a tautology. Suppose that p and q are statements so that p → q is
≡ ~(p → q) → p Given statement form false. Find the truth values of each of the following:
≡ ~[~(p ∧ ~q)] → p Implication law p → q ≡ ~(p ∧ Simplify (¬ p ∧ (p → q))→¬ q
~q) ~p →q
≡ (p ∧ ~q) → p Double negation law TRUE
Show that is a tautology.
≡ ~(p ∧ ~q) ∨ p Implication law p → q ≡ ~p ∨ q
p∨q
≡ (~p ∨ q) ∨ p De Morgan’s law
TRUE
≡ (q ∨ ~p) ∨ p Commutative law of
≡ q ∨ (~p ∨ p) Associative law of q↔p
≡q∨t Negation law FALSE
≡t Universal bound law

You might also like