4 Predicates and Quantifiers 1

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 23

1

CSC102: Discrete Structure


Lecture #: 8
Unit: 1
Instructor:
MISHAL IQBAL

COMSATS University Islamabad


Vehari Campus
2

Topics

Predicate Logic
Quantifiers
3

Predicate Definition
 A predicate is a sentence that contains a finite number of
variables and becomes a statement when specific values are
substituted for the variables.
The domain of a predicate variable is the set of all values that
may be substituted in place of the variable.
If P(x) is a predicate and x has domain D, the truth set of P(x)
is the set of all elements of D that make P(x) true or false
when they are substituted for x. The truth set of P(x) is denoted
{x ∈ D | P(x)}
4

Predicate Overview
The statement P(x) is also said to be the value of the
propositional function P at x.
Once a value has been assigned to the variable x, the statement
P(x) becomes a proposition and has a truth value.
We can also have statements that involve more than one
variable. For instance, consider the statement “x = y + 3.”
We can denote this statement by Q(x, y), where x and y are
variables and Q is the predicate.
When values are assigned to the variables x and y, the
statement Q(x, y) has a truth value.
5

Predicate Overview
Similarly, we can R(x, y, z) denote the statement`‘ x + y = z.”
When values are assigned to the variables x, y, and z, this
statement has a truth value.
Example: What are the truth values of the propositions
R(1, 2, 3) and R(0, 0, 1)?
In general, a statement involving the n variables x 1, x2, . . . , xn
can be denoted by P(x1, x2, . . . , xn).
A statement of the form P(x1, x2, . . . , xn) is the value of the
propositional function P at the n-tuple (x1, x2, . . . , xn), and P
is also called an n-place predicate or a n-ary predicate.
6

Quantifier Overview

When the variables in a predicate (propositional function) are


assigned values, the resulting statement becomes a proposition
with a certain truth value.
However, there is another important way, called
quantification, to create a proposition from a propositional
function.
Quantification expresses the extent to which a predicate is true
over a range of elements.
7

Quantifier Overview

We will focus on two types of quantification here: universal


quantification, which tells us that a predicate is true for every
element under consideration, and
Existential quantification, which tells us that there is one or
more element under consideration for which the predicate is
true.
The area of logic that deals with predicates and quantifiers is
called the predicate calculus.
The Universal 8

Quantifier Definition
The universal quantification of P(x) for a particular domain is
the proposition that asserts that P(x) is true for all values of x
in this domain.
The meaning of the universal quantification of P(x) changes
when we change the domain.
The Universal 9

Quantifier Example
 Example: Let P(x) be the statement “x + 1 > x.” What is the truth
value of the quantification ∀xP(x), where the domain consists of all
real numbers?
 Solution: Because P(x) is true for all real numbers x, the
quantification ∀xP(x) is true.
 Example: Let Q(x) be the statement “x < 2.” What is the truth
value of the quantification ∀xQ(x), where the domain consists of
all real numbers?
 Example: Suppose that P(x) is “x2 > 0.” To show that the statement
∀xP(x) is false where the universe of discourse consists of all
integers.
The Universal 10

Quantifier Example

 Example: What is the truth value of ∀xP(x), where P(x) is the


statement “x2 < 10” and the domain consists of the positive
integers not exceeding 4? False
Example: What is the truth value of ∀x(x2 ≥ x) if the domain
consists of all real numbers? False
Example: What is the truth value of ∀x(x2 ≥ x) if the domain
consists of all integers? True
The Universal 11

Quantifier Example
Let all the elements in the domain are listed, x1, x2, . . ., xn
it follows that the universal quantification ∀xP(x) is the same
as the conjunction P(x1) ∧ P(x2) ∧ · · · ∧ P(xn), because this
conjunction is true if and only if P(x1), P(x2), . . . , P (xn) are all
true.
Remark: Generally, an implicit assumption is made that all
domains of discourse for quantifiers are nonempty.
Note that if the domain is empty, then ∀xP(x) is true for any
propositional function P(x) because there are no elements x in
the domain for which P(x) is false.
The Existential 12

Quantifier Definition
With existential quantification, we form a proposition that is
true if and only if P(x) is true for at least one value of x in the
domain.
A domain must always be specified when a statement ∃xP(x)
is used.
Furthermore, the meaning of ∃xP(x) changes when the domain
changes.
Without specifying the domain, the statement ∃xP(x) has no
meaning.
The Existential 13

Quantifier Definition

The existential quantification ∃xP(x) is read as


“There is an x such that P(x),”
“There is at least one x such that P(x),” or
“For some xP(x).”
The Existential 14

Quantifier Example
Example: Let P(x) denote the statement “x > 3.” What is the
truth value of the quantification ∃xP(x), where the domain
consists of all real numbers? True
Observe that the statement ∃xP(x) is false if and only if there
is no element x in the domain for which P(x) is true.
That is, ∃xP(x) is false if and only if P(x) is false for every
element of the domain.
Example: Let Q(x) denote the statement “x = x + 1.”What is
the truth value of the quantification ∃xQ(x), where the
domain consists of all real numbers? False
The Existential 15

Quantifier Example
Let all elements in the domain are listed, x1, x2, . . . , xn
the existential quantification ∃xP(x) is the same as the
disjunction P(x1) ∨ P(x2) ∨ · · · ∨ P(xn), because this
disjunction is true if and only if at least one of P(x1),
P(x2), . . . , P (xn) is true.
Remark: Generally, an implicit assumption is made that all
domains of discourse for quantifiers are nonempty.
If the domain is empty, then ∃xQ(x) is false whenever Q(x) is
a propositional function because when the domain is empty,
there can be no element x in the domain for which Q(x) is
The Existential 16

Quantifier Example

Example: What is the truth value of ∃xP(x), where P(x) is the


statement “x2 > 10” and the universe of discourse consists of
the positive integers not exceeding 4? True
17
Restricted
Quantifier Domain
An abbreviated notation is often used to restrict the domain of
a quantifier.
In this notation, a condition a variable must satisfy is included
after the quantifier.
Example: What do the statements ∀x < 0 (x2 > 0),
∀y ≠ 0 (y3 ≠ 0), and ∃z > 0 (z2 = 2) mean, where the
domain in each case consists of the real numbers?
18
Restricted
Quantifier Domain
Solution: The statement ∀x < 0 (x2 > 0), states that

“The square of a negative real number is positive.” This


statement is the same as ∀x(x < 0 → x2 > 0).
The statement ∀y ≠ 0 (y3 ≠ 0), states that

“The cube of every nonzero real number is nonzero.” This


statement is equivalent to ∀y(y ≠ 0 → y3 ≠ 0).
Finally, the statement ∃z > 0 (z2 = 2), states that

“There is a positive square root of 2.” This statement is


equivalent to ∃z(z > 0 ∧ z2 = 2).
19
Logical
Quantifier Equivalence
Quantified Universal
20

Expression Quantification
 We consider the negation of the statement
“Every student in your class has taken a course in calculus.”
 This statement is a universal quantification, namely, ∀xP(x), where
P(x) is the statement “x has taken a course in calculus” and the domain
consists of the students in your class.
 The negation of this statement is
“It is not the case that every student in your class has taken a
course in calculus.”
 This is equivalent to “There is a student in your class who has not
taken a course in calculus.” ∃x ¬ P(x).
Quantified Existential
21

Expression Quantification

“There is a student in this class who has taken a course in calculus.”


 This is the existential quantification ∃xQ(x), where Q(x) is the
statement “x has taken a course in calculus.”
 The negation of this statement is the proposition “It is not the case that
there is a student in this class who has taken a course in calculus.”
 It is equivalent to “Every student in this class has not taken calculus”
which is just the universal quantification of the negation of the original
propositional function, ∀x ¬ Q(x).
De Morgan’s
Quantified Laws for
22

Expression Quantifiers
23

You might also like