COMP9414: Artificial Intelligence Uninformed Search

Similar documents
Princess Nora University Faculty of Computer & Information Systems ARTIFICIAL INTELLIGENCE (CS 370D) Computer Science Department

Uninformed search methods II.

Uninformed Search Strategies

Problem Solving as Search - I

Artificial Intelligence. Uninformed Search Strategies

Problem Solving Agents

Search I. Tuomas Sandholm Carnegie Mellon University Computer Science Department. [Read Russell & Norvig Chapter 3]

Solving Problems by Searching chap3 1. Problem-Solving Agents

Uninformed search methods II.

Uninformed search methods

Uninformed search methods

Uninformed search strategies

CENG 466 Artificial Intelligence. Lecture 4 Solving Problems by Searching (II)

Representation. Representation. Representation. Representation. 8 puzzle.

SEARCH SEARCH TREE. Node: State in state tree. Root node: Top of state tree

Real World Search Problems. CS 331: Artificial Intelligence Uninformed Search. Simpler Search Problems. Example: Oregon. Search Problem Formulation

SEARCH TREE. Generating the children of a node

COMP219: Artificial Intelligence. Lecture 8: Combining Search Strategies and Speeding Up

Overview. Depth Limited Search. Depth Limited Search. COMP219: Artificial Intelligence. Lecture 8: Combining Search Strategies and Speeding Up

CSE 3401: Intro to AI & LP Uninformed Search II

Uninformed Search (Ch )

Better Search Improved Uninformed Search CIS 32

CSE 3402: Intro to Artificial Intelligence Uninformed Search II

Introduction. AI and Searching. Simple Example. Simple Example. Now a Bit Harder. From Hammersmith to King s Cross

Uninformed Search (Ch )

CSC384: Introduction to Artificial Intelligence. Search

CS 4649/7649 Robot Intelligence: Planning

6.034 Artificial Intelligence

Depth-bounded Discrepancy Search

Transposition Table, History Heuristic, and other Search Enhancements

Spider Search: An Efficient and Non-Frontier-Based Real-Time Search Algorithm

G53CLP Constraint Logic Programming

Neural Nets Using Backpropagation. Chris Marriott Ryan Shirley CJ Baker Thomas Tannahill

/435 Artificial Intelligence Fall 2015

COMP 406 Lecture 05. Artificial. Fiona Yan Liu Department of Computing The Hong Kong Polytechnic University

Decision Trees. an Introduction

Planning and Acting in Partially Observable Stochastic Domains

ENHANCED PARKWAY STUDY: PHASE 2 CONTINUOUS FLOW INTERSECTIONS. Final Report

Tokyo: Simulating Hyperpath-Based Vehicle Navigations and its Impact on Travel Time Reliability

SIDDHARTH INSTITUTE OF ENGINEERING & TECHNOLOGY :: PUTTUR (AUTONOMOUS) Siddharth Nagar, Narayanavanam Road QUESTION BANK (DESCRIPTIVE)

Intersection Control Evaluation Report Project: Alternative: Location: Evaluator:

Optimization and Search. Jim Tørresen Optimization and Search

Pocatello Regional Transit Master Transit Plan Draft Recommendations

CS 4649/7649 Robot Intelligence: Planning

Application of Dijkstra s Algorithm in the Evacuation System Utilizing Exit Signs

Navy Guidance and Tips for Using DOEHRS-IH Ventilation NAVY & MARINE CORPS PUBLIC HEALTH CENTER

CS 4649/7649 Robot Intelligence: Planning

Centennial Neighbourhoods Transportation Management Plan Summary of Phase 1 Consultation. Overview of Issues

Traffic Academy: IJS & IMS FAQ/RULES OF THUMB

SEISMIC SURVEY GREENLAND 2014 Underwater sound propagation for North East Greenland offshore seismic survey

Pedestrian Dynamics: Models of Pedestrian Behaviour

In station areas, new pedestrian links can increase network connectivity and provide direct access to stations.

COLREGS Based Collision Avoidance of Unmanned Surface Vehicles

Advanced Search Hill climbing

Pedestrian Behaviour Modelling

