Speculative Agents; Single Agent Search
PSU CS441/541
Lecture 3
October 11, 2001
(Note: added Chapter 11 to readings)
- Consider Some Examples (from Ginsberg)
  
  - 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?
  
  - Smart Reactive Systems?  No
    
    - Must react to exponential number of situations:
	too much memory
    
- Make no effective use of computation: lookups are slow
    
 
- Even if there was, lookup always too slow
  
- Problems are (problem is) NP-hard
    
    - problem description
    
- NP
    
- NP-hardness
    
- NP-completeness
    
- reductions
    
- P = NP?
    
 
 
- State Spaces
  
  - Graph
    
    - Nodes, edges
    
- Rooted, directed, labeled nodes, labeled edges
    
- DAG, tree, clique, weighted, colored
    
 
- Nodes describe world state
  
- Edges describe ``legal'' transitions between states
    
    - Direction?
    
- Action?  Maybe: any change in state can be regarded
        as such  (``Feature Vector'' and planning)
    
 
- Problem: find desired state in space
    
    - Given initial state, find path (Nilsson)
    
- Find state meeting constraints
    
 
 
- Blind Search
  
  - Database (graph) too big: build lazily (on-demand)
    
    - solves storage problem
    
- might attack computation problem
    
 
- Tree-structure database
    
    - initial state at root
    
- solutions at leaves
    
- move toward more knowledge
    
 
- Blind search algorithms
    
    - breadth-first search: shortest path
      
      - 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: usable instance
      
      - 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
    
 
 
- 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*: an admissable and ``provably optimal'' pathfinding search algorithm
    
    - A* on trees
    
- admissable heuristics
    
- extension to graphs
    
- consistent/monotonic heuristics
    
 
- IDA*
  
- RBFS (optional)
  
- The role of heuristics
    
    - Heuristics as ``cheating''
    
- Tweaking a heuristic
      
      - Monotonizing
      
- Sacrificing admissibility
      
 
 
 
- 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
    
 
 
- Search and SAT
  
  - Search space
  
- Solution algorithms
  
- Heuristics
  
 
- 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