University of Washington, Bothell
CSS 482: Expert Systems
Winter 2009
Expert System 1: A Circuit Simulation
Assigned: Wednesday, January 21, 2009
Due: Wednesday, January 28, 2009 at midnight
In your first expert system, you will develop a program that simulates logic circuits. A drawing of an example circuit might be:
|
|
In this case, we’re interested in circuits that include AND, OR, XOR, and NOT elements, plus connections (between element output and input), and input and output ports (A–C and D, E, respectively, in the figure). Your task is to develop an expert system in which the circuit structure (logic elements, connections, and ports) is represented as facts and a set of generic rules compute the output of each element or port, given its inputs.
Your approach should proceed in the following stages (we will discuss these in detail in class):
Please submit your program, with documentation (in which you outline your approach, ordered in the steps given above, with the answers to the questions above included) and example runs (which should demonstrate that your code works, using for example Rosen’s circuits “a circuit for a light controlled by two switches” and “the half adder”), to our CollectIt drop box. Your written documentation should be concise, but should allow the reader to understand your design without reference to the code.
Your code should be easy to read and understand. Use consistent indentation. Each file should start with a comment that includes the file name, your name, the date and a summary of the file purpose/contents. Each deftemplate, defrule, etc. should have a useful comment string and comments indicating what each slot means. The gist of your written documentation should be included in comments in your file(s).