This week, we continue our work with Prolog using Learn Prolog Now! and SWI Prolog.
As one would imagine, Prolog supports recursion, lists and arithmetic.
Do the following exercises.
Does Prolog implement a version of generalized modus ponens (i.e., modus ponens with variables and instatiation)? If so, demonstrate how it’s done; if not, explain why not. If it doesn’t, can you implement one? Why or why not?
Be sure that you can explain how you built your system and how Prolog does recursion.
Save your program in lab_1.pl
.
Here’s one last logic proof, to be done on paper rather than in Prolog.
Do the following exercises.
Consider the following situation in the blocks world:
Given the (separate) facts that:
Write these facts in FOL and use resolution/unification to prove that A is above the table.
Save your proof in lab_2.txt
or as an image of a
hand-written solution.
We will grade your work according to the following criteria:
See the policies page for lab due-dates and times.