You are on page 1of 2

COMP9414/9814/3411 Artificial Intelligence, Session 1, 2015

Week 3 Exercises - Search Strategies


This exercise concerns the route-finding problem using the Romania
map from Russell & Norvig as an example:
Straightline distance
Oradea to Bucharest
71
Neamt Arad 366
87 Bucharest 0
Zerind 151 Craiova
75 160
Iasi Dobreta 242
Arad 140 Eforie 161
92 Fagaras 178
Sibiu 99 Fagaras Giurgiu 77
118 Hirsova
Vaslui 151
80
Iasi 226
Rimnicu Vilcea Lugoj
Timisoara 244
142 Mehadia 241
111 211 Neamt 234
Lugoj 97 Pitesti
Oradea 380
70 98 Pitesti 98
146 85 Hirsova
Mehadia 101 Urziceni Rimnicu Vilcea 193
75 138 86 Sibiu 253
Bucharest Timisoara 329
120
Dobreta
90 Urziceni 80
Craiova Eforie Vaslui 199
Giurgiu Zerind 374

In what order are the nodes in the state space expanded for each of the
following algorithms when searching for a (shortest) path between Arad
and Bucharest? Whenever there is a choice of nodes, you should select
the one that comes first in alphabetical order. In each case, continue
the algorithm until the goal node is expanded.

(a) Breadth First Search, skipping any state that has previously been
expanded
(b) Uniform Cost Search, skipping any state that has previously been
expanded
(c) Depth First Search, skipping any state that forms a loop (i.e. the
same state occurring twice along a single path from root to leaf)
(d) Iterative Deepening (Depth First) Search
(e) Greedy Best First Search using the straight-line distance heuristic
(f) A Search using the straight-line distance heuristic
(g) Depth First Search again, skipping loops as before, but this time
choosing nodes in reverse alphabetical order

3.13 (2nd Ed.)

(a) Describe a search space in which Iterative Deepening Search per-


forms much worse than Depth First Search.
(b) Describe a search space in which Breadth First Search performs
much worse than Depth First Search.
(c) Describe a search space in which Depth First Search performs
much worse than Breadth First Search.
3.22 Prove each of the following statements, or give a counterexample:

(a) Breadth First Search is a special case of Uniform Cost Search


(b) Breadth First Search, Depth First Search and Uniform Cost Search
are special cases of best-first search.
(c) Uniform Cost Search is a special case of A*Search

3.28 The heuristic path algorithm is a best-first search in which the


objective function is

f (n) = (2 w)g(n) + wh(n)

For what values of w is this algorithm complete? For what values of


w is it optimal, assuming h() is admissible? What kind of search does
this perform when w = 0? when w = 1? when w = 2?

You might also like