0% found this document useful (0 votes)
65 views

Predicate Calculus PDF

The document introduces predicate calculus. It defines a predicate as a statement containing variables that is neither true nor false until values are assigned to the variables. Predicates allow expressing statements about mathematical and natural language concepts more precisely than propositional logic alone. Quantifiers are introduced that allow reasoning about whether properties hold for all or some objects, enabling inferences that propositional logic cannot.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
65 views

Predicate Calculus PDF

The document introduces predicate calculus. It defines a predicate as a statement containing variables that is neither true nor false until values are assigned to the variables. Predicates allow expressing statements about mathematical and natural language concepts more precisely than propositional logic alone. Quantifiers are introduced that allow reasoning about whether properties hold for all or some objects, enabling inferences that propositional logic cannot.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 273

Predicate Calculus

Mbigili L.J
Mzumbe University

December 11, 2020

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 1 / 17


Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 2 / 17
Introduction
Introduction
Propositional logic studied so far cannot
adequately express the meaning of
statements in mathematics and natural
language.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 3 / 17


Introduction
Introduction
Propositional logic studied so far cannot
adequately express the meaning of
statements in mathematics and natural
language.
For instance, let computer x and
computer y be among computers
connected to Mzumbe university network.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 3 / 17
Introduction
Introduction
If we consider that, “computer x is
functioning properly”, then we find that
there are no rules of propositional logic
that allow us to conclude the truth of the
statement: “Every computer connected to
Mzumbe university network is
functioning properly”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 4 / 17
Introduction
Introduction
Also if “computer y is under attack by
an intruder”then, likewise, we cannot use
the rules of propositional logic to conlude
the truth of the statement
“There is a computer on Mzumbe
university network that is under attack
by an intruder”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 5 / 17
Introduction

Introduction
In this section, we will be introduced to a
more powerful tool of logic called
predicate logic, that can handle such
cases.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 6 / 17


Introduction

Introduction
We will see how predicate logic can be used
to express the meaning of a wide range of
statements in mathematics and computer
science in ways that permit us to reason
and explore relationships between objects.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 7 / 17


Introduction

Introduction
To understand predicate logic, we first
need to be introduced to the concept of a
Predicate.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 8 / 17


Introduction
Introduction
Afterward, we will be introduced to the
notion of Quantifiers which enable us to
reason with statements that assert that
a certain property holds for all
objects of a certain type and with
statements that assert the existence
of an object with a particular
property.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 9 / 17
Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 10 / 1
Predicates

Predicates
Statements involving variables, such as

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 11 / 1


Predicates

Predicates
Statements involving variables, such as
a) x > 3 (b) x = y + 3 (c) x + y = z

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 11 / 1


Predicates

Predicates
Statements involving variables, such as
a) x > 3 (b) x = y + 3 (c) x + y = z
d) “Computer x is functioning properly”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 11 / 1


Predicates

Predicates
Statements involving variables, such as
a) x > 3 (b) x = y + 3 (c) x + y = z
d) “Computer x is functioning properly”.
e) “Computer y is under attack by an
intruder”. are often found in mathematical
assertion, in computer programs, and in
system specifications.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 11 / 1


Predicates
Predicates
These statements are neither true nor
false when the values of the variables are
not specified.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 12 / 1


Predicates
Predicates
These statements are neither true nor
false when the values of the variables are
not specified.
In this section, we will discuss the ways
that propositions can be produced from
such statements.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 12 / 1
Predicates

Predicates
And from the examples above we have the
following definition.

Definition (Predicate)
A predicate is a statement containing variables.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 13 / 1


Predicates
Predicates
From the examples above, the statement
“x is greater than 3”has two parts

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 14 / 1


Predicates
Predicates
From the examples above, the statement
“x is greater than 3”has two parts
a) The first part, is the variable x, which is
the subject of the statement.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 14 / 1


Predicates
Predicates
From the examples above, the statement
“x is greater than 3”has two parts
a) The first part, is the variable x, which is
the subject of the statement.
b) The second part, is the predicate, “is
greater than 3”, which refers to the
property that the subject of the statement
can have.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 14 / 1
Predicates
Predicates
We can denote the statement “x is greater
than 3”by P (x), where P denotes the
predicate “is greater than 3”and x is the
variable.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 15 / 1


Predicates
Predicates
We can denote the statement “x is greater
than 3”by P (x), where P denotes the
predicate “is greater than 3”and x is the
variable.
The statement P (x) is also said to be the
value of the propositional function P at x.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 15 / 1


Predicates
Predicates
Once a value has been assigned to the
variable x, then the statement P (x)
becomes a proposition and has a truth
value.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 16 / 1


Predicates
Predicates
Once a value has been assigned to the
variable x, then the statement P (x)
becomes a proposition and has a truth
value.
Example 1: Let P (x) denote the
statement “x > 3”. What are the truth
values of P (4) and P (2)?
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 16 / 1
Predicates
Predicates
Solution: We obtain the statement P (4)
by setting x = 4 in the statement “x > 3”.
Hence P (4), which is the statement
“4 > 3”is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 17 / 1


Predicates
Predicates
Solution: We obtain the statement P (4)
by setting x = 4 in the statement “x > 3”.
Hence P (4), which is the statement
“4 > 3”is true.
However, P (2) is the statement “2 > 3”, is
false.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 17 / 1
Predicates
Predicates
Example 2: Let A(x) denote the
statement “Computer x is under attack
by an intruder”. Suppose that of the
computers on Mzumbe main campus, only
SOP AM 2 and SOB3 are currently under
attack by intruders. What are the truth
values of A(F ST 1), A(DICT 4),
A(SOB3), A(SOP AM 4), December
A(SOP11,AM 2)?18 / 1
Mbigili L.J (Mzumbe University)Predicate Calculus
2020
Predicates

Predicates
We can also have statements that involve
more than one variable.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 19 / 1


Predicates

Predicates
We can also have statements that involve
more than one variable.
For instance, consider the statement
“x = y + 3”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 19 / 1


Predicates
Predicates
We can denote this statement by Q(x, y),
where x and y are variables and Q is the
predicate.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 20 / 1


Predicates
Predicates
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 the
truth value.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 20 / 1
Predicates

Predicates
Example 3: Let Q(x, y) denote the
statement “x = y + 3”. What are the
truth values of the proposition
Q(1, 2), Q(2, 3), Q(3, 0) and Q(8, 5).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 21 / 1


Predicates
Predicates
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 a variable
representing a network.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 22 / 1


Predicates
Predicates
Continuation........................

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 23 / 1


