For this assignment, you are to write several variations of resolution theorem provers in Lisp, and a backchaining theorem prover.
Each literal will be of the form: (predicate term ... term) . An atomic term is considered to be a variable; a non-atomic term must be a function of the form: (function term ... term) . A constant is represented as a function of no arguments: (JOHN). Negated literals use a not operator.
The notation does not contain any symbols for quantifiers or logical connectives; these, and the meanings of symbols, are determined implicitly by the positions of elements in the list structures. The input to your program will be clauses written in this syntax. For example, the clauses representing the statements `All hounds howl' and `John has either a cat or a hound' would be written:
( ( (NOT (HOUND X)) (HOWL X) ) ( (HAVE (JOHN) (A)) ) ( (CAT (A)) (HOUND (A)) ) )For simplicity, you may assume that the sets of symbols used as predicate names, function names, and variable names are disjoint in any given problem.
Father(Zeus, Ares) <- Mother(Hera, Ares) <- Father(Ares,Harmonia) <- Parent(x, y) <- Mother(x, y) Parent(x, y) <- Father(x, y) Grandparent(x, y) <- Parent(x, z), Parent(z, y) <- Grandparent(x, Harmonia) [negated question]