Truth Tables for Not, And and OR
- A truth table is a way to enumerate all possibilities of a logical expression.
- You need to MEMORIZE the truth tables for the five basic operations.
- And we will create truth tables for combinations of these operations.
- This is a basic tool in the world of logic.
NOT
- Consider the statement Today is Thursday
- p: Today is Thursday
- And the negation Today is not Thursday
- ~p
- If p is true, then ~p is false.
- If p is false, then ~p is true.
-
- We can tell that if p is true, the value of the expression ~p is false.
- This is the definition of the logical operator not
- Is ~(~p) = p
- Two statements are equivalent if they have exactly the same truth values in the answer columns of the truth tables.
- Are Today is Thursday and Today is not not Thursday equivalent?
AND
-
p | q | p ∧ q |
T | T | T |
T | F | F |
F | T | F |
F | F | F |
- And is only true when both sub statement are true.
OR
-
p | q | p ∨ q |
T | T | T |
T | F | T |
F | T | T |
F | F | F |
- Or is true when one or the other or both are true.
Conditional
- This one is odd
-
p | q | p → q |
T | T | T |
T | F | F |
F | T | T |
F | F | T |
- It is only false when the premise is true and the conclusion is false.
- if you get an "A" then I will buy you an ice cream cone.
- T → T : you get an "A" and I get you a cone. OK
- T → F : you get an "A" and I do not get you a cone. BAD
- F → T : you do not get an "A" and I get you a cone. OK, but probably too liberal a parent.
- F → F : you do not get an "A" and I do not get you a cone. OK,
If and Only If
-
p | q | p ↔ q |
T | T | T |
T | F | F |
F | T | F |
F | F | T |
- It is true only if both are the same.
Construct truth tables for
- ~(p ∨ ~q)
- ~p ↔ q
- Tanisha owns a convertible and Joan does not own a Volvo.
- If it is not raining then the baseball game is on.
- q ∨ (p → ~r)
- If Mary Andrews does not send me email then we can call her, or we can write to mom.
A self-contradiction is a compound statement that is always false.
(p ↔ q) ∧ (p ↔ ~q)
A tautology is a compound statement that is always true.
(~q → p) ∨ ~q
An implication is a conditional statement that is a tautology
p → (p ∨ q)