Subsection 6.1.4 Multiply Nested Quantifiers
We’ve already seen a lot of examples that exploit multiply nested quantifiers. But we’ll do a few more here for practice.
When you use multiple quantifiers, keep the following things in mind:
If the quantifiers are the same, it doesn’t matter what order you write them in.
If they are different, it does matter. In particular:
∃x (∀y (P(x, y)) means that there must be at least one x such that P(x, y) holds for every y.
∀y (∃x (P(x, y)) means that there may be a different x for each y.
Exercises Exercises
1.
We want to encode the fact that any color that isn’t black has a darker version. To say this precisely, we need to exploit some terminology that is standard in describing colors:
Hue: Where the color is on the color wheel. Hues include red, blue, green, and yellow.
Brightness (also called value): The amount of light. 100 is maximum (i.e., white). 0 is none (i.e., black).
Saturation: The purity of the color. Think of low saturation as being greyer than high saturation.
Define one predicate:
Color(x): True if x is a color.
And define these functions, which are defined for colors:
hue(x): The hue of x.
brightness(x): The brightness of x. White will have 100 as its value. Black will have 0.
saturation(x): The saturation of x. Clear colors will have 100 as their value. Greyer colors will have lower values.
Which (one or more) of the following logical expressions encodes our claim?
I. ∀x ((Color(x) ∧ (brightness(x) ≠ 0)) → ∃y (Color(y) ∧ (hue(y) = hue(x)) ∧
(saturation(y) = saturation(x)) ∧
(brightness(y) < brightness(x))))
II. ∀x ((Color(x) ∧ (brightness(x) = 0)) → ¬∃y (Color(y) ∧ (hue(y) = hue(x)) ∧
(saturation(y) = saturation(x)) ∧
(brightness(y) < brightness(x))))
III. ∃x (Color(x) ∧ ∀y (Color(y) → ((hue(y) = hue(x)) ∧ (saturation(y) = saturation(x)) ∧ (brightness(y) > brightness(x)))))
Just I.
Just II.
Just III.
Just I and II.
Just II and III.
2.
Suppose that we want to encode the following definition:
Anything anyone eats and isn’t killed by is food.
Define: Food(x): True if x is a food.
Eats(x, y) True if x eats y.
KilledBy(x, y): True if x is killed by y.
Consider the following statements:
I. ∀x ((∃y (Eats(y, x) ∧ ¬KilledBy(y, x))) → Food(x))
II. ∀x (∃y ((Eats(y, x) ∧ ¬KilledBy(y, x)) ∨ Food(x)))
III. ∀x (∀y ((¬Eats(y, x) ∨ KilledBy(y, x)) ∨ Food(x)))
Which (one or more) of those statements corresponds to our definition of food?
Just I.
Just II.
Just III.
I and II.
II and III.
3.
We want to encode a policy of our bank: Every loan without collateral has at least two signers. Define:
Loan(x): True if x is a loan.
Collat(x): True if there is collateral for x.
Signer(x, y): True if x signed y.
Which (one or more) of the following logical expressions encodes our claim?
I. ¬∃x (Loan(x) ∧ Collat(x) ∧ (∃y, z (Signer(y, x) ∧ Signer(z, x) ∧ (y ≠ z))))
II. ∀x ((Loan(x) ∧ ¬Collat(x)) → (∃y, z (Signer(y, x) ∧ Signer(z, x) ∧ (y ≠ z))))
III. ∃y, z (∃x (Loan(x) ∧ ¬Collat(x) ∧ Signer(y, x) ∧ Signer(z, x) ∧ (y ≠ z)))
Just I.
Just II.
Just III.
I and II.
II and III.
4.
Define:
Loan(x): True if x is a loan.
Collat(x): True if there is collateral for x.
Signer(x, y): True if x signed y.
Match each logical expression:
∃x (∀y (Loan(y) → Signer(x, y)))
∀x (∀y (Signer(x, y) → Loan(y)))
∀x (Loan(x) → ∃y (Signer(x, y)))
∃x (∀y (¬Signer(x, y) ∨ ¬Loan(y)))
∀x (∃y (Loan(y) ∧ Signer(x, y)))
∃x (¬∃y (Loan(x) ∧ Signer(y, x)))
To its corresponding English sentence:
There’s at least one unsigned loan.
There’s someone who has signed every loan.
There’s no one who hasn’t signed a loan.
The only signed things are loans.
All loans have been signed.
There’s someone who hasn’t signed any loans.
x (y (Loan(y) Signer(x, y))) There’s someone who has signed every loan.
x (y (Signer(x, y) Loan(y))) The only signed things are loans.
x (Loan(x) y (Signer(y, x))) All loans have been signed.
x (y (Signer(x, y) Loan(y))) There’s someone who hasn’t signed any loans.
x (y (Loan(y) Signer(x, y))) There’s no one who hasn’t signed a loan.
x (y (Loan(x) Signer(y, x))) There’s at least one unsigned loan.
5.
We want to encode the claim that no one likes anyone who doesn’t tell the truth. Define:
Likes(x, y): True if x likes y.
TruthTeller(x): True if x is a truth teller.
Which (one or more) of the following logical expressions encodes our claim?
I. ∀x (∀y ((¬TruthTeller(y) → ¬Likes(x, y)))
II. ∀x (¬∃y (¬TruthTeller(y) ∧ Likes(x, y)))
III. ¬∃x (∃y (¬TruthTeller(y) ∧ Likes(x, y)))
Just I.
Just II.
Just III.
Just I and III.
All three.