Predicates
Predicates
Continuation........................
Suppose that computer F ST 1 is connected
to network Mzumbenet, but not
Lumumbanet. What are the values of the
the propositions A(F ST 1, M zumbenet)
and A(F ST 1, Lumumbanet)?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 23 / 1


Predicates
Predicates
Similarly, we can let R(x, y, z) to denote
the statement “x + y = z”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 24 / 1


Predicates
Predicates
Similarly, we can let R(x, y, z) to denote
the statement “x + y = z”.
When values are assigned to the variables
x, y and z, this statement has a truth
value.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 24 / 1


Predicates
Predicates
Similarly, we can let R(x, y, z) to denote
the statement “x + y = z”.
When values are assigned to the variables
x, y and z, this statement has a truth
value.
Example 5: What are the truth values of
the propositions R(1, 2, 3) and R(0, 0, 1)?
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 24 / 1
Predicates
Predicates
In general, a statement involving n
variables x1, x2, . . . , xn can be denoted by
P (x1, x2, . . . , xn).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 25 / 1


Predicates
Predicates
In general, a statement involving n
variables x1, 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.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 25 / 1


Predicates

Predicates
P is also called an n−place predicate or a
n−ary predicate.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 26 / 1


Predicates

Predicates
P is also called an n−place predicate or a
n−ary predicate.
Propositional functions occur frequently in
computer programs.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 26 / 1


Predicates
Predicates
Example 6: Consider the statement
If x > 0 then x := x + 1

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 27 / 1


Predicates
Predicates
Example 6: Consider the statement
If x > 0 then x := x + 1
When this statement is encountered in a
program, the value of the variable x at
that point in the execution of the program
is inserted into P (x), which is “x > 0”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 27 / 1


Predicates
Predicates
If P (x) is true for this value of x, then the
assignment statement x := x + 1 is
executed,so the value of x is increased by 1.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 28 / 1


Predicates
Predicates
If P (x) is true for this value of x, then the
assignment statement x := x + 1 is
executed,so the value of x is increased by 1.
If P (x) is false for this value of x, then the
assignment statement is not executed, so
the value of x is not changed.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 28 / 1


Predicates
Predicates
Predicates are also used in the verification
that computer programs always produce
the desired output when given valid input.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 29 / 1


Predicates
Predicates
Predicates are also used in the verification
that computer programs always produce
the desired output when given valid input.
The statement that describe valid input
are known as Preconditions.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 29 / 1


Predicates
Predicates
Predicates are also used in the verification
that computer programs always produce
the desired output when given valid input.
The statement that describe valid input
are known as Preconditions.
And the conditions that the output should
satisfy when the program has run are
known as Postcondition. December 11, 2020
Mbigili L.J (Mzumbe University)Predicate Calculus 29 / 1
Predicates
Predicates
Example 7: Consider the following
program, designed to interchange(swap)
the values of two variables x and y.
mict : = x
x:=y
y : = mict

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 30 / 1


Predicates
Predicates
Find the predicates that we can use as the
precondition and the postcondition to
verify the correctness of this program.
Then explain how to use them to verify
that for all valid input the program does
what is intended.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 31 / 1


Predicates

Predicates
Solution: For the precondition, we
need to express that x and y have
particular values before we run the
program.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 32 / 1


Predicates

Predicates
So for this precondition we can use the
predicate P (x, y), where P (x, y) is the
statement “x = a and y = b”, where a and
b are the values of x and y before we run
the program.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 33 / 1


Predicates
Predicates
Since we want to verify that the program
swaps the values of x and y for all input
values, for the postcondition we can use
Q(x, y), where Q(x, y) is the statement
“x = b and y = a.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 34 / 1


Predicates

Predicates
To verify that the program always does
what it is supposed to do. Suppose that
the precondition P (x, y) holds.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 35 / 1


Predicates

Predicates
To verify that the program always does
what it is supposed to do. Suppose that
the precondition P (x, y) holds.
That is, we suppose that the statement
“x = a and y = b”is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 35 / 1


Predicates

Predicates
This means that x = a and y = b.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 36 / 1


Predicates

Predicates
This means that x = a and y = b.
The first step of the program mict := x,
assigns the value of x to the variable mict.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 36 / 1


Predicates

Predicates
So after this step we know that
x = a, mict = a and y = b.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 37 / 1


Predicates

Predicates
So after this step we know that
x = a, mict = a and y = b.
After the second step, of the program,
x := y, we know that x = b, mict = a and
y = b.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 37 / 1


Predicates

Predicates
Finally, after the third step, we know that
x = b, mict = a and y = a.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 38 / 1


Predicates

Predicates
Finally, after the third step, we know that
x = b, mict = a and y = a.
Consequently, after this program is run,
the postcondition Q(x, y) holds, that is the
statement x = b and y = a is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 38 / 1


Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 39 / 1
Quantifiers
Quantifiers
When the variables in a propositional
function are assigned values, the resulting
statement becomes a proposition with a
certain truth value.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 40 / 1


Quantifiers
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.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 40 / 1
Quantifiers

Quantifiers
Quantification expresses the extend to
which a predicate is true over the range of
elements.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 41 / 1


Quantifiers

Quantifiers
Quantification expresses the extend to
which a predicate is true over the range of
elements.
In English, the words, all, some, many,
none and few are used in quantification.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 41 / 1


Quantifiers
Quantifiers
Our focus here is on two types of
quantifications namely:

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 42 / 1


Quantifiers
Quantifiers
Our focus here is on two types of
quantifications namely:
1) Universal quantification, which tells us
that a predicate is true for every element
under consideration, and

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 42 / 1


Quantifiers
Quantifiers
Our focus here is on two types of
quantifications namely:
1) Universal quantification, which tells us
that a predicate is true for every element
under consideration, and
2) Existential quantification, which tells
us that there is at least (one or more)
element under consideration for which the
predicate is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 42 / 1
Universal Quantifier
Universal Quantifier
Many mathematical statements assert that
a property is true for all values of a
variable in a particular domain,called the
Domain of Discourse(The Universe
of Discourse), often just referred to as
the Domain.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 43 / 1
Universal Quantifier
Universal Quantifier
Such a statement is expressed using
universal quantification.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 44 / 1


Universal Quantifier
Universal Quantifier
Such a statement is expressed using
universal quantification.
The universal quantification of P (x) for a
specified domain is the proposition that
asserts that P (x) is true for all values of x
in that particular domain.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 44 / 1
Universal Quantifier
Universal Quantifier
The meaning of the universal quantification
of P (x) changes when the domain change.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 45 / 1


