

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


1. (50 pts total, 5 pts each) Try it Yourselves. Prove that the unicorn is magical.
If the unicorn is mythical, then it is immortal, but if it is not mythical, then it is a mortal mammal. If the unicorn is either immortal or a mammal, then it is horned. The unicorn is magical if it is horned.
Use these propositional variables:
Y = unicorn is m Y thical R = unicorn is mo R tal M = unicorn is a ma M mal H = unicorn is H orned G = unicorn is ma G ical
1.a. Convert the English into propositional logic implicative form and conjunctive normal form (CNF). The first one is done for you as an example. (Note: “immortal” means “not mortal.”)
1.a.1. If the unicorn is mYthical, then it is not moRtal.
S1: Implicative Y => ¬ R. CNF ( ¬ Y ˅ ¬ R ).
1.a.2. If the unicorn is not mYthical, then it is moRtal.
S2: Implicative ¬ Y => R. CNF ( Y ˅ R ).
1.a.3. If the unicorn is not mYthical, then it is a maMmal.
S3: Implicative ¬ Y => M. CNF ( Y ˅ M ).
1.a.4. If the unicorn is not moRtal, then it is Horned.
S4: Implicative ¬ R => H. CNF ( R ˅ H ).
1.a.5. If the unicorn is a maMmal, then it is Horned.
S5: Implicative M => H. CNF ( ¬ M ˅ H ).
1.a.6. The unicorn is maGical if it is Horned.
S6: Implicative H => G. CNF ( ¬ H ˅ G ).
It is OK not to put the parentheses around the CNF clauses.
This sentence means the same as, “If the unicorn is Horned, then it is maGical.”
1.b. (25 pts total, 5 pts each) Resolution Theorem Proving. Use the conjunctive normal form (CNF) expressions from 1.a above to prove that the unicorn is magical. The first and last steps are done for you.
1.b.1. The negated goal is S7.
S7: ( ¬ G ).
1.b.2. Resolve S6 and S7 to give S8.
S8: ( ¬ H ).
1.b.3. Resolve S5 and S8 to give S9.
S9: ( ¬ M ).
1.b.4. Resolve S4 and S8 to give S10.
S10: ( R ).
1.b.5. Resolve S3 and S9 to give S11.
S11: ( Y ).
1.b.6. Resolve S1 and S11 to give S12.
S12: ( ¬ R ).
1.b.7. Resolve S10 and S12 to give the empty clause, thus proving the goal sentence is true.
S13: ( ).
2. (25 pts total, 5 pts each) English to logic translation. Fill in each blank below with Y (= Yes) or N (= No) depending on whether the logic expression correctly expresses the English.
2a. N “All men are mortal.” ∀x Man(x) ∧ Mortal(x)
2b. Y “For every quiz, there is a student who got 100 on it.” ∀q∃s Quiz(q) ⇒ [ Student(s) ∧ Got100(s, q) ]
2c. N “Every student got 100 on every quiz.” ∀s∃q Student(s) ⇒ [ Quiz(q) ∧ Got100(s, q) ]
2d. Y “Everyone has a favorite food.”
Here you will get full credit if you do the resolution steps correctly based on your answers for the two resolved sentences (even if those sentences were not correct). I.e., this question asks only that you do the resolution step correctly, regardless of content.
∀x Man(x) => Mortal(x) “Everything is a man and is mortal.”
∀s∀q [ Student(s) ∧ Quiz(q) ] ⇒ Got100(s, q) “Every student got 100 on some quiz.”