Search Techniques CS480/580 Fall 2009. Introduction Trees: – Root, parent, child, sibling, leaf node, node, edge – Single path from root to any node Graphs:

Slides:



Advertisements
Similar presentations
Artificial Intelligence
Advertisements

Informed Search CS 171/271 (Chapter 4)
Informed search algorithms
Heuristic Searches. Feedback: Tutorial 1 Describing a state. Entire state space vs. incremental development. Elimination of children. Closed and the solution.
Heuristic Search techniques
Solving Problem by Searching
October 1, 2012Introduction to Artificial Intelligence Lecture 8: Search in State Spaces II 1 A General Backtracking Algorithm Let us say that we can formulate.
ICS-171:Notes 4: 1 Notes 4: Optimal Search ICS 171 Summer 1999.
5-1 Chapter 5 Tree Searching Strategies. 5-2 Satisfiability problem Tree representation of 8 assignments. If there are n variables x 1, x 2, …,x n, then.
CS 480 Lec 3 Sept 11, 09 Goals: Chapter 3 (uninformed search) project # 1 and # 2 Chapter 4 (heuristic search)
CS 484 – Artificial Intelligence1 Announcements Department Picnic: today, after class Lab 0 due today Homework 2 due Tuesday, 9/18 Lab 1 due Thursday,
Chapter 4 Search Methodologies.
EIE426-AICV 1 Blind and Informed Search Methods Filename: eie426-search-methods-0809.ppt.
Artificial Intelligence (CS 461D)
CS171 Introduction to Computer Science II Graphs Strike Back.
Artificial Intelligence Lecture No. 7 Dr. Asad Safi ​ Assistant Professor, Department of Computer Science, COMSATS Institute of Information Technology.
Mahgul Gulzai Moomal Umer Rabail Hafeez
SE Last time: Problem-Solving Problem solving: Goal formulation Problem formulation (states, operators) Search for solution Problem formulation:
Review: Search problem formulation
Problem Solving by Searching Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 3 Spring 2004.
1 Using Search in Problem Solving Part II. 2 Basic Concepts Basic concepts: Initial state Goal/Target state Intermediate states Path from the initial.
Nyhoff, ADTs, Data Structures and Problem Solving with C++, Second Edition, © 2005 Pearson Education, Inc. All rights reserved Graphs.
MAE 552 – Heuristic Optimization Lecture 27 April 3, 2002
Structures and Strategies for State Space Search
Using Search in Problem Solving
Problem Solving and Search in AI Heuristic Search
Using Search in Problem Solving
5-Nov-2003 Heuristic Search Techniques What do you do when the search space is very large or infinite? We’ll study three more AI search algorithms: Backtracking.
5-1 Chapter 5 Tree Searching Strategies. 5-2 Breadth-first search (BFS) 8-puzzle problem The breadth-first search uses a queue to hold all expanded nodes.
CS 561, Session 6 1 Last time: Problem-Solving Problem solving: Goal formulation Problem formulation (states, operators) Search for solution Problem formulation:
1 Structures and Strategies for State Space Search 3 3.0Introduction 3.1Graph Theory 3.2Strategies for State Space Search 3.3Using the State Space to Represent.
State-Space Searches. 2 State spaces A state space consists of –A (possibly infinite) set of states The start state represents the initial problem Each.
For Friday Finish chapter 3 Homework: –Chapter 3, exercise 6 –May be done in groups. –Clarification on part d: an “action” must be running the program.
State-Space Searches.
Informed Search Idea: be smart about what paths to try.
Review: Search problem formulation Initial state Actions Transition model Goal state (or goal test) Path cost What is the optimal solution? What is the.
Informed Search Strategies
Busby, Dodge, Fleming, and Negrusa. Backtracking Algorithm Is used to solve problems for which a sequence of objects is to be selected from a set such.
Solving Problems by Searching CPS Outline Problem-solving agents Example problems Basic search algorithms.
Graphs II Robin Burke GAM 376. Admin Skip the Lua topic.
Vilalta&Eick: Informed Search Informed Search and Exploration Search Strategies Heuristic Functions Local Search Algorithms Vilalta&Eick: Informed Search.
Tree Searching Breadth First Search Dept First Search.
P ROBLEM Write an algorithm that calculates the most efficient route between two points as quickly as possible.
Informed search algorithms
State-Space Searches. 2 State spaces A state space consists of A (possibly infinite) set of states The start state represents the initial problem Each.
A RTIFICIAL I NTELLIGENCE UNIT : 2 Search Techniques.
Nyhoff, ADTs, Data Structures and Problem Solving with C++, Second Edition, © 2005 Pearson Education, Inc. All rights reserved Graphs.
Artificial Intelligence LECTURE 4 ARTIFICIAL INTELLIGENCE LECTURES BY ENGR. QAZI ZIA.
For Friday Finish reading chapter 4 Homework: –Lisp handout 4.
For Monday Read chapter 4, section 1 No homework..
Search with Costs and Heuristic Search 1 CPSC 322 – Search 3 January 17, 2011 Textbook §3.5.3, Taught by: Mike Chiang.
Review: Tree search Initialize the frontier using the starting state While the frontier is not empty – Choose a frontier node to expand according to search.
For Friday Read chapter 4, sections 1 and 2 Homework –Chapter 3, exercise 7 –May be done in groups.
Search (continued) CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
1 search CS 331/531 Dr M M Awais REPRESENTATION METHODS Represent the information: Animals are generally divided into birds and mammals. Birds are further.
Uninformed search strategies A search strategy is defined by picking the order of node expansion Uninformed search strategies use only the information.
Slides by: Eric Ringger, adapted from slides by Stuart Russell of UC Berkeley. CS 312: Algorithm Design & Analysis Lecture #36: Best-first State- space.
Graph Algorithms GAM 376 Robin Burke Fall Outline Graphs Theory Data structures Graph search Algorithms DFS BFS Project #1 Soccer Break Lab.
Informed Search CSE 473 University of Washington.
Graph Search II GAM 376 Robin Burke. Outline Homework #3 Graph search review DFS, BFS A* search Iterative beam search IA* search Search in turn-based.
Search Methodologies Fall 2013 Comp3710 Artificial Intelligence Computing Science Thompson Rivers University.
For Monday Read chapter 4 exercise 1 No homework.
Chapter 3 Solving problems by searching. Search We will consider the problem of designing goal-based agents in observable, deterministic, discrete, known.
Artificial Intelligence Solving problems by searching.
Chapter 3.5 Heuristic Search. Learning Objectives Heuristic search strategies –Best-first search –A* algorithm Heuristic functions.
Last time: Problem-Solving
Heuristic Search A heuristic is a rule for choosing a branch in a state space search that will most likely lead to a problem solution Heuristics are used.
CS 4100 Artificial Intelligence
Informed Search Idea: be smart about what paths to try.
Informed Search Idea: be smart about what paths to try.
Presentation transcript:

