L3 Predicate Logic PDF
L3 Predicate Logic PDF
Discrete Mathematics
Predicate Logic
SAHAR SELIM
2
Agenda
Convention:
Lowercase variables x, y, z... denote objects/entities.
Uppercase variables P, Q, R… denote propositional functions (predicates).
Keep in mind that the result of applying a predicate P to an object x is
the proposition P(x).
But the predicate P itself (e.g. P=“is sleeping”) is not a proposition (not a
complete sentence).
E.g. if P(x) = “x is a prime number”,
P(3) is the proposition “3 is a prime number.”
Quantifiers
In English, the words all, some, many, none, and few are used in
quantifications.
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.
It describes the values of a variable that make the predicate true. E.g. ∃x
P(x)
Domain or universe: range of values of a variable (sometimes implicit)
Example:
Let the u.d. of x be parking spaces at Cairo University.
Let P(x) be the predicate “x is full.”
Then the universal quantification of P(x), ∀x P(x), is the proposition:
“All parking spaces at CU are full.”
i.e., “Every parking space at CU is full.”
i.e., “For each parking space at CU, that space is full.”
Example:
Let the u.d. of x be parking spaces at CU.
Let P(x) be the predicate “x is full.”
Then the existential quantification of P(x), ∃x P(x), is the
proposition:
“Some parking space at CU is full.”
“There is a parking space at CU that is full.”
“At least one parking space at CU is full.”
Domain integers:
Using implications:
The cube of all negative integers is negative.
∀x (x < 0) →(x3 < 0)
Expressing sums :
n
∀n (Σ i = n(n+1)/2)
i=1
Operator Precedence
∀,∃ 1
¬ 2
∧ 3
∨ 4
→ 5
↔ 6
Sahar Selim MATH211 Lecture 3 | Predicate Logic
19
Precedence of Quantifiers
∃x Q( x, y )
∃x (P( x) ∨ Q( x) ) ∧ ∀x(R( x) )
10 MINUTES
BREAK
33
Extra Questions
Inference Rules