Single Agent Search
PSU CS441/541
Lecture 3
October 9, 2000
- Consider Ginsberg 2.2.4 Examples
- Game Playing
- Pathfinding
- missionaries and cannibals
- Towers of Hanoi
- 15 puzzle
- Rubik's Cube
- Satisfiying/Satisficing
- cryptarithmetic
- n-queens
- mutilated checkerboard
- What Is The Common Ground?
- We could build giant database and look up answer
- No database in the world big enough
- Even if there was, lookup always too slow
- Problems are (problem is) NP-hard
- problem description
- NP
- NP-hardness
- NP-completeness
- reductions
- P = NP?
- Blind Search
- Build database lazily (on-demand)
- solves first problem
- might attack second
- Tree-structure database
- initial state at root
- solutions at leaves
- move toward more knowledge
- Blind search algorithms
- breadth-first search for pathfinding
- node represents location
- select least recently examined node until
- move away from node in direction not
previously visited
- not space-efficient: cannot discard nodes
- produces shortest paths: optimal
- depth-first search?
- depth-first search for SAT
- node represents partial assignment
- extend partial assignments until
- contradiction
- total assignment (solution)
- ``obvious'' approach
- runs forever (except small or easy instances)
- space-efficient
- making DFS more like BFS
- iterative deepening
- iterative broadening
- nonsystematic methods
- undirected and directed graphs: open and closed
lists
- dynamic backtracking
- Heuristic Search
- DFS gets lost: add problem-specific ``hints''
- Goal distance estimates in pathfinding search
- How to use the goal distance heuristic
- Hill climbing: local search
- Best-first search
- A*: a ``provably optimal'' pathfinding search algorithm
- admissable heuristics
- monotonic heuristics
- algorithm
- extension to graphs
- IDA*
- Nogoods
- DFS for SAT does not use memory effectively
- Keep nogoods around: partial assignments that
fail
- Resolve nogoods to shorter nogoods
- Prune search using nogoods
- What nogoods to keep?
- short nogoods: does not work
- "relevant" nogoods: RELSAT
- Local Search
- Completeness of search
- Hill climbing: problems
- local maxima
- plateaus
- ridges
- Noise
- natural noise
- introducing noise
- convergence
- restarts
- simulated annealing
- Systematic hill climbing: iterated randomness
- WSAT: local search for Boolean SAT
- idea: start with total assignment and ``flip''
- problem: can get stuck
- solution: noise flips
- algorithm
- Start with (random?) total assignment
- Repeatedly flip a coin and on
- Heads: pick ``best'' variable in unsat clause,
flip it
- Tails: pick random variable, flip it
- If a solution is ever found, stop
- ``walks'' through total assignment space