This preview shows pages 1–6. Sign up to view the full content.
CSIS1118
oundations of Computer Science
Foundations of Computer Science
redicate Logic
Predicate Logic
Hubert Chan
([O1,O2]; chapters 1.3, 1.4)
1
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document Subjects and Predicates
Do you still remember the definition of propositions?
Is “x > 3” a proposition?
No, unless the value of x is fixed.
Let P(x) denote the statement “x > 3” where P(x) is called a
propositional function
.
P(x) has a truth value once the value of x is fixed.
E.g. P(5) is true; P(1) is false.
P actually refers to the property “is greater than 3” and is called the
predicate
. Note that x is a variable (the subject).
A propositional function can have more than one variable (multi
value predicates).
E.g. Let Q(x, y) denote “x + y > 10”.
2
Then, Q(4, 5) is false; Q(5, 6) is true.
niverse of Discourse
Universe of Discourse
• The collection of values that a variable
x
may take is
called the
universe of discourse
or
domain
.
xample
•
Example
:
“x
is rich”,
x
can refer to people in HK, the world,
movies stars, IT people, …
For the statement
“x
is prime
”,
the universe of
discourse of
x
is the set of all positive integers.
3
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document uantification (Quantifiers)
Quantification (Quantifiers)
Two ways to convert a propositional function, say P(x), into a
roposition
proposition.
• Assign value(s) to variable(s).
• Quantify variable(s):
(x) is true for all possible values of x
niversal Quantification)
P(x) is true for all possible values of x
(Universal Quantification)
These exists at least one value of x such that P(x) is true
(Existential Quantification)
Example:
Let P(x) denote the statement “x has a million dollars”.
P(x) has no truth value and is not a proposition.
P(John) is a proposition
.
x P(x) is a proposition.
“ or all possible values of x (universe of discourse) P(x) is true”
4
for all possible values of x (universe of discourse), P(x) is true
e.g.
“
x P(x)” is false
where domain is people in this room.
Example:
Let P(x) denote the statement “x is married”.
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview. Sign up
to
access the rest of the document.
This note was uploaded on 02/05/2012 for the course FBE BUSI1007 taught by Professor Lin during the Spring '11 term at HKU.
 Spring '11
 Lin

Click to edit the document details