Uninformed Search Techniques
Informed Search Techniques
Generating solutions from observed data
- Set of Goals
- Set of Objects
- Set of Operations
All valid states using operations on objects
- Search for solution in problem space
- Example: DFS, BFS,...
Actions: PICKUP, PUTDOWN, FORWARD, BACKWARD, LEFT, RIGHT
Condition-1: Only top ring can be moved at a time
Condition-2: Smaller ring cannot be below the large one
- Direct Graph
- Start from Initial State
- Use operations
- Check Goal State
- Blind Search
- Only Problem Defintion
- No idea if one non-goal state is better than other
- Visit all the nodes in a a certain order for pre-defined goal
- No cleverness
- No guarantee of reaching goal state
Less Ineffective than Informed Search
- Proceed level by level down the tree
- Start from root node and explore all the children, left to right
- If no solution found, expand the first(leftmost) child, then second at same depth,...
- Place start node at the end of queue
- Examine the node at the front of queue, then
Queue
Complete? Yes! Always reaches GOAL
Time? O(b^d):: Number of nodes generated
Space? O(b^d):: Keeps every node in the memory
Optimal? Yes! except deeper solutions
Branching Factor=b and goal found at depth=d
Space is more problem than time.
- Proceed down a single branch at a time
- Expand root node, then leftmost child of the root, then leftmost child of that node,..
Stack (LIFO)
Complete? No! Fails in infinite depth :: A-B-C-A
Time? O(b^m):: Maximum depth
Space? O(b*m):: Linear Space
Optimal? NO! except deeper solutions
Can go to wrong branch and may take very long time to find solution
- Optimized DFS
- Perform DFS but only at a specified depth L
- The path length is at max L
Complete? No! Solution may be beyond depth level
Time? O(b^L):: Maximum depth
Space? O(b*L):: Linear Space
Optimal? NO!
- Domain Specific Information
- Heuristic Function h(n) : Goodness of a node n
h(n) = estimated cost of minimal cost path from n to goal state
- Uses evaluation function f(n) to select a node for expansion
- Node with lowest evaluation function is expanded first
Use an evaluation function for each node -> desirability
- Greedy Best First Search
- A* Search
- tries to get as close as it can to the goal
- expands the node that appears closest to the goal
- Uses only heuristic function
Evaluation function h(n) = estimate of cost from n to closest goal
Example: hsld(n) = straight-line distance from n to goal
f(n) = h(n)
h(n) = 0 for goal state
Complete? NO! Can get stuck in loops
Time? O(b^m):: depends on good heuristic
Space? O(b^m):: Keeps all nodes in memory
Optimal? NO!
evaluation function f(n) = g(n) + h(n)
g(n) = cost so far to reach n
estimated cost from n to goal
Complete? YES!
Time? Exponential
Space? Keeps all nodes in memory
Optimal? YES!
Competitive Environments in which the agents goals are in conflict
- Often known as games
- Initial State
- A successor function
- A terminal test
- A Utility function
Opposition between agent's Utility functions
- depth first search with limited depth
- Static evaluation function for all leaf nodes
- assume opponent will make the best move possible
- Optimized MiniMax
- Instead of expanding nodes, we try to infer based on node values
- Depends on the order on how nodes are expanded
Alpha -> value of best choice so far for MAX (highest value)
Beta -> value of best choice so far for MIN (lowest value)
Each node keeps track of [alpha, beta]
Alpha -> -INF
Beta -> +INF
Research