CS 484 - Artificial Intelligence
Fall 2007


Loyola College > Department of Computer Science > CS 484 > CS 484 Homework > Homework 3 Additional Problems
  1. Give the initial state, goal test, successor function, and cost function for each of the following. Choose a formulation that is precise enough to be implemented.
    1. You have a program that outputs the message "illegal input record" when fed a certain file of input records. You know that processing of each record is independent of the other records. You want to discover what record is illegal.
    2. You have three jugs, measuring 12 gallons, 8 gallons, and 3 gallons, and a water faucet. You can fill jugs up or empty them out from one to another or onto the ground. You need to measure out exactly one gallon.
  2. Conisder a state space where the start state is number 1 and the successor function for state n returns two states, numbers 2n and 2n +1.
    1. Draw the portion of the state space for states 1 to 15.
    2. Suppose that goal state is 11. List the order in which nodes will be visisted for breath-first search, depth-first limited to a depth of 3 (root is at depth 0), and iterative deepening search.
    3. Would bidirectional search be appropriate for this problem? If so, describe in detail how it would work.
    4. What is the branching factor in each direction of the bidirectional search?
    5. Does the answer to (c) suggest a reformulation of the problem that would allow you to solve the problem of getting form state 1 to a given state with almost no search?
  3. The heuristic path algorithm is a best-first search in which the objective function is f(n) = (2 - w)g(n) + (w)h(n). For what values of w is this algorithm guarenteed to be optimal? (You may assume that h is admissible.) What kind of search does this perform when w = 0 ? When w = 1 ? When w = 2 ?
  4. Solve the cryptarithmetic problem T W O + T W O = F O U R by hand using backtracking, forward checking, and the MRV and least-constraing-value heuristics (provide one solution).
  5. Use the Arc Consistency algorithm to show that arc consistency is able to detect the inconsistency of the partial assignment {CA = red, NM = blue} for the map coloring problem in Lecture 5.