170 likes | 376 Views
GPS. CIS 479/579 Bruce R. Maxim UM-Dearborn. GPS. General problem solver Newell, Simon, Shaw Based on Polya’s problem solving heuristics Understand problem Devise plan Carry out plan Look back at solution. GPS Applications. Missionaries and Cannibals Towers of Hanoi
E N D
GPS CIS 479/579 Bruce R. Maxim UM-Dearborn
GPS • General problem solver • Newell, Simon, Shaw • Based on Polya’s problem solving heuristics • Understand problem • Devise plan • Carry out plan • Look back at solution
GPS Applications • Missionaries and Cannibals • Towers of Hanoi • Symbolic integration • Predicate calculus theorem proving • Series completion (e.g. B C B D B _ _ )
GPS • Unlike A* we do not need to reprogram GPS when we change problem solving domains • When the domain changes GPS simply receives a new list of states and operators • It is interesting to note that as GPS became more general its solutions became poorer
GPS Components • Means ends analysis • control strategy used to select and order operators • Planning • goal or problem reduction • Selective trial and error • basically generate and test
Means Ends Analysis • Focus of this technique is to do whatever is needed to reduce the distance between the current state and the goal state • Resembles depth first search • Each operator has a set of preconditions that must be satisfied before it can be fired • If preconditions are not satisfied then they are added to the goal list and the procedure is run again
GPS Algorithm form a one element queue containing current state until queue is empty or goal reached if no untried procedure for reducing differences between current & goal then remove first goal from queue else if procedure precondition not satisfied then use GPS with precondition as sub-goal else use procedure to make new state q+ head of queue if goal state found turn then announcesuccess else announce failure
GPS Example • How do we get Robbie the Robot from Boston to LA? • We will need a distance measure (e.g. like “miles”) • We also need a table of operators to work with indexed by both preconditions and effect (output)
GPS Example • How does Robbie know that it is not good to return to Boston to get the car after landing at the LA airport? • Answer: GPS prevents movement to states farther from goal than current state
GPS • In complex domains we need to be careful that GPS is not blindly attacking preconditions for operators tah would be bad to use from current state • This where the role of planning becomes important (e.g. ask “is there anything bad about using the airplane?” before attacking precondition goals)
GPS Problem Areas • Clobbered sibling problem • GPS may decide to solve problems in serial order using depth first search • For example if goal is to drive to school and arrive with money, GPS may decide to use money to buy a battery if the car doesn’t start
GPS Problem Areas • Leaping before you look • GPS is more than happy to solve the goal “jump of the cliff and land safely” by jumping first and worrying about landing on the way down • Recursive sub goals • Learn how to set up a VCR by playing a video tape showing your how
GPS Problem Areas • Lack of intermediate information • GPS may simply print out a “nil” on failure • Important to keep track of partial solutions and displaying them rather than giving up • Not adding look ahead • “not looking after not leaping” • GPS may not generate solution if it does not consider all future problem states
GPS Problem Areas • Lack of descriptive power • GPS may simply provide general goal like “put king in check mate” even when state information is very specific (e.g. piece locations) • Requires perfect information • Real world problems are not always stated with the complete information required to assess operator preconditions
GPS Problem Areas • Interacting goals problem • Similar to deadlock in thread or coroutine execution • GPS has no notion of giving up when a reasonable number of goals have been met (this is call problem satisficing as opposed to problem solving)