Universal Quantifier
Universal Quantifier
The meaning of the universal quantification
of P (x) changes when the domain change.
The domain must always be specified when
a universal quantifier is used, without it,
the universal quantification of a statement
is not defined.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 45 / 1
Universal Quantifier
Definition (Universal Quantification)
The universal quantification of P (x) is the
statement “P (x) for all values of x in the
domain”
The notation ∀xP (x) denotes the universal
quantification of P (x), and ∀ is called the
universal quantifier.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 46 / 1
Universal Quantifier

Universal Quantification
We read ∀xP (x) as “for all xP (x)”or “for
every xP (x)”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 47 / 1


Universal Quantifier

Universal Quantification
We read ∀xP (x) as “for all xP (x)”or “for
every xP (x)”.
An element for which P (x) is false is called
a Counterexample of ∀xP (x).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 47 / 1


Universal Quantifier
Universal Quantifier
Example 8: 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?.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 48 / 1


Universal Quantifier
Universal Quantifier
Example 8: 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: Since P (x) is true for all real
number x, then the quantification ∀xP (x)
is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 48 / 1
Universal Quantifier

Universal Quantifier: Note


Besides For all, For every, universal
quantification can also be expressed using
words such as All of, For each, Given
any, For arbitrary and For any.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 49 / 1


Universal Quantifier
Universal Quantifier
A statement ∀xP (x) is false if and only if
P (x) is not always true for at least or for
some x in the domain.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 50 / 1


Universal Quantifier
Universal Quantifier
A statement ∀xP (x) is false if and only if
P (x) is not always true for at least or for
some x in the domain.
So it is enough to give a counterexample to
the statement ∀xP (x) such that P (x) is
not always true when x is in the domain.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 50 / 1
Universal Quantifier

Universal Quantifier
Example 9: Let Q(x) be the statement
“x < 2”. What is the truth value of the
quantification ∀xP (x), where the domain
consists of all real numbers?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 51 / 1


Universal Quantification

Universal Quantification
Solution: Q(x) is not true for every real
number x, because for instance, Q(3) is
false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 52 / 1


Universal Quantification

Universal Quantification
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.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 52 / 1


Universal Quantification

Universal Quantification
Example 10: Suppose that P (x) is a
statement “x2 > 0”. To show that the
statement ∀xP (x) is false where the
universe of discourse consists of all
integers, we give a counterexample.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 53 / 1


Universal Quantification
Universal Quantification
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
statement
∀xP (x) = P (x1) ∧ P (x2) ∧ . . . ∧ P (xn)
because this conjunction is true if and
only if P (x1), P (x2), . . . , PDecember
(xn) are
Mbigili L.J (Mzumbe University)Predicate Calculus
all
11, 2020 54 / 1
Universal Quantification

Universal Quantification
Example 11: What is the truth value of
∀xP (x), where P (x) is the statement
x2 < 10 and the domain consists of the set
of positive integers not exceeding 4?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 55 / 1


Universal Quantification

Universal Quantification
Example 12: What does the statement
∀xN (x) mean, if N (x) is the “Computer
x is connected to the university
network”and the domain is the set of all
computers on campus?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 56 / 1


Universal Quantification

Universal Quantification
Example 13: (a) What is the truth value
of ∀x(x2 ≥ x) if the domain consists of all
real numbers? (b) What is the truth value
of this statement if the domain consists of
all integers?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 57 / 1


Existential Quantifier

Existential Quantifier
Many mathematical statements assert that
there is an element with certain property.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 58 / 1


Existential Quantifier

Existential Quantifier
Many mathematical statements assert that
there is an element with certain property.
Such statements are expressed using
existential quantification.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 58 / 1


Existential Quantifier

Existential Quantifier
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.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 59 / 1


Existential Quantifier

Definition (Existential Quantification)


The Existential quantification of P (x) is the
proposition
“There exists an element x in the domain such
that P (x)”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 60 / 1


Existential Quantifier

Existential Quantification
We use the notation ∃xP (x) for the
existential quantification of P (x), and ∃ is
called the Existential quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 61 / 1


Existential Quantifier
Existential Quantifier
A domain must be specified when a
statement ∃xP (x) is used.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 62 / 1


Existential Quantifier
Existential Quantifier
A domain must be specified when a
statement ∃xP (x) is used.
Furthermore, the meaning of ∃xP (x)
changes when the domain changes.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 62 / 1


Existential Quantifier
Existential Quantifier
A domain must 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.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 62 / 1
Existential Quantifier

Existential Quantifier
Besides, the word “There exists”, we can
also express existential quantification in
many other ways such as “For some”,
“For at least”, or “There is”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 63 / 1


Existential Quantifier

Existential Quantifier
The existential quantification ∃xP (x) is
read as “There is an x such that
P (x)”OR “There is at least one x such
that P (x)”OR “For some xP (x)”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 64 / 1


Existential Quantifier

Existential Quantifier
Example 14: 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?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 65 / 1


Existential Quantifier

Existential Quantifier
Solution: Because “x > 3”is sometimes
true, for instance, when x = 4, then the
existential quantification of P (x) which is
∃xP (x) is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 66 / 1


Existential Quantifier
Existential Quantifier
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.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 67 / 1


Existential Quantifier
Existential Quantifier
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.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 67 / 1
Existential Quantifier

Existential Quantifier
Example 15: 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?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 68 / 1


Existential Quantifier
Existential Quantifier
When all elements in the domain can be
listed, say x1, x2, . . . , xn, then the
existential quantification ∃xP (x) is the
same as the disjunction
P (x1) ∨ P (x2) ∨ . . . ∨ P (xn)
since this disjunction is true if and only if
at least one of P (x1), (x2), . . . , P (xn) is
true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 69 / 1
Existential Quantifier

Existential Quantifier
Example 16: What is the truth value of
∃xP (x), where P (x) is the statement
“x2 > 10”and the universe of discourse
consists of the set of positive integers not
exceeding 4?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 70 / 1


Existential Quantifier
Existential Quantifier
Solution: Since the domain is {1, 2, 3, 4},
the proposition ∃xP (x) is the same as the
disjunction
P (1) ∨ P (2) ∨ P (3) ∨ P (4)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 71 / 1


Existential Quantifier
Existential Quantifier
Solution: Since the domain is {1, 2, 3, 4},
the proposition ∃xP (x) is the same as the
disjunction
P (1) ∨ P (2) ∨ P (3) ∨ P (4)
Because P (4) is the statement “42 > 10 is
true, it follows that ∃xP (x) is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 71 / 1
Existential Quantifier
Existential Quantifier
The table below summarizes the meaning of the
universal quantifier and existential quantifier.
Statement When True? When False?
∀xP (x) P (x) is T ∀x ∃x for which
P (x) is F
∃xP (x) ∃x for which P (x) is F, ∀x
P (x) is T
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 72 / 1
Other Quantifiers

