CSC 550: Introduction to Artificial Intelligence
CSC 650: Advanced Artificial Intelligence
Spring 2003

HW6: Neural Nets


  1. Consider the following (normalized) perceptron, with 3 input nodes and a single output node.
    Perceptron

    1. What function is computed by this perceptron? That is, for what input patterns does this perceptron fire?

    2. Similar to the examples from class, train this perceptron (with initial weights as shown here) to compute the OR function on three inputs. When the final weights are determined, the perceptron should fire as long as any of the three inputs is a 1. Be sure to intermediate steps in going from the initial weights to the final weights.


  2. In class, we trained a backpropagation network to predict a person's political affiliation based on survey data. For this assignment, you are to similarly train a backpropagation network to recommend potential majors for students. Your network will need to choose from at least three majors (with one output node per major). You will need to design a survey with at least five questions that will identify characteristics that recommend one major or another. Questions might refer to the person's personality, interests, aptitudes and/or lifestyle goals.

    To train and test your network, you will need to give the survey to at least three people per major. One person per major will be reserved to test the network once it is trained. The rest will be used to train the network, using the applet from homepage.stts.edu/~gunawan/others/bpnnjava/TAMenu.html.

    You will need to turn in your survey data, a picture of the trained network, and the classification of each person (both the training examples and test examples).

  3. Consider the following Hopfield net, where active nodes are drawn as shaded circles while inactive nodes are not shaded.

    1. Starting from this state, draw a sequence of states obtained by performing parallel relaxation. Reminder: a node should become active when the sum of the weights from its active neighbors exceeds 0, and should likewise become inactive when the sum is below 0. Parallel relaxation repeatedly finds an invalid node (either an inactive node that should be active, or vice versa) and toggles it. The process terminates when there are no invalid nodes in the net, i.e., it has reached a stable state.

    2. Is there more than one stable state reachable from this start state? Justify your answer.

    3. Draw all of the stable states of this particular Hopfield network? How did you determine this?

    4. Implement this Hopfield net as a Scheme structure (similar to the Hopfield net defined in hopfieldBFS.scm. Verify your answers to the above questions using the relax function defined in that same file.