Professional Documents
Culture Documents
Predicates and Quantifiers
Predicates and Quantifiers
Introduction
Propositional logic, studied in previous lecture, cannot adequately
express the meaning of all statements in mathematics and in natural
language.
Predicates
Statements involving variables, such as
“x > 3,” “x = y + 3,” “x + y = z,”
and
“computer x is under attack by an intruder,”
and
“computer x is functioning properly,”
2
EXAMPLE 1 Let P(x) denote the statement “x > 3.” What are the
truth values of P(4) and P(2)?
3
EXAMPLE 2 Let A(x) denote the statement “Computer x is under
attack by an intruder.” Suppose that of the computers on campus,
only CS2 and MATH1 are currently under attack by intruders. What
are truth values of A(CS1), A(CS2), and A(MATH1)?
4
EXAMPLE 3 Let Q(x, y) denote the statement “x = y + 3.” What
are the truth values of the propositions Q(1, 2) and Q(3, 0)?
5
EXAMPLE 4 Let A(c, n) denote the statement “Computer c is
connected to network n,” where c is a variable representing a
computer and n is a variable representing a network. Suppose that
the computer MATH1 is connected to network CAMPUS2, but not
to network CAMPUS1. What are the values of A(MATH1,
CAMPUS1) and A(MATH1, CAMPUS2)?
7
Quantifiers
When the variables in a 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.
10
EXAMPLE 7 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?
Solution: Q(x) is not true for every real number x, because, for
instance, Q(3) is false. That is, x = 3 is a counterexample for the
statement ∀xQ(x). Thus
∀xQ(x)
is false.
11
The truth value of ∀xP(x) depends on the domain:
When all the elements in the domain can be listed—say, 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.
12
EXAMPLE 8 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?
13
The existential quantification of P(x) is the proposition
“There exists an element x in the domain such that P(x).”
We use the notation ∃xP(x) for the existential quantification of
P(x). Here ∃ is called the existential quantifier.
EXAMPLE 9 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?
14
EXAMPLE 10 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?
15
The truth value of ∃xP(x) depends on the domain:
When all elements in the domain can be listed—say, 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.
16
EXAMPLE 11 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?
17
EXAMPLE 12 Express the statement “Every student in this class
has studied calculus” using predicates and quantifiers.
Solution:
Let us introduce a variable x so that our statement becomes
18
EXAMPLE 13 Express the statements “Some student in this class
has visited Mexico” and “Every student in this class has visited either
Canada or Mexico” using predicates and quantifiers.
20
EXAMPLE 15 Consider these statements, of which the first three
are premises and the fourth is a valid conclusion.
“All hummingbirds are richly colored.”
“No large birds live on honey.”
“Birds that do not live on honey are dull in color.”
“Hummingbirds are small.”
Let P(x), Q(x), R(x), and S(x) be the statements “x is a
hummingbird,” “x is large,” “x lives on honey,” and “x is richly
colored,” respectively. Assuming that the domain consists of all
birds, express the statements in the argument using quantifiers and
P(x), Q(x), R(x), and S(x).
Solution: The negation of ∀x(x2 > x) is the statement ¬∀ x(x2 > x), which is
equivalent to ∃x ¬ (x2 > x). This can be rewritten as ∃x(x2 ≤ x).
The negation of ∃x(x2 = 2) is the statement ¬∃ x(x2 = 2), which is equivalent to
∀x ¬ (x2 = 2). This can be rewritten as ∀x(x2 = 2). The
truth values of these statements depend on the domain.
22
Understanding Statements Involving Nested Quantifiers
23
EXAMPLE 17 Translate into English the statement
∀x∀y((x > 0) ∧ (y < 0) → (xy < 0)),
where the domain for both variables consists of all real numbers.
Solution:
his statement says that for every real number x and for every real
number y, if x > 0 and y < 0, then xy < 0.
That is, this statement says that for real numbers x and y, if x is
positive and y is negative, then xy is negative.
This can be stated more succinctly as “The product of a positive
real number and a negative real number is always a negative real
number.”
24
EXAMPLE 18 Let P(x, y) be the statement “x + y = y + x.” What are
the truth values of the quantifications ∀x∀yP(x, y) and ∀y∀xP(x, y)
where the domain for all variables consists of all real numbers?
25
EXAMPLE 19 Let Q(x, y) denote “x + y = 0.” What are the truth
values of the quantifications ∃y∀xQ(x, y) and ∀x∃yQ(x, y), where the
domain for all variables consists of all real numbers?
Solution: The quantification, ∃y∀xQ(x, y)
denotes the proposition
“There is a real number y such that for every real number x, Q(x, y).”
No matter what value of y is chosen, there is only one value of x for
which x + y = 0. Therefore the statement ∃y∀xQ(x, y) is false.
26
EXAMPLE 20
Let Q(x, y, z) be the statement “x + y = z.” What are the truth values
of the statements ∀x∀y∃zQ(x, y, z) and ∃z∀x∀yQ(x, y, z), where the
domain of all variables consists of all real numbers?
Solution:
The quantification ∀x∀y∃zQ(x, y, z), which is the statement
“For all real numbers x and for all real numbers y there is a real
number z such that x + y = z,” is true.
28
Example-22
Determine the truth value of each of the following statements where
U = {1, 2, 3} is the universal set.
Ans.
(a) ∃x∀y, x2 < y + 1; (b) ∀x∃y, x2 + y2 < 12; (c) ∀x∀y, x2 + y2 < 12.
(a) True. For if x = 1, then 1, 2, and 3 are all solutions to 1 < y + 1.
(b) True. For each x, let y = 1; then x2 + 1 < 12 is a true statement.
(c) False. For if x = 2 and y = 3, then x2+ y2 < 12 is not a true
statement.
29
Example-23
Negate each of the following statements:
(a)∃x ∀y, p(x, y); (b) ∃x ∀y, p(x, y); (c) ∃y ∃x ∀z, p(x, y, z).
Solution:
Use ¬∀ x p(x) ≡ ∃x ¬ p(x) and ¬∃ x p(x) ≡ ∀x ¬ p(x):
(a) ¬ (∃x∀y, p(x, y)) ≡ ∀x∃y ¬ p(x, y)
(b) ¬ (∀x∀y, p(x, y)) ≡ ∃x∃y ¬ p(x, y)
(c) ¬ (∃y ∃x ∀z, p(x, y, z)) ≡ ∀y ∀x ∃z ¬ p(x, y, z)
30
EXAMPLE 24
Express the statement “If a person is female and is a parent, then this
person is someone’s mother” as a logical expression involving
predicates, quantifiers with a domain consisting of all people, and
logical connectives.
31