Other Quantifiers
The quantifiers we have seen so far are the
most important quantifiers in Mathematics
and Computer Science.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 73 / 1


Other Quantifiers

Other Quantifiers
However, there exist some different
quantifiers such as, “There are exactly
two”, “There are no more than
three”, “There are at least 100”and
so on.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 74 / 1


Other Quantifiers

Other Quantifiers
Of these quantifiers, the one that is most
often seen is the Uniqueness
quantifier, denoted by ∃! OR ∃1.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 75 / 1


Other Quantifiers
Other Quantifiers
The notation ∃!xP (x)[Or ∃1xP (x)] states
that “There exists a unique x such that
P (x) is true”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 76 / 1


Other Quantifiers
Other Quantifiers
The notation ∃!xP (x)[Or ∃1xP (x)] states
that “There exists a unique x such that
P (x) is true”.
Other phrases for uniqueness quantification
include “There is exactly one”, “There is
one and only one”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 76 / 1
Other Quantifiers

Other Quantifiers
In some occasion, it is necessary that
uniqueness quantifier be formulated as a
separate concept from existence, albeit
instead requiring the universal quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 77 / 1


Other Quantifiers

Other Quantifiers
The idea is that uniqueness states that
“if any two, not necessarily
different objects in S satisfy the same
particular statement P , then they must
in fact be the same object.”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 78 / 1


Other Quantifiers
Other Quantifiers
Consider the following, symbolic
representation of the uniqueness of an
object x which satisfies P (x).

(∀, x, y ∈ S)[P (x) ∧ P (y) −→ x = y]

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 79 / 1


Other Quantifiers

Other Quantifiers
Finally we note that a proof of a statement
such as (∃!x ∈ S)P (x) is thus usually
divided into two separate proofs:

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 80 / 1


Other Quantifiers

Other Quantifiers
Finally we note that a proof of a statement
such as (∃!x ∈ S)P (x) is thus usually
divided into two separate proofs:
1) Existence: (∃x ∈ S)P (x)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 80 / 1


Other Quantifiers

Other Quantifiers
Finally we note that a proof of a statement
such as (∃!x ∈ S)P (x) is thus usually
divided into two separate proofs:
1) Existence: (∃x ∈ S)P (x)
2) Uniqueness:
(∀, x, y ∈ S)[P (x) ∧ P (y) −→ x = y]

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 80 / 1


Other Quantifiers
Other Quantifiers
For example,One of the axioms defining
the real numbers is the existence of an
additive identity

(∃z ∈ R)(∀x ∈ R)[z + x = x]

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 81 / 1


Other Quantifiers
Other Quantifiers
In fact it follows quickly that such a
“z”must be unique, so we have

(∃z! ∈ R)(∀x ∈ R)[z + x = x] (1)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 82 / 1


Other Quantifiers
Other Quantifiers
In fact it follows quickly that such a
“z”must be unique, so we have

(∃z! ∈ R)(∀x ∈ R)[z + x = x] (1)

To prove (1), we need to prove (1)


existence, and (2) uniqueness.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 82 / 1
Other Quantifiers

Other Quantifiers
In this setting, the existence is an axiom so
there is nothing to prove.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 83 / 1


Other Quantifiers

Other Quantifiers
In this setting, the existence is an axiom so
there is nothing to prove.
We turn then to the uniqueness.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 83 / 1


Other Quantifiers

Other Quantifiers
A proof is best written in prose, but it is
based upon proving that

(∀z1, z2 ∈ R)
[(z1 is an add. identity) ∧ (z2 is an add. ident

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 84 / 1


Other Quantifiers
Other Quantifiers
Now we prove this. Suppose that z1 and z2
are additive identities, that is, they can
stand in for z in (1).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 85 / 1


Other Quantifiers
Other Quantifiers
Now we prove this. Suppose that z1 and z2
are additive identities, that is, they can
stand in for z in (1).
Then under these assumptions, we have
z1 = z2 + z1 (since z2 is an additive identity)
= z1 + z2 (since addition is commutative-o
= z2 (since z1 is an additive identity)
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 85 / 1
Other Quantifiers

Other Quantifiers
This argument showed that if z1 and z2 are
any real numbers which act as additive
identities, then z1 = z2.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 86 / 1


Other Quantifiers

Other Quantifiers
In other words, if there are any, there is in
fact only one.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 87 / 1


Other Quantifiers

Other Quantifiers
In other words, if there are any, there is in
fact only one.
Of course, assuming existence we call that
unique real number zero.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 87 / 1


Other Quantifiers
Other Quantifiers
The distinction between existence and
uniqueness of an object with some property
P is often summarized as follows:

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 88 / 1


Other Quantifiers
Other Quantifiers
The distinction between existence and
uniqueness of an object with some property
P is often summarized as follows:
1) Existence asserts that there is at least one
such object.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 88 / 1


Other Quantifiers
Other Quantifiers
The distinction between existence and
uniqueness of an object with some property
P is often summarized as follows:
1) Existence asserts that there is at least one
such object.
2) Uniqueness asserts that there is at most
one such object.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 88 / 1


Other Quantifiers
Other Quantifiers
The distinction between existence and
uniqueness of an object with some property
P is often summarized as follows:
1) Existence asserts that there is at least one
such object.
2) Uniqueness asserts that there is at most
one such object.

If both hold, then there is exactly one such


