CISC 404/604
Homework 4 Solutions
1a. To show
∃
z
∀
xP
(
x,z,f
(
x,z
))
⇒ ∃
z
∀
x
∃
yP
(
x,z,y
) is valid using resolution.
..
Negate:
¬
(
∃
z
∀
xP
(
x,z,f
(
x,z
))
⇒ ∃
z
∀
x
∃
yP
(
x,z,y
))
Convert to prenex:
∃
z
1
∀
z
2
∃
x
2
∀
y
∀
x
1
¬
(
P
(
x
1
,z
1
,f
(
x
1
,z
1
))
⇒
P
(
x
2
,z
2
,y
))
Skolemize:
∀
z
2
∀
y
∀
x
1
¬
(
P
(
x
1
,a,f
(
x
1
,a
))
⇒
P
(
g
(
z
2
)
,z
2
,y
))
Drop quantiﬁers:
¬
(
P
(
x
1
,a,f
(
x
1
,a
))
⇒
P
(
g
(
z
2
)
,z
2
,y
))
Convert to CNF:
{
[
P
(
x,a,f
(
x,a
))]
,
[
¬
P
(
g
(
z
)
,z,y
)]
}
Resolution/Uniﬁcation:
L
=
{
[
P
(
x,a,f
(
x,a
))]
,
[
¬
P
(
g
(
z
)
,z,y
)]
}
sub
= [
x

g
(
z
)]
L
sub
=
{
[
P
(
g
(
z
)
,a,f
(
g
(
a
)
,a
))]
,
[
¬
P
(
g
(
z
)
,z,y
)]
}
sub
= [
x

g
(
z
)]
,
[
z

a
]
L
sub
=
{
[
P
(
g
(
a
)
,a,f
(
g
(
a
)
,a
))]
,
[
¬
P
(
g
(
a
)
,a,y
)]
}
sub
= [
x

g
(
z
)]
,
[
z

a
]
,
[
y

f
(
g
(
a
)
,a
)]
L
sub
=
{
[
P
(
g
(
a
)
,a,f
(
g
(
a
)
,a
))]
,
[
¬
P
(
g
(
a
)
,a,f
(
g
(
a
)
,a
))]
}
[ ] (by resolution)