Incremental ARA*: An Anytime Incremental Search Algorithm For Moving Target Search. University of Southern California Singapore Management University

Genetic Programming of Multi-agent System in the RoboCup Domain

Subsea Wellhead and Conductor Fatigue

Applying Bi-objective Shortest Path Methods to Model Cycle Route-choice

Chapter 7. Transportation. Transportation Road Network Plan Transit Cyclists Pedestrians Multi-Use and Equestrian Trails

The system design must obey these constraints. The system is to have the minimum cost (capital plus operating) while meeting the constraints.

Percentage. Year. The Myth of the Closer. By David W. Smith Presented July 29, 2016 SABR46, Miami, Florida

Decision Trees. Nicholas Ruozzi University of Texas at Dallas. Based on the slides of Vibhav Gogate and David Sontag

Exhibit 1 PLANNING COMMISSION AGENDA ITEM

Robust Task Execution: Procedural and Model-based. Outline. Desiderata: Robust Task-level Execution

Evacuation Time Minimization Model using Traffic Simulation and GIS Technology

Surf Survey Summary Report

Case Interview End-to-end Secrets Program

Distributed Control Systems

EDMONTON SCOTTISH UNITED SOCCER CLUB Accelerated Development Program Outdoor 2015

CS472 Foundations of Artificial Intelligence. Final Exam December 19, :30pm

Urban OR: Quiz 2 Solutions (2003) ( 1 ρ 1 )( 1 ρ 1 ρ 2 ) ( 1 12 )( ) σ S ] 24 [ 2 = 60, 2 2 ] ( 2 ) 3

Roundabouts Near At-Grade Railroad Crossings

Coquitlam Cross-town Bike Route Improving Bicycle Facilities in a Mature Suburban Environment

Active mobility and health: Insights from the PASTA Project

EXECUTIVE SUMMARY. A Executive Summary

Process Nature of Process

Using SHRP 2 s NDS Video Data to Evaluate the Impact of Offset Left-Turn Lanes on Gap Acceptance Behavior Karin M. Bauer & Jessica M.

Highway 56 Traffic Study Rymal Road to Cemetery Road

Two types of physical and biological standards are used to judge the performance of the Wheeler North Reef 1) Absolute standards are measured against

City of Ottawa s Complete Streets Approach to Transportation Projects

The Evolution of Transport Planning

III Code. TRACECA Maritime Safety and Security IMSAS workshop Kiev (Ukraine) III Code. Dr. Jens U. Schröder-Hinrichs

NORSOK STANDARD D-002 Edition 2 (2013)

CFD SIMULATIONS OF GAS DISPERSION IN VENTILATED ROOMS

Provably Secure Camouflaging Strategy for IC Protection

The evolution of public transport: an analysis of national statistics. Summary Report 2015:15

ConcepTest PowerPoints

CS 351 Design of Large Programs Zombie House

DECISION-MAKING ON IMPLEMENTATION OF IPO UNDER TOPOLOGICAL UNCERTAINTY

Variable Face Milling to Normalize Putter Ball Speed and Maximize Forgiveness

UNIT V 1. What are the traffic management measures? [N/D-13] 2. What is Transportation System Management (TSM)? [N/D-14]

Comments EXECUTIVE SUMMARY

Quiz name: Chapter 13 Test Review - Fluids

Large-eddy simulation study of effects of clearing in forest on wind turbines

Poseidon Team Description Paper RoboCup 2016, Leipzig, Germany

METHODOLOGY. Signalized Intersection Average Control Delay (sec/veh)

RoboCup-99 Simulation League: Team KU-Sakura2

The Rule of Right-Angles: Exploring the term Angle before Depth

m v = 1.04 x 10-4 m 2 /kn, C v = 1.29 x 10-2 cm 2 /min

Transcription:

COMP9, Monday March, 0 Uninformed Search COMP9: Artificial Intelligence Uninformed Search Overview Breadth-First Search Uniform Cost Search Wayne Wobcke Room J- wobcke@cse.unsw.edu.au Based on slides by Maurice Pagnucco Depth-First Search Depth-Limited Search Iterative Deepening Search Bidirectional Search Conclusion COMP9 c UNSW, 0 COMP9, Monday March, 0 Uninformed Search COMP9, Monday March, 0 Uninformed Search Uninformed (Blind) Search Many problems are amenable to attack by search methods We shall analyse a number of different search strategies We begin by examining search methods that have no problem-specific knowledge to use as guidance Theme: In [search] space, no one can hear you scream. [Aliens] References: Ivan Bratko, Prolog Programming for Artificial Intelligence, Fourth Edition, Pearson Education, 0. (Chapter ) Stuart J. Russell and Peter Norvig, Artificial Intelligence: A Modern Approach, Third Edition, Pearson Education, 00. (Chapter ) Breadth-First Search Idea: Expand root node, then expand all children of root, then expand their children,... All nodes at depth d are expanded before nodes at d+ Can be implemented by using a queue to store frontier nodes Breadth-first search finds shallowest goal state Stop when node with goal state is generated Include check that generated state has not already been explored

COMP9, Monday March, 0 Uninformed Search Breadth-First Search COMP9, Monday March, 0 Uninformed Search 6 Breadth-First Search Analysis 6 6 6 5 6 8 9 6 8 0 5 6 8 9 8 8 8 6 6 8 8 5 6 6 5 6 6 8 6 Complete Optimal provided path cost is nondecreasing function of the depth of the node Maximum number of nodes generated: b + b + b +...+ b d (where b = forward branching factor; d = path length to solution) Time and space requirements are the same O(b d ) 0 0 5 6 8 9 8 6 6 8 6 6 5 8 6 5 8 8 8 5 6 6 8 6 5 6 8 6 5 8 8 6 6 6 8 6 8 9 0 5 6 6 8 5 8 6 6 5 5 6 5 6 5 8 8 6 5 6 5 8 COMP9, Monday March, 0 Uninformed Search 5 Breadth-First Search COMP9, Monday March, 0 Uninformed Search Uniform Cost Search % Figure.0 An implementation of breadth-first search. % solve(start, Solution): % Solution is a path (in reverse order) from Start to a goal solve(start, Solution) :- breadthfirst([[start]], Solution). % breadthfirst([path, Path,...], Solution): % Solution is an extension to a goal of one of paths breadthfirst([[node Path] _], [Node Path]) :- goal(node). breadthfirst([path Paths], Solution) :- extend(path, NewPaths), conc(paths, NewPaths, Paths), breadthfirst(paths, Solution). extend([node Path], NewPaths) :- bagof([newnode, Node Path], (s(node, NewNode), not member(newnode, [Node Path])), NewPaths),!. extend(path, []). % bagof failed: Node has no successor Also known as Lowest-Cost-First search Shallowest goal state may not be the least-cost solution Idea: Expand lowest cost (measured by path cost g(n)) node on the frontier Order nodes in the frontier in increasing order of path cost Breadth-first search uniform cost search where g(n)=depth(n) (except breadth-first search stops when goal state generated) Include check that generated state has not already been explored Include test to ensure frontier contains only one node for any state for path with lowest cost

COMP9, Monday March, 0 Uninformed Search 8 COMP9, Monday March, 0 Uninformed Search 0 Uniform Cost Search Depth-First Search S 5 8 A B C 5 5 Idea: Always expand node at deepest level of tree and when search hits a dead-end return back to expand nodes at a shallower level Can be implemented by using a stack to store frontier nodes At any point depth-first search stores single path from root to leaf together with any remaining unexpanded siblings of nodes along path Stop when node with goal state is expanded Include check that generated state has not already been explored along a path cycle checking G COMP9, Monday March, 0 Uninformed Search 9 COMP9, Monday March, 0 Uninformed Search Uniform Cost Search Analysis Depth-First Search Complete Optimal provided path cost does not decrease along path (i.e. g(successor(n)) g(n) for all n) 6 8 6 Reasonable assumption when path cost is cost of applying operators along the path 6 9 8 8 Performs like breadth-first search when g(n)=depth(n) If there are paths with negative cost we would need to perform an exhaustive search 8 0 5 8 6 9 6 8 8 6 6 8 6 6 5 6 5 5 9 8 6 5 8 5 0 8 6 0 6 6 8 6 8 8 8 6 6 8 6 8 6 6 5 6 6 8 5 5 6 5 6 5

