180 likes | 319 Views
Chap 4. Informed Search Methods. 4-1. Best-first search 4-2. Heuristic functions 4-3. Memory bounded search 4-4. Iterative improvement algorithms. 4-0. Preliminary. Reference: Chapter 4, Winston How to put heuristics? 1) as program codes 2) as rules 3) as parameters Role of knowledge
E N D
Chap 4. Informed Search Methods 4-1. Best-first search 4-2. Heuristic functions 4-3. Memory bounded search 4-4. Iterative improvement algorithms
4-0. Preliminary • Reference: Chapter 4, Winston • How to put heuristics? 1) as program codes 2) as rules 3) as parameters • Role of knowledge 1) to reduce the search time (by reducing the # of expanded nodes) 2) to help to reduce a problem into a simpler one.
“heuristic” search -- Newell & Ernst (1965) • Where is the heuristics incorporated in the search algorithm? n <--- SELECT (OPEN), or OPEN <--- Re-order (OPEN) • heuristic power <----> # of expanded nodes
1) Heuristic function (evaluation function) • the ability to forecast the future. • candidates • probability that a node is on the best path. • distance between a node and the goal. 2) Hill climbing • similar to depth-first
3) Beam search • similar to breadth-first search. • Move down only thru the best W nodes at each level. • Other nodes are ignored. 4) Greedy method • Choose the node that is likely to be the closest to goal. • completeness -- no • admissibility -- no, but tends to find solutions quickly.
4-1. A-search and A*-search • “Best-first” actually means “seemingly-best-first”. • idea • evaluation function = estimated min cost from s to n + estimated min cost from n to g • algorithm n <---- SELECT (OPEN) n <---- min { OPEN } wrt eval. fn
(1) A-search (2) A*-search
(1) A-search • f(n) = g(n) + h(n)
(2) A*-search • Hart, Nilsson, Raphael (1968) • Def. admissibility • Def. A* • Thm. A* is admissible Homework #1: Proove that A* is admissible.
4-2. Heuristic functions • heuristic functions for 8-puzzle problem 1) # of mis-placed tiles 2) the sum of the distances of the tiles from their goal position • performance [fig 4.8, pp. 103]
Comparison of two A* algorithms • Def. (more) informed • Thm. a relation between informedness and # of nodes
inventing heuristic functions • Consider a relaxed problem. • example: shortest path on the map • example: 8 puzzle • Automatic generation of a relaxed problem? • ABSOLVER (Prieditis 1993) • statistical info • training
Def. monotonic restriction • Thm. monotonic restriction ===> less book-keeping
Homework #2: A* algorithm • OPEN FOCAL • sublist of OPEN • contains only those nodes which do not deviate from the node which has the lowest expected evaluation function by a factor greater than 1+ . • A* selects a node from FOCAL with the minimum f value. • Show that A* is -admissible, I.e., it always find a solution whose cost dos not exceed the optimal cost more than a factor of (1+ ).
4-3. Memory-bound search • Memory is more critical than time. • iterative-deepening search ---> IDA* (iterative deepening A*) • A* ----> SMA* (simplified memory-bounded A*)
1) Iterative deepening A* search (IDA*) • iterative deepening • memory -- depth-first • completeness -- breadth-first • depth-first, but use f-value, rather than depth. • complete, admissible • algorithm [fig 4.10, pp. 107] • space longest path ( = shortest path to the optimal solution) • time • total # of expansions = 1 + 2 + 3 + … N where A* expands N nodes.
2) Simplified memory-bound A* search (SMA*) • IDA* uses too little memory. • idea: Keep | OPEN | + | CLOSE | Nmax • algorithm [fig 4.12, pp. 110] • example [fig 4.11, pp.109] • complete if the available memory is sufficient to store the shallowest solution path. • admissible if the available memory is sufficient to store the shallowest optimal solution path.