This assignment is due by Thursday, 19 March, at 11:50 p.m.. This is both the first and final deadline; it will not be possible to submit the assignment after the Thursday, 19 March, 11:50 p.m. deadline. See the turn-in page (last modified on 2015 February 7) for information about turning in your assignment.
Propositional reasoning over a knowledge base can be used to answer questions about topics covered by the knowledge base. This assignment develops a simple propositional reasoner capable of answering questions related to a knowledge base.
Write a Java class that answers questions asked against a knowledge base and
and interpretation for the knowledge base. The class should implement the
PropositionalReasoner
interface defined in the file
/export/home/class/mucs520/pa3/PropositionalReasoner.java.
PropositionalReasoner
interface defines the method
PropositionalDefiniteClause [] answer(PropositionalDefiniteClause.Atom... query);
In addition to implementing the answer()
method, the class implementing the
PropositionalReasoner
interface should also implement a constructor
accepting a knowledge base and an interpretation for the knowledge base. The
knowledge base and interpretation are to be used to answer questions asked of
the knowledge base by answer()
method calls.
answer()
method is a propositional definite clause to
be determined relative to the knowledge base and interpretation passed into the
reasoner when constructed.
answer()
method follows from the knowledge
base and interpretation associated with the reasoner, then answer()
should
return the sequence of steps used to prove the question. Otherwise answer()
should return null
.
$ javac -Xlint -cp /export/home/class/mucs520/pa3/pa3.jar:. java-source-files
Here are some suggestions for writing the reasoner code:
$ java -cp /export/home/class/mucs520/pa3/pa3.jar:. main
in the directory containing your class files. The jar file can be found in the
assignment directory /export/home/class/mucs520/pa3
, or you may have a copy stashed elsewhere. If
you do make a copy, make sure you keep it up-to-date with the copy in the
assignment directory.