03_Propositional_Logic
03_Propositional_Logic
1
Email: [email protected]
2
URL: http://tgifernando.wordpress.com/
Dr. TGI Fernando (DSCS) Propositional Logic 1 / 22
Introduction (1)
E.g.
Suppose we know the following sentences (the premises) to be true:
“If I swim, then I will get wet.”
“If I take a shower, then I will get wet.”
From these sentences, we are justified to conclude:
“If I swim or I take a shower, then I will get wet.”
Propositional logic is able to capture the form of this argument
This is a valid argument (i.e., if the premises are true, the conclusion
must also be true)
This can be explained in propositional logic.
George Boole is regarded as the founder of propositional logic
although it can be found some traces of propositional logic in stoic
philosophy.
Another example
x + y > 0 is not a statement.
For some values of x and y the sentence is true (e.g. x = 3, y = 4).
For some values of x and y the sentence is false (e.g. x = −1, and
y = −5)
Ex. 1 Indicate which of the following sentences are statements.
1 For all x and y, x + y > 0
2 There exists x and y, x + y > 0
3 1,024 is the smallest four-digit number that is a perfect square.
4 She is a mathematics special student.
5 128 = 26
6 x = 26
Sol
(i) Q ∨ R
(ii) P ∧ Q
(iii) P ∧ (Q ∨ R)
P ¬P
T F
F T
Truth Table for ¬P
P Q P ∧Q
T T T
T F F
F T F
F F F
Truth Table for P ∧ Q
P Q P ∨Q
T T T
T F T
F T T
F F F
Truth Table for P ∨ Q
P Q P XOR Q
T T F
T F T
F T T
F F F
Truth Table for Exclusive OR (P XOR Q)
P Q P →Q
T T T
T F F
F T T
F F T
Truth Table for P → Q
Ex. 5 Translate the sentence “If the humidity is high and the
temperature is high, then one does not feel comfortable” into
propositional logic.
P Q P ↔Q
T T T
T F F
F T F
F F T
Truth Table for P ↔ Q
1. ¬
2. ∧, ∨
3. →, ↔
7. P ∧ P ≡ P
P ∨ P ≡ P (Idempotent laws)
8. P ∨ T ≡ T
P ∧ F ≡ F (Universal bound laws/Domination laws)
9. ¬(P ∧ Q) ≡ ¬P ∨ ¬Q
¬(P ∨ Q) ≡ ¬P ∧ ¬Q (De Morgan’s laws)
10. P ∨ (P ∧ Q) ≡ P
P ∧ (P ∨ Q) ≡ P (Absorption laws)
11. ¬T ≡ F
¬F ≡ T (Negations of T and F )
12. (P → Q) ≡ (¬P ∨ Q) (Implication law)
13. (P → Q) ≡ (¬Q → ¬P ) (Contrapositive law)
14. (P ↔ Q) ≡ (P → Q) ∧ (Q → P ) (Equivalence)
¬(¬P ∧ Q) ∧ (P ∨ Q)
≡ (¬(¬P ) ∨ ¬Q) ∧ (P ∨ Q) (De Morgan’s law)
≡ (P ∨ ¬Q) ∧ (P ∨ Q) (Double negation law)
≡ P ∨ (¬Q ∧ Q) (Distributive law)
≡ P ∨ F (Negation law)
≡ P (Identity law)
Ex. 10 Rewrite the statement “Either you get to work on time or you
are fired.” in if-then form.
Ex. 11 Write the negations for each of the following statements:
(i) If my car is in the repair shop, then I cannot get to the class.
(ii) If Sara lives in Athens, then she lives in Greece.
Ex. 12 Write the statement “If Howard can swim across the lake, then
Howard can swim to the island.” in its equivalent contrapositive form.