object.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 88 / 1
Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
An abbreviated notation is often used to
restrict the domain of a quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 89 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
An abbreviated notation is often used to
restrict the domain of a quantifier.
In this notation, a condition that a variable
must satisfy is included after the quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 89 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Example 17: What do the statements,
∀x < 0(x2 > 0), ∀y 6= 0(y 3 6= 0) and
∃z > 0(z 2 = 2) mean, where the domain in
each case consists of the real numbers?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 90 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Solution: (a) The statement
∀x < 0(x2 > 0), states that for every real
number x with x < 0, x2 > 0.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 91 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Solution: (a) The statement
∀x < 0(x2 > 0), states that for every real
number x with x < 0, x2 > 0.
That is, it states that “The square of a
negative real number is positive”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 91 / 1
Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
This statement is the same as
∀x(x < 0 → x2 > 0).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 92 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
This statement is the same as
∀x(x < 0 → x2 > 0).
Solution: (b) The statement
∀y 6= 0(y 3 6= 0), states that for every real
number y with y 6= 0, we have y 3 6= 0.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 92 / 1
Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
That is, it states that “The cube of every
nonzero real number is nonzero”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 93 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
That is, it states that “The cube of every
nonzero real number is nonzero”.
This statement is equivalent to
∀y(y 6= 0 → y 3 6= 0).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 93 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Solution: (c) Finally, the statement
∃z > 0(z 2 = 2), states that, there exists a
real number z with z > 0, such that
z 2 = 2.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 94 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Solution: (c) Finally, the statement
∃z > 0(z 2 = 2), states that, there exists a
real number z with z > 0, such that
z 2 = 2.
That is, it states that “There is a positive
square root of 2”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 94 / 1
Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
This statement is equivalent to
∃z(z > 0 ∧ z 2 = 2).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 95 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
This statement is equivalent to
∃z(z > 0 ∧ z 2 = 2).
Note that: “The restriction of a
universal quantification is the same as
the universal quantification of a
Conditional statement”
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 95 / 1
Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
On the other hand “The restriction of
an existential quantification is the same
as existential of a Conjunction
statement”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 96 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Example:Consider the following
statements

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 97 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Example:Consider the following
statements
a) All students are intelligent.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 97 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Example:Consider the following
statements
a) All students are intelligent.
b) Some students are intelligent.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 97 / 1


Quantifiers with Restricted
Domains
Quantifiers with Restricted Domains
Example:Consider the following
statements
a) All students are intelligent.
b) Some students are intelligent.
c) No students are intelligent.
Write the statement above using predicates
and quantifiers and hence in symbolic form.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 97 / 1
Precedence of Quantifiers
Precedence of Quantifiers
The quantifiers ∀ and ∃ have higher
precedence than all logical operators from
propositional calculus.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 98 / 1


Precedence of Quantifiers
Precedence of Quantifiers
The quantifiers ∀ and ∃ have higher
precedence than all logical operators from
propositional calculus.
For example: ∀xP (x) ∨ Q(x) is the
disjunction of ∀xP (x) and Q(x).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 98 / 1


Precedence of Quantifiers
Precedence of Quantifiers
The quantifiers ∀ and ∃ have higher
precedence than all logical operators from
propositional calculus.
For example: ∀xP (x) ∨ Q(x) is the
disjunction of ∀xP (x) and Q(x).
In other words, it means (∀xP (x)) ∨ Q(x)
rather than ∀x(P (x) ∨ Q(x)).
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 98 / 1
Binding Variables

Binding Variables
When a quantifier is used on the variable
x, we say that this occurrence of the
variable is Bound.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 99 / 1


Binding Variables

Binding Variables
When a quantifier is used on the variable
x, we say that this occurrence of the
variable is Bound.
An occurrence of a variable that is not
bound by a quantifier is said to be Free.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 99 / 1


Binding Variables
Binding Variables
The part of logical expression to which a
quantifier is applied is called the Scope of
the quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 100 /


Binding Variables
Binding Variables
The part of logical expression to which a
quantifier is applied is called the Scope of
the quantifier.
Consequently, a variable is free if it is
outside the scope of all quantifiers in the
formula that specifies this variable.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 100 /
Binding Variables
Binding Variables
Example 18(a): In the statement
∃x(x + y = 1), the variable x is bound by
the existential quantification ∃x, but the
variable y is free because it is not bound by
a quantifier and no value is assigned to this
variable.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 101 /
Binding Variables
Example 18(b) continuation
Example 18(b): In the statement
∃x(P (x) ∧ Q(x)) ∨ ∀xR(x), all variables
are bound.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 102 /


Binding Variables
Example 18(b) continuation
Example 18(b): In the statement
∃x(P (x) ∧ Q(x)) ∨ ∀xR(x), all variables
are bound.
The scope of the first quantifier ∃x is
expression P (x) ∨ Q(x) and the scope of
the second quantifier ∀x is the expression
R(x).
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 102 /
Binding Variables

Example 18(b) continuation


That is the existential quantification ∃x
binds the variable x in P (x) ∨ Q(x) and
the universal quantification ∀x binds the
variable x in R(x).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 103 /


Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 104 /
Logical Equivalences:Quantifiers
Definition (Logical
Equivalences:Quantifiers)
Statements involving predicates and quantifiers
are logically equivalent if and only if they
have the same truth value no matter which
predicates are substituted into these statements
and which domain of discourse is used for the
variables in these propositional functions.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 105 /
Logical Equivalences involving
Quantifiers
Logical Equivalences involving
Quantifiers
We use the notation A ≡ B to indicate
that two statements A and B involving
predicates and quantifiers are logically
equivalent.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 106 /
Logical Equivalences involving
Quantifiers

Note that
Example 19: Show that
∀x(P (x) ∧ Q(x)) and ∀xP (x) ∧ ∀xQ(x)
are logically equivalent(where the same
domain is used throughout).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 107 /


Logical Equivalences involving
Quantifiers
Note that
This logical equivalence shows that we can
distribute a universal quantifier
over the Conjunction and also
distribute an existential quantifier
over the Disjunction.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 108 /
Logical Equivalences involving
Quantifiers

Note that
However, we cannot distribute a universal
quantifier over a disjunction, nor can we
distribute an existential quantifier over a
Conjunction.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 109 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
To show that these statements are logically
equivalent we must show that they always
take the same truth value no matter what
the predicates P and Q are, and no matter
which domain of discourse is used.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 110 /
Logical Equivalences:Quantifiers
Note that
Thus, we start by Supposing that, we have
particular predicates P and Qwith a
common domain.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 111 /


Logical Equivalences:Quantifiers
Note that
Thus, we start by Supposing that, we have
particular predicates P and Qwith a
common domain.
We can show that ∀x(P (x) ∧ Q(x)) and
∀xP (x) ∧ ∀xQ(x) are logically equivalent
by doing two things.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 111 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
1) We show that if ∀x(P (x) ∧ Q(x)) is true
then ∀xP (x) ∧ ∀xQ(x) is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 112 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
1) We show that if ∀x(P (x) ∧ Q(x)) is true
then ∀xP (x) ∧ ∀xQ(x) is true.
2) And then we show that if
∀xP (x) ∧ ∀xQ(x) is true, then
∀x(P (x) ∧ Q(x)) is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 112 /
Logical Equivalences involving
Quantifiers
Example 19: Solution
So, suppose that ∀x(P (x) ∧ Q(x)) is true.
This means that if a is an element in the
domain, then (P (a) ∧ Q(a)) is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 113 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
So, suppose that ∀x(P (x) ∧ Q(x)) is true.
This means that if a is an element in the
domain, then (P (a) ∧ Q(a)) is true.
Hence P (a) is true and Q(a) is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 113 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
Because P (a) is true and Q(a) is true for
every element in the domain, we can
conclude that ∀xP (x) and ∀xQ(x) are
both true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 114 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
Because P (a) is true and Q(a) is true for
every element in the domain, we can
conclude that ∀xP (x) and ∀xQ(x) are
both true.
This means that ∀xP (x) ∧ ∀xQ(x) is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 114 /
Logical Equivalences involving
Quantifiers
Example 19: Solution
Next, we suppose that ∀xP (x) ∧ ∀xQ(x)
is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 115 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
Next, we suppose that ∀xP (x) ∧ ∀xQ(x)
is true.
It follows that ∀xP (x) is true and ∀xQ(x)
is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 115 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
Hence, if a is in the domain, then P (a) is
true and Q(a) is true[Since P (x) and Q(x)
are both true for all elements in the
domain].

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 116 /


