Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Section 1.5 and 1.6
Predicates and Quantifiers
Vocabulary
•
•
•
•
•
•
•
Predicate
Domain
Universal Quantifier
Existential Quantifier
Counterexample
Free variable
Bound variable
Activity 1
• Define:
– Proposition
• A statement that can be identified as true or
false but not both.
– Predicate
• A statement whose truth value is a function
of one or more variables.
In the first two weeks
• So far we have looked at :
– the concept of proposition statements
– Several common operators/connectives
¬
But that isn’t always enough
• We talked about the fact that not all
sentences are statements:
He is the vice president.
x+y>10
• The true or false nature of these sentences
depends on which values are bound into
the variables (he, x, and y)
But that isn’t always enough
• Similarly, suppose we know:
– Every computer connected to the university
network is functioning properly.
• No rules of propositional logic allow us to
conclude that
– This laptop is functioning properly
We need more
• Thus, the next couple of sections introduce
another form (a more powerful form) of
logic that helps us with these deficiencies.
• This type of logic is called predicate logic
and is built on the idea of allowing us to
write statements that indicate a quantity.
The Logic of Quantified Statements
• A predicate is a sentence that contains a
finite number of variables and becomes a
statement when specific values are
substituted for the variables.
– “He is the vice president” is a sentence
– It becomes a predicate statement when
• he=Mike Pence
• he=Avery Johnson
• he=Ben Schafer
The Logic of Quantified Statements
• The domain of a predicate variable is the
set of all values that may be substituted in
place of the variable.
• What is the domain of “he”
– The domain for he in the sentence “He is the
vice president” is the set of all humans.
The Logic of Quantified Statements
• 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 when they are
substituted for x.
• The truth set of P(x) is denoted:
{ x D | P(x) }
Activity #2
• Let P(x) denote the statement “x+2>5”
– What are the truth values of P(4), P(2) and
P(3)?
– P(4) means “4+2>5” and that is true
– P(2) means “2+2>5” and that is false
– P(3) means “3+2>5” and that is false
Example
• Let P(x) denote the statement “x+2>5”
– Let the domain of x be Z (the set of all integers)
– Then the truth set is {x Z | x>3 }
Questions??
Quantifiers
• Quantifiers are words that refer to
quantities such as “some” or “all” and tell
for how many elements a given predicate is
true.
• In predicate logic we focus on two
quantifiers:
The Universal Quantifier
• The symbol is read as “for all”
• Let Q(x) be a predicate and D the domain of
x. A universal statement is a statement of
the form
– x D, Q(x)
• For all x who are human beings, x is mortal.
• human beings h, h is vice president.
The Universal Quantifier
• A universal statement is a statement of the
form:
– x D, Q(x)
• This statement is defined to be true if and
only if Q(x) is true for every x.
• This statement is defined to be false if for at
least one value of x exists such that Q(x) is
false. X is then called a counterexample.
The Universal Quantifier
• Assume that x1, x2, x3… xn are EVERY x
in the set D.
• Then:
• x D, Q(x)
• Is the same as saying
– Q(x1) Q(x2) Q(x3) … Q(xn)
The Existential Quantifier
• The symbol is read as “there exists”
• Let Q(x) be a predicate and D the domain of
x. An existential statement is a statement of
the form
– x D, Q(x)
• There exists an integer x such that x*2 = x.
• There exists an integer x such that x+1 = x.
The Existential Quantifier
• An existential statement is a statement of
the form:
– x D, Q(x)
• This statement is defined to be true if and
only if Q(x) is true for at least one value of
x in D.
• This statement is defined to be false if it is
false for all x in D.
The Existential Quantifier
• Assume that x1, x2, x3… xn are EVERY x
in the set D.
• Then:
– x D, Q(x)
• Is the same as saying
– Q(x1) Q(x2) Q(x3) … Q(xn)
Activity #3
• How would you prove that
x D, Q(x) is true
x D, Q(x) is false
x D, Q(x) is true
x D, Q(x) is false
Activity #4
•
•
•
•
Write down a true universal statement
Write down a false universal statement
Write down a true existential statement
Write down a false existential statement