Instructor: Rao Vemuri

Hand in clear, complete, concise answers to the following questions related to logic and deductive inference. Type your answers if at all possible. As usual you can discuss general issues with other students, the TAs, and the instructor, but you must otherwise do your own work. Be sure that your name is at the top of the first page, and all pages are stapled together. Each question should begin at the top of a new page. There is no programming associated with this assignment.

**Valid and Unsatisfiable Sentences in Propositional Logic (Read the book for the definitions of these concepts) (8 points)**

Is each of the following sentences in Propositional Logic*valid*,*unsatisfiable*, or*neither*? Justify your answer.

a. P <-> ¬P

b. P -> (Q -> P)

c. ((P ^ Q) -> R) -> (Q -> (P -> R))

d. ((P -> Q) ^ ¬P) -> ¬Q)

**Soundness and Completeness (Read the book for the definitions of these concepts) (8 points)**

Abduction is an inference rule that
infers *P* from *P* -> *Q* and *Q*.

a.
Prove whether or not abduction is a *sound* rule of inference for
Propositional Logic.

b.
Prove whether or not abduction is a *complete* rule of inference
for Propositional Logic.

**Translation from English to First-Order Logic (8 points)**

Problem 7.2, parts (a), (b), (g), and Problem 7.5 in the textbook. Use only the
predicates *Student(x)*, *Takes(x,y)* meaning student *x* takes
course *y*, *Fails(x,y)* meaning student *x* fails course *y*,
*Vegetarian(x)*, *Likes(x,y)* meaning person *x* likes person *y*,
*Woman(x)*, *Man(x)*, *German(x)*, *Language(x)*, and *Speaks(x,l)*
meaning person *x* speaks language *l*. You may also use the equality
predicate, = (see page 193). You may *not* use the uniqueness quantifier,
E! (see page 196).

Suggested
Solution

(a) Not
all students take both history and biology

~A(x)
Student (x) => (Takes (H, x) ^ Takes (B, x) )

(b)
Only one student failed history

E(x)
Student (x) ^ Fails (x, H) ^ A(y)
Student (y) ^ Fails (x, H) => x = y

(g)
There is a woman who likes
all men who are not vegetarians

E(x)
Woman (x) ^ A(y) Man (y) ^ ~Vegetarian (y) => Likes (x, y)

Problem
7.5. All Germans speak the same language.

A(x, y,
l) German (x) ^ German (y) ^ Speaks (x, l) => Speaks (y,l)

**Unification (8 points)**

For each of the following pairs of
atomic sentences, give the most general unifier, if it exists. If none exists,
explain why. *w*, *x*, *y* and *z* are variable symbols, *A*
and *B* are constant symbols, *F* and *G* are function symbols,
and *P* is a predicate symbol.

a.
*P(y, y)* and *P(A, B)*, *Not unifiable *

b.
*P(x, x)* and *P(A, y);
( A/y) , A/x) *Substitute A for x
first and then A for y

c.
*P(G(w), w, y)* and *P(z, F(A), F(B)); (G(F(A))/z, F(A)/w, F(B)/y)*

d.
*P(w, G(y), w)* and *P(x, x, G(A)); ( A/y , G(A)/w, G(A)/x) is one possibility*

**Deductive Inference in First-Order Logic (18 points)**

The Oxford don Charles Dodgson (aka
Lewis Carroll) is famous not only for his novel *Alice in Wonderland* but
also for his textbook *Symbolic Logic*. Here is one of the problems from
that book. Consider the following premises:

1. Colored flowers are always scented. A(x) C (x) => S (x) à A(x) ~C (x) V S(x) à ~C(x) V S(x)

2. I dislike flowers that are not grown in the open air. A(y) ~G(y) => D (y) à A(y) G(y) V D(y) à G(y) V D(y)

3. No flowers grown in the open air are colorless. A(z) ~G(z) => ~C (z) à A(z) G(z) V ~C(z) à G(z) V ~C(z)

and the query:

4. Do I dislike all flowers that are not scented? A(w) ~S (w) ^ D(w) => True

a.
Write a set of wffs in FOL representing the four English sentences
above. Use the predicates *C(x)* meaning *x* is colored, *D(x)*
meaning I dislike *x*, *G(x)* meaning *x* is grown in the open
air, and *S(x)* meaning *x* is scented.

b. Convert your sentences in (a) into Conjunction Normal Form (CNF).

c. Use the Resolution Refutation method to prove the query is true given the three premises. Your proof should look like the ones in Figures 9.6 and 9.7 in the textbook. Be sure to include the most general unifiers used at each step as shown in these examples.

Department of Computer Science

University of California at Davis

Davis, CA 95616-8562

Page last modified on 1/20/2003