Logical Equivalences involving
Quantifiers
Example 19: Solution
Hence, if a is in the domain, then P (a) is
true and Q(a) is true[Since P (x) and Q(x)
are both true for all elements in the
domain].
It follows that, for all a in the domain,
P (a) ∧ Q(a) is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 116 /
Logical Equivalences involving
Quantifiers
Example 19: Solution
Thus, it follows that ∀x(P (x) ∧ Q(x)) is
true, and hence we are done, and so we can
now conclude that
∀x(P (x) ∧ Q(x)) ≡ ∀xP (x) ∧ ∀xQ(x)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 117 /


Negating Quantified Expressions

Negating Quantified Expressions


We often want to consider the negation of
a quantified expression.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 118 /


Negating Quantified Expressions

Negating Quantified Expressions


We often want to consider the negation of
a quantified expression.
For example: “Every student in your
class has taken a course in foundation
analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 118 /


Negating Quantified Expressions

Negating Quantified Expressions


This statement is a universal quantification
namely, ∀xP (x), where P (x) is the
statement “x has taken a course in
foundation analysis”, and the domain
consists of the students in your class.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 119 /


Negating Quantified Expressions
Negating Quantified Expressions
The negation of this statement is “It is
not the case that, every student in your
class has taken a course in foundation
analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 120 /


Negating Quantified Expressions
Negating Quantified Expressions
The negation of this statement is “It is
not the case that, every student in your
class has taken a course in foundation
analysis”.
This is equivalent to “There is a student
in your class who has not taken a course
in foundation analysis”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 120 /
Negating Quantified Expressions
Negating Quantified Expressions
And this is simply the existential
quantification of the negation of the
original propositional function, namely
∃x¬P (x).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 121 /


Negating Quantified Expressions
Negating Quantified Expressions
And this is simply the existential
quantification of the negation of the
original propositional function, namely
∃x¬P (x).
Symbolically, it can be illustrated as follows

¬∀xP (x) ≡ ∃x¬P (x)


Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 121 /
Negating Quantified Expressions

Negating Quantified Expressions


Question 1: Prove that ¬∀xP (x) and
∃x¬P (x) are logically equivalent.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 122 /


Negating Quantified Expressions

Negating Quantified Expressions


Suppose we wish to negate an existential
quantification, for instance, “There is a
student in this class who has taken a
course of foundations of analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 123 /


Negating Quantified Expressions

Negating Quantified Expressions


This is the existential quantification
∃xQ(x) where Q(x) is the statement
“Student x has taken a course of
foundations of analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 124 /


Negating Quantified Expressions

Negating Quantified Expressions


The negation of this is “It is not the case
that, there is a student in this class who
has taken a course of foundations of
analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 125 /


Negating Quantified Expressions

Negating Quantified Expressions


This is equivalent to “Every(each) student
in this class has not taken a course of
foundations of analysis”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 126 /


Negating Quantified Expressions
Negating Quantified Expressions
This is just a universal quantification of
the negation of the original propositional
function, or phrased in the language of
quantifier as
∀x¬Q(x)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 127 /


Negating Quantified Expressions
Negating Quantified Expressions
This is just a universal quantification of
the negation of the original propositional
function, or phrased in the language of
quantifier as
∀x¬Q(x)
The logical equivalence is illustrated
hereunder
¬∃xQ(x) ≡ ∀x¬Q(x)
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 127 /
Negating Quantified Expressions
Negating Quantified Expressions
Question 2: Show that ¬∃xQ(x) and
∀x¬Q(x) are logically equivalent, no
matter what Q(x) is and what domain is.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 128 /


Negating Quantified Expressions
Negating Quantified Expressions
Question 2: Show that ¬∃xQ(x) and
∀x¬Q(x) are logically equivalent, no
matter what Q(x) is and what domain is.
The rules for negation for quantifiers are
called De Morgan’s laws for
quantifiers(See the table below).
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 128 /
Negating Quantified Expressions

Negating Quantified Expressions


De Morgan’s laws for quantifiers are
extended to the domain with n elements
x1, x2, . . . , xn.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 129 /


Negating Quantified Expressions

Negating Quantified Expressions

Figure: The De Morgan’s Laws for quantifiers

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 130 /


Negating Quantified Expressions
Negating Quantified Expressions
Thus ¬∀xP (x) is the same as

¬(P (x1) ∧ P (x2) ∧ . . . ∧ P (xn))

which is equivalent to

¬P (x1) ∨ ¬P (x2) ∨ . . . ∨ ¬P (xn)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 131 /


Negating Quantified Expressions
Negating Quantified Expressions
Similarly, ¬∃xP (x) is the same as

¬(P (x1) ∨ P (x2) ∨ . . . ∨ P (xn))

which by De Morgan’s laws is equivalent to

¬P (x1) ∧ ¬P (x2) ∧ . . . ∧ ¬P (xn)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 132 /


