Professional Documents
Culture Documents
Jaime Carbonell
jgc@cs.cmu.edu
16 January 2003
Today's Agenda
Brief review of search complexity
Heuristics and evaluation functions
Heuristic search methods
Admissibility and A* search
B* search
Macrooperators in search
Complexity of Search
Definitions
Let depth d = length(min(s-Path(S0, SG)))-1
Let branching-factor b = Ave(|Succ(Si)|)
Let backward branching B = Ave(|Succ-1(Si)|);
usually b=bb, but not always
Let C(<method>,b,d) = max number of Si visited
Definition
A Heuristic is an operationally-effective
nugget of information on how to direct
search in a problem space. Heuristics are
only approximately correct. Their purpose is
to minimize search on average.
Common Types of Heuristics
General Form:
1. Quit if done (with success or failure), else:
2. s-Queue:= F(Succ(Scurr),s-Queue)
3. Snext:= Argmax[E(s-Queue)]
4. Go to 1, with Scurr:= Snext
Heuristic Search
Steepest-Ascent Hill-Climbing
F(Succ(Scurr), s-Queue) = Succ(Scurr)
Snext:= Argmax[E(Succ(Scurr))]
If Succ(Snext) is null, then stop
Quintessential greedy search
Max-Gradient Search
"Informed" depth-first search
Snext:= Argmax[E(Succ(Scurr))]
But if Succ(Snext) is null, then backtrack
Alternative: backtrack if E(Snext)<E(Scurr)
Beyond Greedy Search
Best-First Search
BestFS(Scurr, SG, s-Queue)
IF Scurr = SG, return SUCCESS
For si in Succ(Scurr)
Insertion-sort(<Si, E(Si)>, s-Queue)
IF s-Queue = Null, return FAILURE
ELSE return
BestFS(FIRST(s-Queue), SG, TAIL(s-Queue))
Beyond Greedy Search
F(Succ(Scurr)), s-Queue) =
Sort(Append(Succ(Scurr), Tail(s-Queue)),E(si))
Full-breadth search
"Ragged"fringe expansion
Beam Search
Best-few BFS
Beam-width parameter
Optimality Definition
A solution is optimal if it conforms to the
minimal-cost path between S0 and SG. If
operators cost is uniform, then the optimal
solution = shortest path.
Admissibility Definition
A heuristic is admissible with respect to a
search method if it guarantees finding the
optimal solution first, even when its value is
only an estimate.
A* Search Preliminaries
Yes, we can!
A*: Better Admissible Heuristics
The A* Criterion
If h(Scurr) always equals or underestimates the
true remaining cost, then f(Scurr) is admissible
with respect to Best-First Search.
A* Search
A* Search = BestFS with admissible f = g + h
under the admissibility constraints above.
A* Optimality Proof
Ideas
Admissible heuristics for mono- and bi-polar
search
"Eliminates" horizon problem in game-trees
[more later]
Definitions
Let Best(S) = Always optimistic eval fn.
Let Worst(S) = Always pessimistic eval fn.
Hence: Worst(S) < True-eval(S) < Best(S)
Basic B* Search
Basic B* Search
B*(S) is defined as:
If there is an Si in SUCC(Scurr)
s.t. For all other Sj in SUCC(Scurr), W(Si) > B(Sj)
Then select Si
Else ProveBest (SUCC(Scurr)) OR DisproveRest (SUCC(Scurr)
Difficulties in B*
Guaranteeing eternal pessimism in W(S) (eternal optimism is
somewhat easier)
Switching among ProveBest and DisproveRest
Usually W(S) << True-eval(S) << B(S) (not possible to achieve
W(Si) > B(Sj)
Macrooperators in Search
Linear Macros
Cashed sequence of instantiated operators:
If: S0 opi S1 opj S2
Then: S0 opi,j S2
Alternative notation:
Disjunctive Macros
op2 op3
op5 op6
Iterative Macros
NO
opo,p,q