COMP9, Monday March, 0 Uninformed Search Depth-First Search % Figure. A depth-first search program that avoids cycling. % solve(node, Solution): % Solution is acyclic path (in reverse order) btwn Node and goal solve(node, Solution) :- depthfirst([], Node, Solution). % depthfirst(path, Node, Solution): % extending the path [Node Path] to a goal gives Solution depthfirst(path, Node, [Node Path]) :- goal(node). depthfirst(path, Node, Sol) :- s(node, Node), not member(node, Path), % Prevent a cycle depthfirst([node Path], Node, Sol). COMP9, Monday March, 0 Uninformed Search Depth-Limited Search Idea: impose bound on depth of a path In some problems you may know that a solution should be found within a certain cost (e.g. a certain number of moves) and therefore there is no need to search paths beyond this point for a solution Depth-Limited Search Analysis Complete but not optimal (may not find shortest solution) However, if the depth limit chosen is too small a solution may not be found and depth-limited search is incomplete in this case Time and space complexity similar to depth-first search (but relative to depth limit rather than maximum depth) COMP9, Monday March, 0 Uninformed Search Depth-First Search Analysis COMP9, Monday March, 0 Uninformed Search 5 Iterative Deepening Search Storage: O(bm) nodes (where m = maximum depth of search tree) Time: O(b m ) In cases where problem has many solutions depth-first search may outperform breadth-first search because there is a good chance it will happen upon a solution after exploring only a small part of the search space However, depth-first search may get stuck following a deep or infinite path even when a solution exists at a relatively shallow level Therefore, depth-first search is not complete and not optimal Avoid depth-first search for problems with deep or infinite paths It can be very difficult to decide upon a depth limit for search The maximum path cost between any two nodes is known as the diameter of the state space This would be a good candidate for a depth limit but it may be difficult to determine in advance Idea: try all possible depth limits in turn Combines benefits of depth-first and breadth-first search

COMP9, Monday March, 0 Uninformed Search 6 Iterative Deepening Search COMP9, Monday March, 0 Uninformed Search 8 Bidirectional Search... Idea: search forward from initial state and backward from goal state at the same time until the two meet To search backwards we need to generate predecessors of nodes (this is not always possible or easy) If operators are reversible successor sets and predecessor sets are identical If there are many goal states we can try a multi-state search (how would you do this in chess, say?) Need to check whether a node occurs in both searches may not be easy Which is the best search strategy for each half? COMP9, Monday March, 0 Uninformed Search Iterative Deepening Search Analysis COMP9, Monday March, 0 Uninformed Search 9 Bidirectional Search Optimal; Complete; Space O(bd) Some states are expanded multiple times. Isn t this wasteful? Number of expansions to depth d = + b + b + b +...+ b d Therefore, for iterative deepening, total expansions = (d+ ) + (d)b+ (d )b +...+ b d + b d + b d The higher the branching factor, the lower the overhead (even for b=, search takes about twice as long) Hence time complexity still O(b d ) May consider doubling depth limit at each iteration overhead O(dlogd) In general, iterative deepening is the preferred search strategy for a large search space where depth of solution is not known S G

COMP9, Monday March, 0 Uninformed Search 0 COMP9, Monday March, 0 Uninformed Search Bidirectional Search Analysis Conclusion If solution exists at depth d then bidirectional search requires time O(b d )=O(b d ) (assuming constant time checking of intersection) To check for intersection must have all states from one of the searches in memory, therefore space complexity is O(b d ) We have surveyed a variety of uninformed search strategies All can be implemented within the framework of the general search procedure There are other considerations we can make like trying to save time by not expanding a node which has already been seen on some other path There are a number of techniques available and often use is made of a hash table to store all nodes generated COMP9, Monday March, 0 Uninformed Search Summary Blind Search Criterion Breadth Uniform Depth- Depth- Iterative Bidirectional First Cost First Limited Deepening Time b d b d b m b l b d b d Space b d b d bm bl bd b d Optimal Yes Yes No No Yes Yes Complete Yes Yes No Yes, if l d Yes Yes b branching factor d depth of shallowest solution m maximum depth of tree l depth limit