Negating Quantified Expressions
Negating Quantified Expressions
Example 20: What are the negations of
the statements (a) ∀x(x2 > x and
(b) ∃x(x2 = 2)?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 133 /


Negating Quantified Expressions
Negating Quantified Expressions
Example 20: What are the negations of
the statements (a) ∀x(x2 > x and
(b) ∃x(x2 = 2)?
Example 21: Use De Morgan’s laws for
quantifiers to show that
¬∀x(P (x) → Q(x)) and
∃x(P (x) ∧ ¬Q(x)) are logically equivalent.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 133 /
Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 134 /
Translating from English into
Logical expressions
Translating from English into Logical
expressions
In this section we restrict ourselves to
sentences that can be translated into
logical expressions using quantifiers.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 135 /


Translating from English into
Logical expressions
Translating from English into Logical
expressions
Example 22: Express the statement
“Every student in this class has studied
calculus”using predicates and quantifiers.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 136 /


Translating from English into
Logical expressions
Translating from English into Logical
expressions
Example 22: Express the statement
“Every student in this class has studied
calculus”using predicates and quantifiers.
Solution: We first rewrite the statement
so that we clearly identify the appropriate
Mbigili L.J (Mzumbe University)Predicate Calculus
December 11, 2020 136 /
Translating from English into
Logical expressions
Example 22: Solution
That is “For every student in this class,
that student has studied calculus”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 137 /


Translating from English into
Logical expressions
Example 22: Solution
That is “For every student in this class,
that student has studied calculus”.
Next we introduce a variable x so that our
statement becomes “For every student x
in this class, x has studied calculus”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 137 /
Translating from English into
Logical expressions
Alternatively
We then introduce the predicate C(x),
which is the statement “x has studied
calculus”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 138 /


Translating from English into
Logical expressions
Alternatively
We then introduce the predicate C(x),
which is the statement “x has studied
calculus”.
Consequently, if we consider the domain
for x to consists of the students in the
class, then we can translate our statement
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 138 /
Translating from English into
Logical expressions
Alternatively
However, there are other correct
approaches; different domains of discourse
and other predicates can be used.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 139 /


Translating from English into
Logical expressions
Alternatively
However, there are other correct
approaches; different domains of discourse
and other predicates can be used.
The approach we select depends on the
subsequent reasoning we want to carry out.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 139 /
Translating from English into
Logical expressions

Alternatively
For example, we may be interested in a
wider group of people, than only those in
this class.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 140 /


Translating from English into
Logical expressions
Alternatively
If we change the domain to consist all
people, we will need to express our
statement as
“For every person x, if person x is a
student in this class, then x has studied
calculus”.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 141 /
Translating from English into
Logical expressions
Alternatively
If we introduce S(x) be the statement that
“Person x is in this class”, we see that
our statement can be expressed as
∀x[S(x) → C(x)].

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 142 /


Translating from English into
Logical expressions

Alternatively
We can also use two variable quantifier
Q(x, y) for the statement “student x has
studied subject y”.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 143 /


Translating from English into
Logical expressions
Alternatively
Then we could replace C(x) by
Q(x, calculus) in both approaches to
obtain

∀xQ(x, calculus) OR ∀x[S(x) → Q(x, calculu

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 144 /


Translating from English into
Logical expressions
Alternatively
Example 23: Express the statement (a)
“Some student in this class has visited
Nairobi”(b) “Every student in this class
has visited either Arusha or Nairobi
”using predicates and quantifiers.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 145 /
Translating from English into
Logical expressions
Alternatively
Example 24: Use predicates and
quantifiers to express the system
specifications (a) “Every mail message
larger than one megabyte will be
compressed”and (b) “If a user is active,
at least one network link will be
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 146 /
Contents
1 Predicate Calculus
Introduction
Predicates
Quantifiers
Other Quantifiers
Quantifiers with Restricted Domains
Precedence of Quantifiers
Binding Variables

Logical Equivalences involvingQuantifiers


Negating Quantified Expressions
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 147 /
Nested Quantifiers
Nested Quantifiers
Many of the interesting statements in
mathematics contain more than one
quantifier.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 148 /


Nested Quantifiers
Nested Quantifiers
Many of the interesting statements in
mathematics contain more than one
quantifier.
To illustrate the mechanics of multiply
quantified statements, we will first turn to
a more worldly setting.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 148 /
Nested Quantifiers

Nested Quantifiers
Consider the following sets: M = {Men}
and W = {Women}.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 149 /


Nested Quantifiers
Nested Quantifiers
In other words, M is the set of all men,
and W the set of all women.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 150 /


Nested Quantifiers
Nested Quantifiers
In other words, M is the set of all men,
and W the set of all women.
Consider the statement

{(∀m ∈ M )(∃w ∈ W )[w loves m]} (2)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 150 /


Nested Quantifiers
Nested Quantifiers
Set to English, (2) could be written, “for
every man there exists a woman who
loves him.”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 151 /


Nested Quantifiers
Nested Quantifiers
Set to English, (2) could be written, “for
every man there exists a woman who
loves him.”
So if (2) is true, we can in principle
arbitrarily choose a man m, and then
there is a woman w who loves him.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 151 /
Nested Quantifiers
Nested Quantifiers
It is important that the man m was
quantified first.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 152 /


Nested Quantifiers
Nested Quantifiers
It is important that the man m was
quantified first.
A common syntax that would be used by a
logician or mathematician would be to say
here that, once our choice of a man is
fixed, we can in principle find a woman
who loves him.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 152 /
Nested Quantifiers

Nested Quantifiers
Note that (2) allows that different men
may need different women to love them,
and also that a given man may be loved by
more than one woman.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 153 /


Nested Quantifiers
Nested Quantifiers
Alternatively, consider the statement:

{(∃w ∈ W )(∀m ∈ M )[w loves m]} (3)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 154 /


Nested Quantifiers
Nested Quantifiers
Alternatively, consider the statement:

{(∃w ∈ W )(∀m ∈ M )[w loves m]} (3)

A reasonable English interpretation would


be, “there exists a woman who loves
every man.”
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 154 /
Nested Quantifiers

Nested Quantifiers
In other way, this would read more like,
“there exists a woman such that, for
every man, she loves him.”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 155 /


Nested Quantifiers
Nested Quantifiers
This says something very different from
(2), because that earlier statement does
not assert that we can find a woman who,
herself, loves every man, but that for
each man there is a woman who loves
him.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 156 /
Nested Quantifiers
Nested Quantifiers
We can also consider the statement

{(∀m ∈ M )(∀w ∈ W )[w loves m]} (4)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 157 /


Nested Quantifiers
Nested Quantifiers
We can also consider the statement

{(∀m ∈ M )(∀w ∈ W )[w loves m]} (4)

This can be read, “for every man and


every woman, the woman loves the
man.”
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 157 /
Nested Quantifiers
Nested Quantifiers
In other words, every man is loved by
every woman.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 158 /


Nested Quantifiers
Nested Quantifiers
In other words, every man is loved by
every woman.
In this case we can reverse the order of
quantification:

{(∀w ∈ W )(∀m ∈ M )[w loves m]} (5)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 158 /


Nested Quantifiers
Nested Quantifiers
In fact, if the two quantifiers are the same
type, both universal or both
existential, then the order does not
matter.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 159 /


Nested Quantifiers
Nested Quantifiers
In fact, if the two quantifiers are the same
type, both universal or both
existential, then the order does not
matter.
In the next slides we will be considering
m ∈ M and w ∈ W in all quantifications.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 159 /
Nested Quantifiers

Nested Quantifiers
Thus
∀m∀w[w loves m] ⇔ ∀w∀m[w loves m]
∃m∃w[w loves m] ⇔ ∃w∃m[w loves m]
(6)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 160 /


Nested Quantifiers

Nested Quantifiers
In both representations in the existential
statements, we are stating that “there is
at least one man and one woman such
that she loves him.”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 161 /


Nested Quantifiers

Nested Quantifiers
In fact that above equivalence is also valid
if we replace ∃ with ∃!, though it would
mean then that “there is exactly one man
and exactly one woman such that the
woman loves the man.”

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 162 /


Nested Quantifiers
Nested Quantifiers
Note that in cases where the sets are the
same, we can combine two similar
quantifications into one, as in
{(∀x ∈ R)(∀y ∈ R)[x + y = y + x]}
(7)
⇐⇒ {(∀x, y ∈ R)[x + y = y + x]}

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 163 /


Nested Quantifiers
Nested Quantifiers
Note that in cases where the sets are the
same, we can combine two similar
quantifications into one, as in
{(∀x ∈ R)(∀y ∈ R)[x + y = y + x]}
(7)
⇐⇒ {(∀x, y ∈ R)[x + y = y + x]}
Similarly with existence.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 163 /


Nested Quantifiers

Examples and Proofs


Example 1: Given P (x, y)|x2 ≥ y,
where D ∈ R × R. (a) Find the truth
value of ∃x∀y|P (x, y).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 164 /


Nested Quantifiers

Examples and Proofs


Example 1: Given P (x, y)|x2 ≥ y,
where D ∈ R × R. (a) Find the truth
value of ∃x∀y|P (x, y).
The ∃x(∀y|P (x, y)) is the statement such
that ∃x(∀y|P (x, y)) ≡ ∃x(∀y|x2 ≥ y)

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 164 /


Nested Quantifiers
Examples and Proofs
If ∃x(∀y|x2 ≥ y) is true, then we give an
example of a specific x, for which
∀y|x2 ≥ y = T .

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 165 /


Nested Quantifiers
Examples and Proofs
If ∃x(∀y|x2 ≥ y) is true, then we give an
example of a specific x, for which
∀y|x2 ≥ y = T .
If we choose x = 3, then
∀y|x2 ≥ y ⇔ ∀y|32 ≥ y = F .

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 165 /


Nested Quantifiers
Examples and Proofs
If ∃x(∀y|x2 ≥ y) is true, then we give an
example of a specific x, for which
∀y|x2 ≥ y = T .
If we choose x = 3, then
∀y|x2 ≥ y ⇔ ∀y|32 ≥ y = F .
Thus, the quantification ∃x(∀y|P (x, y)) is
False.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 165 /
Nested Quantifiers

Examples and Proofs


(b) Prove that ∀x∀y|P (x, y) is false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 166 /


Nested Quantifiers

Examples and Proofs


(b) Prove that ∀x∀y|P (x, y) is false.
Proof: Let x be any element of R(fixed
but arbitrary(f.b.a)).

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 166 /


Nested Quantifiers
Examples and Proofs
Now required to prove that ∀y|P (x, y) is
false. That is there exists y ∈ R for which
P (x, y) is false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 167 /


Nested Quantifiers
Examples and Proofs
Now required to prove that ∀y|P (x, y) is
false. That is there exists y ∈ R for which
P (x, y) is false.
Since P (x, y) is the statement that,
x2 ≥ y, x is fixed but arbitrary and y
varies.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 167 /
Nested Quantifiers
Examples and Proofs
Choose y = x2 + 1,then y = x2 + 1 > x2,
so x2 ≥ y is false. Hence, the
quantification ∀x∀y|P (x, y) is false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 168 /


Nested Quantifiers
Examples and Proofs
Choose y = x2 + 1,then y = x2 + 1 > x2,
so x2 ≥ y is false. Hence, the
quantification ∀x∀y|P (x, y) is false.
Example 2: Prove that ∀x∃y|P (x, y),
where P (x, y)|x < y is true. That is for
each fixed x chosen there is a
corresponding
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 168 /
Nested Quantifiers
Examples and Proofs
Proof: (1) Let x be f.b.a. and (2) Prove
that ∃y|x < y is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 169 /


Nested Quantifiers
Examples and Proofs
Proof: (1) Let x be f.b.a. and (2) Prove
that ∃y|x < y is true.
To prove ∃y|x < y is true, its enough to
give an example of the value for y for
which P (x, y) is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 169 /


Nested Quantifiers
Examples and Proofs
Proof: (1) Let x be f.b.a. and (2) Prove
that ∃y|x < y is true.
To prove ∃y|x < y is true, its enough to
give an example of the value for y for
which P (x, y) is true.
Let us choose y = x + 1 so that
y = x + 1 > x is true. Hence
∀x∃y|P (x, y) is true.
Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 169 /
Nested Quantifiers

Examples and Proofs


Example 3: Consider the statement
∀y∀xP (x, y), where P (x, y)|x2 − y ≥ 0.
Find the truth value of the quantification
and prove it.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 170 /


Nested Quantifiers

Examples and Proofs


Example 3: Consider the statement
∀y∀xP (x, y), where P (x, y)|x2 − y ≥ 0.
Find the truth value of the quantification
and prove it.
Claim the statement ∀y∀xP (x, y) is false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 170 /


Nested Quantifiers

Examples and Proofs


Proof: Consider the negation of this
statement.
¬[∀y∀x(x2 − y ≥ 0)] ⇔ ∃y¬∀x[x2 − y ≥ 0]
⇔ ∃y(∃x[x2 − y < 0])

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 171 /


Nested Quantifiers

Examples and Proofs


Now let y = 1 and x = 0, and
P (0, 1)|02 − 1 = −1 < 0 is true.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 172 /


Nested Quantifiers

Examples and Proofs


Now let y = 1 and x = 0, and
P (0, 1)|02 − 1 = −1 < 0 is true.
Since the truth value of
¬[∀y∀x(x2 − y ≥ 0)] is true then
∀y∀x[x2 − y ≥ 0] is false.

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 172 /


Nested Quantifiers
Nested Quantifiers
Example 3: Find the truth values of the
following statements, given that, the
domain of discourse is the set of all real
numbers.

a) ∀x∃y[x = 2y] and (b) ∃y∀x[x = 2y]

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 173 /


Questions?

Mbigili L.J (Mzumbe University)Predicate Calculus December 11, 2020 174 /

You might also like