CSE 473 - Artificial Intelligence - Autumn 2011

Written Assignment 1: Search and CSPs

Due Date: Due Mon Oct 24, 9:30am in class or through the online dropbox.

Problem 1: Word Ladder [25 points]

Wikipedia describes the rules for the word game Word Ladder as:

The player is given a start word and an end word(of equal length). In order to win the game, the player must change the start word into the end word progressively, creating an existing word at each step. Each step consists of replacing a single letter. For example, the following is a solution to the Word Ladder puzzle between words "Cold" and "Warm".

COLD -> CORD -> CARD -> WARD -> WARM

A. [10pts] Formulate the problem of solving word ladders as a search problem.

B. [10pts] Consider a restriction where the words can only use the first five letters (a-e). Draw the search graph for coverting "ad" to "be". This page may be helpful.

C. [5pts] Would you prefer to use BFS, DFS, or ID to solve the full problem (with no letter restrictions)? Briefly motivate your choice.

Problem 2: Admissibility [12 points]

Consider a search problem like the Bucharest travel problem in the lectures and text book: nodes correspond to locations on a map and edge costs correspond to distances. Let n.x and n.y be the coordinates of state n and x* and y* be the coordinates of the goal. Which of the following are admissable heuristics?

A. [2 pts] h(n) = |x*-n.x| + |y*-n.y|

B. [2 pts] h(n) = min(|x*-n.x|,|y*-n.y|)

C. [2 pts] h(n) = max(|x*-n.x|,|y*-n.y|)

D. [2 pts] h(n) = shortest path distance from n to the goal in the original search graph.

E. [2 pts] h(n) = shortest path distance from n to the goal in the original search graph, with new edges added.

F. [2 pts] h(n) = shortest path distance from n to the goal in the original search graph, with some edges removed.

Problem 3: Ordering Pizza [30 points]

You are ordering a pizza for friends, and your friends have a few constraints. A. [10 pts] Formulate the problem of ordering a pizza as a constraint satisfaction problem.

B. [5 pts] Draw the constraint graph for this problem.

C. [5 pts] What about this constraint graph structure makes the problem easy or hard? (For this question, ignore the content of the constraints and just consider the structure of the constraint graph.)

D. [10 pts] Trace the execution of the AC3 algorithm on this problem.