Search Techniques CS480/580 Fall 2009

Introduction Trees: – Root, parent, child, sibling, leaf node, node, edge – Single path from root to any node Graphs: – Nodes, edges, directed/undirected graph, acyclic graph

Search techniques for Trees Exhaustive search – Breadth-first search: Use a queue to implement Search nodes each level at a time – Depth-first search: Use a stack to implement Search nodes path at a time

Searching Graph Apply the same two techniques But to eliminate infinite looping, mark a node when it is already visited. This way it won’t be explored repeatedly.

Heuristic Search When the search space is very large (millions of nodes), it is not feasible to search the entire space; Instead we use a heuristic search that directs the search based on some heuristics – Evaluation function to rank the nodes to determine the order of search---which is most likely to succeed

Heuristic 1: Hill Climbing First decide on an evaluation function for each node---this depends on the specific application – E.g., In airline routing, if the task is to find a route that can take a passenger from airport X to airport Y, there could be several possible sequence of hops that need to be considered. – Suppose there is no direct path from X-Y, but there are 4 hubs H1, H2, H3, H4, that X has flights to, then we need to determine which is the next hub we want to explore. We need a basis for the decision. – Suppose we consider the distance between X and a hub as the evaluation function so the further a hub takes a passenger away from X, then the closer it is to the destination Y. So evaluation criteria is: choose an alternate that is farthest from X. – This may or may not always result in optimal solution. – Local maxima, local minima---problems – Look at the airline routing in the above reference

Best First Search Similar to BFS and DFS, it is exhaustive. The difference is that the next node to search is based on an evaluation function---in other words whenever we need to choose the next node to search pick the one with the best node value Calls for a priority queue instead of a stack or a FCFS queue Refer to Fig. 4.8 – Discussion in class

Least-cost search Always choose the one that costs less in the next step---that is we always choose the node that can be reached with minimal cost from the current location. For example

A* Algorithm Variant of best first search Assumes: Estimated cost < Actual cost Admissible heuristic function: h(n) ≤ h * (n) where h * (n) is the true cost to the nearest goal.---never overestimate costs Guarantees optimal solution provided admissible heuristics is used ---minimum cost solution --- distance is a cost, travel time is a cost, etc. Here, evaluation function has two parts: cost of getting from start to the Current node; cost of going from current node to goal node or target node. f(Node) = g(Node) + h(Node) Refer to the following slidesslides

Using Search Techniques in problem Solving Puzzle solving, planning, routing, etc. In the case of a board puzzle, each node represents current state of the puzzle; goal node represents the desired board position