Lesson 4
Lesson 4
Quantifiers
The variable of predicates is quantified by quantifiers. There are two types of quantifier
in predicate logic − Universal Quantifier and Existential Quantifier.
Universal Quantifier
Universal quantifier states that the statements within its scope are true for every value
of the specific variable. It is denoted by the symbol ∀.
∀xP(x) is read as for every value of x, P(x) is true.
Nested Quantifiers
If we use a quantifier that appears within the scope of another quantifier, it is called
nested quantifier.
Example
∀ a ∃bP(x,y) where P(a,b) denotes a + b = 0
∀ a∀b∀cP(a,b,c) where P(a,b) denotes a+(b+c)=(a+b)+c
Note − ∀a ∃bP(x,y)≠∃a∀bP(x,y)
To deduce new statements from the statements whose truth that we already
know, Rules of Inference are used.
P P∨Q
Addition Disjunctive Syllogism
∴P∨Q ¬P
∴Q
P P→Q
Q Q→R Hypothetical
Conjunction
Syllogism
∴P∧Q ∴P→R
∴P P∨R Constructive
Simplification
Dilemma
∴Q∨S
P→Q
¬Q Modus Tollens
∴¬P
Addition
If P is a premise, we can use Addition rule to derive P∨Q.
P
∴P∨Q
Example
Let P be the proposition, “He studies very hard” is true
Therefore − "Either he studies very hard Or he is a very bad student." Here Q is the
proposition “he is a very bad student”.
Conjunction
If P and Q are two premises, we can use Conjunction rule to derive P∧.
P
Q
∴P∧Q
Example
Let P − “He studies very hard”
Let Q − “He is the best boy in the class”
Therefore − "He studies very hard and he is the best boy in the class"
Simplification
If P∧QP∧Q is a premise, we can use Simplification rule to derive P.
P∧Q
∴P
Example
"He studies very hard and he is the best boy in the class", P∧QP∧Q
Therefore − "He studies very hard"
Modus Ponens
If P and P→Q are two premises, we can use Modus Ponens to derive Q.
P→Q
P∴Q
Example
"If you have a password, then you can log on to facebook", P→Q
"You have a password", P
Therefore − "You can log on to facebook"
Modus Tollens
If P→Q and ¬Q are two premises, we can use Modus Tollens to derive ¬P.
P→Q
¬Q
∴¬P
Example
"If you have a password, then you can log on to Facebook", P→Q
"You cannot log on to Facebook", ¬Q
Therefore − "You do not have a password "
Disjunctive Syllogism
If ¬P and P∨Q are two premises, we can use Disjunctive Syllogism to derive Q.
¬P
P∨Q
∴Q
Example
"The ice cream is not vanilla flavored", ¬P
"The ice cream is either vanilla flavored or chocolate flavored", P∨Q
Therefore − "The ice cream is chocolate flavored”
Hypothetical Syllogism
If P→Q and Q→R are two premises, we can use Hypothetical Syllogism to
derive P→R
P→Q
∴P→R
Example
"If it rains, I shall not go to school”, P→Q
"If I don't go to school, I won't need to do homework", Q→R
Therefore − "If it rains, I won't need to do homework"
Constructive Dilemma
If (P→Q)∧(R→S) and P∨R are two premises, we can use constructive dilemma to
derive Q∨S.
(P→Q)∧(R→S)
P∨R
∴Q∨S
Example
“If it rains, I will take a leave”, (P→Q)
“If it is hot outside, I will go for a shower”, (R→S)
“Either it will rain or it is hot outside”, P∨R
Therefore − "I will take a leave or I will go for a shower"
Destructive Dilemma
If (P→Q)∧(R→S) and ¬Q∨¬S¬ are two premises, we can use destructive dilemma
to derive ¬P∨¬R.
(P→Q)∧(R→S)
¬Q∨¬S
∴¬P∨¬R
Example
“If it rains, I will take a leave”, (P→Q)
“If it is hot outside, I will go for a shower”, (R→S)
“Either I will not take a leave or I will not go for a shower”, ¬Q∨¬S
Therefore − "Either it does not rain or it is not hot outside"