HOMEWORK 8
Our language L
Throughout this assignment, we will work with the following
first-order lambda calculus. The notation is slightly different from
that of Manning 2005 because we are going to use it to query a live
database using the wonderful Python NLTK semantic module
(documentation).
-
Type Ind expressions:
bart, lisa, maggie,
marge, homer, burns
-
Type Ind variables:
x, y, z
-
Type <Ind → Bool> expressions:
simpson, child, parent,
boss, female, male,
bald, musical, student,
skateboarder
- Type <Ind → <Ind → Bool>> expressions:
teases, admires, telephoned
- Functional application:
If φ is an expression of type <Indn → Bool>, where
Indn is an n-ary sequence
of Ind-types, and
ψ1...ψn is a sequence of Ind-type
expressions, then (φ(ψ1,...,ψn))
is an expression of type Bool.
- Lambda abstraction: If φ is an expression of type b and χ is an variable of type Ind,
then (\χ .φ) is an expression of type <Ind → b>.
-
Equality: If φ and ψ are expressions of type a,
then (φ = ψ) is an expression of
type Bool.
-
Boolean negation: If φ is an expression of type Bool,
then -φ is an expression of type Bool.
-
Boolean combinations: If φ and ψ are expressions of type Bool, then (φ & ψ),
(φ | ψ), (φ -> ψ), and (φ <-> ψ) are expressions of type Bool.
-
Quantification: If φ is an expression of type Bool and χ is an variable of type Ind,
then (exists χ.φ) and (all χ.φ) are expressions of type Bool.
Thus, with the above definition, we have formulae like these:
child(bart)
parent(lisa)
teases(lisa, y)
(\x .parent(x))
(\x .-parent(homer))
(\y .(\x .admires(x, y)))
(exists x.(parent(bart) -> -child(x)))
The syntax is pretty picky. We recommend paying close attention to
bracketing and other details. Some outer brackets can be safely left
off, but not all the standard association conventions are
implemented.
Our model
We have specified a model for the above language, but we are not going to show it
to you in full. Rather, we're asking you to use the above language to query it.
We have also specified an assignment function g that
provides values for the
variables x, y, z. We aren't going to show
you that either, but here is a hint: it assigns a different entity to
each variable.
Query interface
Interpretation: {{ interpretation }}
Questions (1 point each)
- Provide a formula that will answer the question of
whether Maggie is musical in our model, and provide the return value
as well.
- Provide a formula that answers the question of whether everyone is
a Simpson in our model, and provide the return value as well.
- Figure out who g(x) is. (That is, figure out who our
variable assignment g maps the variable x to.)
Provide a formula that answers this question.
- Use the lambda operator to specify the property of being
a parent or a child. Provide your lambda expression and its
interpretation in the model (you can copy out the return value).
- Provide a formula that answers the question of who
admires Lisa in our model. (Hint: the return value should be a
function from individuals to truth values.)
- Provide a formula that corresponds to the sentence No
one is a parent and a boss, and provide the return value as well.
- Our negation operator - is boolean in the sense
that it applies only to expressions of type Bool (and yields
expressions of the same type). This is unfortunate from the
perspective of natural language, since sentential negations are rare
and marked cross-linguistically. We can remedy this with lambdas,
though. Provide an <Ind → Bool>-typed lambda
expression that corresponds to the property of being not bald.
- Verbs like telephone are transitive in the
sense that they typically have direct objects (Bart telephoned
Lisa), but they can also be used intransitively (Bart
telephoned), where they have roughly the sense of ‘telephoned
someone’. Use lambdas and the existential quantifier to create an
intransitive version of telephoned. What set of entities does
this function pick out (i.e., which set of entities does it map to
True?)
- There are two readings of Everyone admires someone, one
where the subject takes wide scope and one where the direct object
takes wide scope. Provide formulae corresponding to each of these two
readings and give their interpretations in our model.
- Repeat the previous problem for Everyone telephoned
someone.
- [extra credit, up to 2 points] What is the general logical
relationship between the two translations you arrived at for problem
10? (The same relationship holds for problem 9.) In light of this
relationship, if you were limited to being able to express only one of
the two scopal orderings, which would you choose, and why?