Mathematical Logic
Mathematical Logic
Mathematical Logic
Lesson 2.3: Mathematical Logic
C. Logic
Terms:
1. Simple statement is a single statement denoted with any small
letters in the English Alphabet.
Example: r : Adele is a singer.
s : The sum of 4 and 5 is greater than 6.
t : The qoutient of 95 and 5 is 19.
5. Truth value table contains all possible truth values of the statement.
Lesson 2.3: Mathematical Logic
B. Negation (~ = not) is the opposite truth value of the assertion. That is,
p ~p (not p)
T F
F T
Lesson 2.3: Mathematical Logic
Solution: 1. (p ˅ q) ˄ ~q
Step 1. Determine 2n where n=2 since we have 2 statements p and q. That is,
2n = 22 = 4 possible truth values for p and q.
Step 2. Construct the table.
p q p˅q ~q (p ˅ q) ˄ ~q
T T T F F
T F T T T
F T T F F
F F F T F
Lesson 2.3: Mathematical Logic
2. ~p ˅ (~q → p)
Step 1. 2n = 22 = 4 possible truth values for p and q.
Step 2.
p q ~p ~q ~q → p ~p ˅ (~q → p)
T T F F T T
T F F T T T
F T T F T T
F F T T F T
Observe that the truth values of ~p ˅ (~q → p) are all true, then it is called
tautology. If the truth values are all false, it is called contradiction.
Lesson 2: Mathematical Logic
3. p ˅ (q ↔ s)
Step 1. 2n = 23 = 8
Step 2.
p q s q↔s p ˅ (q ↔ s)
T T T T T
T T F F T
T F T F T
T F F T T
F T T T T
F T F F F
F F T F F
F F F T T
Lesson 2.3: Mathematical Logic
Thus, p → q ≈ ~p ˅ q.
Let p and q be two statements.
n = 2, =
p q
T T
T F
F T
F F
p, q, and r. n = 3, =
p q r
T T T
T T F
T F T
T F F
F T T
F T F
F F T
F F F