Module 4 - Logic
Module 4 - Logic
Lesson Objectives At the end of the lessons, you will be able to:
I. Logic Statements
Answer:
a. Not a statement
b. Statement
Statements that express single idea is called a simple statement while statement
that express two or more ideas is called the compound statement.
The truth value of a compound statement depends on the truth values of its simple
statements and its connectives.
Logical Operators
In a statement, the word some and the phrases there exists and at least one
are called existential quantifiers. Existential quantifiers are used as prefixes
to assert the existence of something.
In a statement, the words none, no, all, and every are called universal
quantifiers. The universal quantifiers none and no deny the existence of
something, whereas the universal quantifiers all and every are used to assert
that every element of a given set satisfies some condition.
Prepared by: Rafael J. Eusebio Jr. Universidad de Manila SY 2020-2021
The statement not P represented by –p is called the negation of P. It can
be expressed by “it is not the case that” or “it is false that”.
For example, the negation of “I have abandoned you” is “It is not true that
I have abandoned you.” Or “I have not abandoned you.”
The proposition “not p” is true when p is false; “not p” is false when p is true.
The rule for negation is presented on the following truth table:
p -p
T F
F T
Statement Negation
All X are Y Some X are not Y
No X are Y Some X are Y
Some X are not Y All X are Y
Some X are Y No X are Y
2. Disjunction
p q pvq
T T T
T F T
F T T
F F F
3. Conjunction
p q p^q
T T T
T F F
F T F
F F F
4. Conditional
p q p→q
T T T
T F F
F T T
F F T
5. Biconditional
p q p↔q
T T T
T F F
F T F
F F T
Every conditional statement has three related statements. They are called the
converse, the inverse, and the contrapositive.
The converse of p → q is q → p.
The inverse of p → q is -p → -q.
The contrapositive of p → q is -q → -p.
Example 1: Write the converse, inverse, and contrapositive of “If I get job, then I
will buy the NMAX motor”.
Solution:
Converse – If I buy the NMAX motor, then I get the job.
Inverse – If I do not get the job, then I will not buy the NMAX motor.
Contrapositive – If I do not buy the NMAX motor, then I did not get the job.
Example 2: Write the converse, inverse, and contrapositive of “If we have a quiz
today, then we will not have a quiz tomorrow”.
Converse – If we will not have a quiz tomorrow, then we have a quiz today.
Inverse – If we do not have a quiz today, then we will have a quiz tomorrow.
Contrapositive – If we will have a quiz tomorrow, we do not have a quiz today.
Example 1:
Solution:
a. p ^ q
b. -q ^ r
c. –s v r
d. q → s
Example 2:
Solution:
a. The game will be shown in ABS-CBN and the game will be played in
Araneta Coliseum.
b. The game will be shown in GMA and the UDM are favored to win.
c. The UDM are favored to win if and only if the game will not be played in
Araneta Coliseum.
The truth table is a table that shows the truth value of a compound statement or
proposition for all possible truth values of its simple statements. The truth value of
a given proposition is always appears in the last column of the truth table.
Proposition with 2 variables, 4 rows are necessary to construct the truth table; for
3 variables, 8 rows are necessary; and in general, for n variables, 2n rows are
required. Below are the examples:
Solution: Since the given proposition has 2 variables p and q, we need 4 rows.
p q -p -p v q (-p v q) v q
T T F T T
T F F F F
F T T T T
F F T T T
Solution: Since the given proposition has 3 variables p, q, and r, we need 8 rows.
p q r -r (p v q) (p v q) ʌ -r
T T T F T F
T T F T T T
T F T F T F
T F F T T T
F T T F T F
F T F T T T
F F T F F F
F F F T F F
p q r s (p v q) (r v s) (p v q) ʌ (r v s)
T T T T T T T
T T T F T T T
T T F T T T T
Propositions are called tautologies if contain only True in the last column of their
truth table, in other words, they are true for any truth values of their variables.
Analogously, a propositions are called contradiction if contain only False in the
last column of their truth table or, in other words, it is false for any truth values of
its variables. Lastly, contingency is a proposition which is neither a tautology nor a
contradiction.
Two statements are equivalent if they both have the same truth value for all
possible truth values of their simple statements. Equivalent statements have
identical truth values in the final columns of their truth tables. The notation p
≡ q is used to indicate that the statements p and q are equivalent.
Solution:
p q -q p v –q –(p v –q)
T T F T F
T F T T F
F T F F T
F F T T F
p q -p –p ʌ q
T T F F
T F F F
F T T T
F F T F
Since their truth values are equivalent, thus, –(p v –q) and –p ʌ q are
equivalent statements.
Solution:
p q -p -q -p v –q –(p v –q)
T T F F F T
T F F T T F
F T T F T F
F F T T T F
p q pʌq
T T T
T F F
F T F
F F F
1. x2 – 9 = 0.
2. Is 2 a positive number?
3. Study mathematics in the modern world
4. If stock prices fall, then I will lose money.
5. 121 is a perfect square.
6. President Arroyo is over 5 feet tall.
7. What time is it?
8. z + 3 is a positive integer.
9. The sum of all integers from 1 to n.
10. 11 is an even number.
1. (p v r) ʌ q
2. –s → (p ʌ -q)
3. p → (q ʌ -r)
4. (s ʌ -q) → t
5. (r ʌ p) ↔ q
6. t ↔ (-r ʌ -p)
IV. Write the negation of each quantified statement. Start each negation
with “Some”, “No”, or “All”.
1. p ʌ (q ʌ -p)
2. (p ʌ q) v (p → -q)
3. [-(p → q)] ↔ (p ʌ -q)
VII. Use a truth table to show that the given pairs of statements are
equivalent.
1. -p → -q ; p v –q
2. p ↔ q ; (p ʌ q) v (-p ʌ -q)
VIII. Write the converse, inverse, and contrapositive of the given statement.
List of References: