NEW Lesson 4.1 Introduction to Logic
NEW Lesson 4.1 Introduction to Logic
1
Introduction to
OGIC
What is L OGIC ?
1. 9 is an odd number.
2. 4 + 4 = 8
3. 10 − 1 = 8
4. 6 − 6 = −1
5. The square root of 4 is 1.
Statement and Sentences
A compound proposition is a proposition formed from simple
propositions using logical connectors or some combinations of
logical connectors. Logical connectors involving propositions p
and/or q may be expressed as:
not p
if p then q
p and q
p if and only if q
p or q
Statement and Sentences
A proposition is simple if it cannot be broken down any further
into other component propositions.
Example:
For each of the propositions, determine whether it is a simple
or compound proposition. If it is compound proposition,
identify the simple components.
Simple or Compound Proposition?
1. ∀𝑥 ∈ R (𝑥 2 ≥ 0)
The statement is true since the square of any real number is
always nonnegative.
Examples: Determine the truth value of the following statements.
3. (∀𝑥, ∀𝑦 ∈ 𝑅)(𝑥 + 𝑦 = 𝑦 + 𝑥)
The statement is true since the real numbers are commutative
under addition.
EXISTENTIAL QUANTIFIERS:
1. (∃𝒙 ∈ 𝑹)(𝒙𝟐 − 𝟏𝟎 ≥ 𝟎)
The statement (∃𝑥 ∈ 𝑅)(𝑥 2 − 10 ≥ 0) is true since if we
choose 𝑥 = 4, then 42 − 10 = 6 ≥ 0.
Examples: Determine the truth value of the following statements.
3. (∃𝒙 ∈ 𝒁)(𝟑𝒙 + 𝟐 = 𝟔)
4
The statement is false since 𝑥 must be equal to to make the
3
4
equation true, and is not an integer.
3
BASIC L O G I CA L O P E RAT O R S :
Given a proposition, its truth table shows all its possible truth values.
A proposition p would have For proposition p and q, truth
the truth table. value would be: p q
p T T
T T F
F F T
F F
p ~𝑝
Truth Table for Negation T F
F T
BASIC L O G I CA L O P E RAT O R S :
Examples: Write the negation of each of the following statements.
4. 3 times 7 = 20
Negation: 𝟑 × 𝟕 ≠ 𝟐𝟎
5. January has 31days
Negation: January does not have 31 days.
6. Eleven is not a prime number.
Negation: Eleven is a prime number.
BASIC L O G I CA L O P E RAT O R S :
Conjunctions
Answer: Fishes live in the moon if and only if birds can fly.
(False because p is false and q is true)
Examples:
Construct the biconditional statement and write its truth value.
p q 𝒑 ⊕𝒒
T T F
Truth Table of Exclusive-or Statement T F T
F T T
F F F
Examples of exclusive-or
TRUE FALSE
Determine if the statement is true or false.
2. Manny Pacquiao is a boxer if and only if
December is a summer month in the
Philippines.
TRUE FALSE
Determine if the statement is true or false.
3. Cigarette smoking causes cancer or Filipino is
the universal language, and Asia is a continent.
TRUE FALSE
Determine if the statement is true or false.
4. If ice cream is sweet, then cake is bitter.
TRUE FALSE
BASIC L O G I CA L O P E RAT O R S :
Operator Word/s Symbol Truth Value (Technique)
Negation
Conjunction
Disjunction
Conditional
Biconditional
Exclusive-or
BASIC L O G I CA L O P E RAT O R S :
Operator Word/s Symbol Truth Value (Technique)
Negation not ~ Opposite
Conjunction and ∧ Both true, True
Disjunction or ∨ Both false, False
Conditional if, then → True implies false, False
Biconditional if and only if Same truth values, True
Exclusive-or or ⊕ Diff. truth values, True
Determine if the statement is true or false.
1. Today is Sunday and it is raining.
2. 2016 is a leap year.
3. The boiling point of water is 0 ℃ or the freezing
point is 100 ℃.
4. 20 is divisible by 2 if and only if 20 is even.
CONSTRUCTING TRUTH TABLES
1. 𝑝 ˅ ~𝑞
2. ~𝑝 ⨁ 𝑞
3. 𝑝 ˅ 𝑞 ˄~𝑟
CONSTRUCTING TRUTH TABLES
1. 𝑝 ˅ ~𝑞
CONSTRUCTING TRUTH TABLES
1. 𝑝 ˅ ~𝑞
p q ~𝑞 𝑝 ˅ ~𝑞
T T F T
T F T T
F T F F
F F T T
CONSTRUCTING TRUTH TABLES
2. ~𝑝 ⨁ 𝑞
CONSTRUCTING TRUTH TABLES
2. ~𝑝 ⨁ 𝑞
p q ~𝑝 ~𝑝 ⨁ 𝑞
T T F T
T F F F
F T T F
F F T T
CONSTRUCTING TRUTH TABLES
3. 𝑝 ˅ 𝑞 ˄~𝑟
CONSTRUCTING TRUTH TABLES
3. 𝑝 ˅ 𝑞 ˄~𝑟 p q r 𝑝˅𝑞 ~𝑟 𝑝 ˅ 𝑞 ˄~𝑟
T T T T F F
T T F T T T
T F T T F F
T F F T T T
F T T T F F
F T F T T T
F F T F F F
F F F F T F
TAUTOLOGY, CONTRADICTION & CONTINGENCY
Tautology
A compound statement that is always true, regardless
of the truth values of its components, is called a
tautology.
TAUTOLOGY, CONTRADICTION & CONTINGENCY
Tautology
The proposition 𝑝 ˅ ~𝑝 is a tautology as the following table illustrates.
p ~𝒑 𝒑 ˅ ~𝒑
T F T
F T T
Contradiction
Contradiction
The proposition 𝑝 ˄ ~𝑝 is a contradiction as the following table
illustrates.
p ~𝒑 𝒑 ˄~𝒑
T F F
F T F
Contingency
A contingency is neither a tautology nor a contradiction.
Example:
1. 𝑝 ˅ ~ 𝑝 ˄ 𝑞
2. (𝑝˄~𝑞)˄(𝑝˄𝑞)
3. 𝑝 ˅~𝑝 ˄ 𝑞
1. 𝑝 ˅ ~ 𝑝 ˄ 𝑞
p q
T T
T F
F T
F F
Therefore, 𝑝 ˅ ~ 𝑝 ˄ 𝑞 is a tautology.
1. 𝑝 ˅ ~ 𝑝 ˄ 𝑞
p q 𝑝˄𝑞 ~ 𝑝˄𝑞 𝑝˅~ 𝑝˄𝑞
T T T F T
T F F T T
F T F T T
F F F T T
Therefore, 𝑝 ˅ ~ 𝑝 ˄ 𝑞 is a tautology.
2. (𝑝˄~𝑞)˄(𝑝˄𝑞)
p q
T T
T F
F T
F F
Therefore,(𝑝˄~𝑞)˄(𝑝˄𝑞)is a contradiction.
2. (𝑝˄~𝑞)˄(𝑝˄𝑞)
Therefore,(𝑝˄~𝑞)˄(𝑝˄𝑞)is a contradiction.
3. (𝑝 ˅~𝑝) ˄ 𝑞
p q
T T
T F
F T
F F
Therefore, (𝑝 ˅~𝑝) ˄ 𝑞 is a contingency
3. (𝑝 ˅~𝑝) ˄ 𝑞
p q ~𝑝 (𝑝 ˅~𝑝) (𝑝 ˅~𝑝) ˄ 𝑞
T T F T T
T F F T F
F T T T T
F F T T F
Therefore, (𝑝 ˅~𝑝) ˄ 𝑞 is a contingency
4. (~𝑝 ˄~𝑞) →(𝑟˄~𝑞)
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
4. (~𝑝 ˄~𝑞) →(𝑟˄~𝑞) is a contingency
p q r ~𝑝 ~𝑞 (~𝑝 ˄~𝑞) (𝑟˄~𝑞) (~𝑝 ˄~𝑞) →(𝑟˄~𝑞)
T T T F F F F T
T T F F F F F T
T F T F T F T T
T F F F T F F T
F T T T F F F T
F T F T F F F T
F F T T T T T T
F F F T T T F F
EQUIVALENT STATEMENTS
p q 𝑝→𝑞 ~𝑞 ~𝑝 ~𝑞 → ~𝑝
T T T F F T
T F F T F F
F T T F T T
F F T T T T
EQUIVALENT STATEMENTS
Another example: Determine if each of the following is
equivalent by constructing their truth tables.
1. ~ 𝑝 ˄ 𝑞 and ~𝑝 ˅ ~𝑞
2. ~ 𝑝 ˅ 𝑞 and ~𝑝 ˄~𝑞
3. 𝑝 → 𝑞 and ~𝑝 ˅ 𝑞
4. 𝑝 → 𝑞 ˄ (𝑞 → 𝑝) and 𝑝 𝑞
EQUIVALENT STATEMENTS
1. ~ 𝑝 ˄ 𝑞 𝑎𝑛𝑑 ~𝑝 ˅ ~𝑞
p q
T T
T F
F T
F F
EQUIVALENT STATEMENTS
1. ~ 𝑝 ˄ 𝑞 𝑎𝑛𝑑 ~𝑝 ˅ ~𝑞
p q 𝑝˄𝑞 ~ 𝑝˄𝑞 ~𝑝 ~𝑞 ~𝑝 ˅ ~𝑞
T T T F F F F
T F F T F T T
F T F T T F T
F F F T T T T
Hence, ~ 𝑝 ˄ 𝑞 ≡ ~𝑝 ˅ ~𝑞
EQUIVALENT STATEMENTS
2. ~ 𝑝 ˅ 𝑞 𝑎𝑛𝑑 ~𝑝 ˄~𝑞
p q
T T
T F
F T
F F
Hence, ~ 𝑝 ˅ 𝑞 ≡ ~𝑝 ˄~𝑞
EQUIVALENT STATEMENTS
2. ~ 𝑝 ˅ 𝑞 𝑎𝑛𝑑 ~𝑝 ˄~𝑞
p q 𝑝˅𝑞 ~ 𝑝˅𝑞 ~𝑝 ~𝑞 ~𝑝 ˄~𝑞
T T T F F F F
T F T F F T F
F T T F T F F
F F F T T T T
Hence, ~ 𝑝 ˅ 𝑞 ≡ ~𝑝 ˄~𝑞
EQUIVALENT STATEMENTS
3. 𝑝 → 𝑞 𝑎𝑛𝑑 ~𝑝 ˅ 𝑞
p q
T T
T F
F T
F F
Hence, 𝑝 → 𝑞 ≡ ~𝑝 ˅ 𝑞
EQUIVALENT STATEMENTS
3. 𝑝 → 𝑞 𝑎𝑛𝑑 ~𝑝 ˅ 𝑞
p q 𝑝→𝑞 ~𝑝 ~𝑝 ˅ 𝑞
T T T F T
T F F F F
F T T T T
F F T T T
Hence, 𝑝 → 𝑞 ≡ ~𝑝 ˅ 𝑞
EQUIVALENT STATEMENTS
4. (𝑝 → 𝑞)˄(𝑞 → 𝑝) and 𝑝 𝑞
p q
T T
T F
F T
F F
Hence,(𝑝 → 𝑞)˄(𝑞 → 𝑝) ≡ 𝑝 𝑞
EQUIVALENT STATEMENTS
4. (𝑝 → 𝑞)˄ 𝑞 → 𝑝 and 𝑝 𝑞
p q (𝑝 → 𝑞) (𝑞 → 𝑝) (𝑝 → 𝑞)˄(𝑞 → 𝑝) 𝑝 𝑞
T T T T T T
T F F T F F
F T T F F F
F F T T T T
Hence,(𝑝 → 𝑞)˄(𝑞 → 𝑝) ≡ 𝑝 𝑞
FORMS OF CONDITIONAL PROPOSITIONS
Truth table:
FORMS OF CONDITIONAL PROPOSITIONS
Consider the following true conditional:
𝑝 → 𝑞: "If today is Saturday, then it is a weekend."
State its (a) converse, (b) contrapositive, and (c) inverse, and determine
whether each statement is true.
Solution:
(a) Converse: "If today is a weekend, then it is Saturday."
(b) Contrapositive: "If today is not a weekend, then it is not Saturday."
(c) Inverse: "If today is not Saturday, then it is not a weekend."
Symbolic Arguments
An argument is an assertion that a given series of 𝑠
𝑃1 ,𝑃2 , … , 𝑃𝑚 called premises yields (has a consequence)
another statement Q, called the conclusion. The premises
are intended to demonstrate or at least provide some
evidences for the conclusion.
Symbolic Arguments
Example:
Some of the following are arguments. Identify their premises
and conclusions.
If I will study for the examination, then I will get a passing score.
I got a passing score.
Therefore, I studied for the examination.
Valid Arguments
An argument is said to be valid when all the
premises are true it forces the conclusion to be
true. An argument which is not valid is called an
invalid argument or fallacy.
Valid Arguments
Theorem: The argument consisting of the premises
𝑃1 ,𝑃2 , … , 𝑃𝑛 and conclusion Q is valid if and only if
the proposition 𝑃1 ˄ 𝑃2 ˄ … ˄ 𝑃𝑛 → 𝑄 is a
tautology.
List of SomeValid Arguments
1. Law of Detachment (also called modus ponens)
Symbolically, the argument is written:
Premise 1: 𝑝 → 𝑞
Premise 2: 𝑝____
∴𝑞
1. Law of Detachment (also called modus ponens)
[(𝑝 → 𝑞) ˄ 𝑝] → 𝑞
p q 𝑝 → 𝑞 (𝑝 → 𝑞) ˄ 𝑝 [(𝑝 → 𝑞) ˄ 𝑝] → 𝑞
T T T T T
T F F F T
F T T F T
F F T F T
The truth table above shows that we have a valid argument, since the compound
statement is a tautology.
List of SomeValid Arguments
2. Law of Contraposition (also called modus tollens)
Symbolically, the argument is written:
Premise 1: 𝑝 → 𝑞
Premise 2: ~𝑞____
∴ ~𝑝
2. Law of Contraposition (also called modus tollens)
[(𝑝 → 𝑞) ˄ ~𝑞] → ~𝑝
The truth table above shows that we have a valid argument, since the compound
statement is a tautology.
List of SomeValid Arguments
4. Rule of Disjunctive Syllogism
Symbolically, the argument is written:
Premise 1: 𝑝 ˅ 𝑞
Premise 2: ~𝑝____
∴𝑞
4. Rule of Disjunctive Syllogism
[(𝑝 ˅ 𝑞) ˄ ~𝑝] → 𝑞
Let p be “It rains today”, and q be “ I will wear my rain jacket.” and r be
“I will keep dry”. Clearly, by Law of Syllogism, this argument is valid.
List of SomeValid Arguments
d. Gregorio’s pencil is in his bag or it is on his table.
Gregorio’s pencil is not in his bag.
Therefore, Gregorio’s pencil is on his table.
p q 𝑝 → 𝑞 (𝑝 → 𝑞) ˄ 𝑞 [(𝑝 → 𝑞) ˄ 𝑞] → 𝑝
T T
T F
F T
F F
p q 𝑝 → 𝑞 (𝑝 → 𝑞) ˄ 𝑞 [(𝑝 → 𝑞) ˄ 𝑞] → 𝑝
T T T T T
T F F F T
F T T T F
F F T F T
Law of Detachment
(Modus Ponens)
Law of Contraposition
(Modus Tollens)
Law of Syllogism
Rule of Disjunctive
Syllogism
Consider each of the following argument. Identify the form of
valid argument that establishes its validity.
Law of Contraposition
Consider each of the following argument. Identify the form of
valid argument that establishes its validity.
Law of Detachment
Consider each of the following argument. Identify the form of
valid argument that establishes its validity.
Law of Syllogism
Consider each of the following argument. Identify the form of
valid argument that establishes its validity.