CSE (c) S. Tanimoto, 2002 State-Space Search

Slides:



Advertisements
Similar presentations
BEST FIRST SEARCH - BeFS
Advertisements

Solving problems by searching
CS344 : Introduction to Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 2 - Search.
Heuristic Search techniques
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal.
Artificial Intelligence Solving problems by searching
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
an incremental version of A*
Problem Solving by Searching Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 3 Spring 2007.
CSE 373, Copyright S. Tanimoto, 2001 Graphs Graphs 2 Incidence and Adjacency Representing a graph with an adjacency matrix, an incidence matrix,
Search Techniques MSc AI module. Search In order to build a system to solve a problem we need to: Define and analyse the problem Acquire the knowledge.
Alford Academy Business Education and Computing1 Advanced Higher Computing Based on Heriot-Watt University Scholar Materials Problem abstraction and symbolic.
Best-First Search: Agendas
Problem Solving and Search in AI Part I Search and Intelligence Search is one of the most powerful approaches to problem solving in AI Search is a universal.
Uninformed Search Reading: Chapter 3 by today, Chapter by Wednesday, 9/12 Homework #2 will be given out on Wednesday DID YOU TURN IN YOUR SURVEY?
Problem Solving and Search in AI Heuristic Search
Using Search in Problem Solving
CSE (c) S. Tanimoto, 2008 State-Space Search 1 State-Space Search Motivation: Understanding “dynamics” in AI Statics versus Dynamics of AI Statics:
Solving problems by searching
CSE (c) S. Tanimoto, 2007 Search 1: State Spaces 1 State-Space Search Outline: Demonstration with T* State spaces, operators, moves A Puzzle: The.
Review: Search problem formulation Initial state Actions Transition model Goal state (or goal test) Path cost What is the optimal solution? What is the.
3.0 State Space Representation of Problems 3.1 Graphs 3.2 Formulating Search Problems 3.3 The 8-Puzzle as an example 3.4 State Space Representation using.
Solving Problems by Searching CPS Outline Problem-solving agents Example problems Basic search algorithms.
CS.462 Artificial Intelligence SOMCHAI THANGSATHITYANGKUL Lecture 02 : Search.
1 Solving problems by searching 171, Class 2 Chapter 3.
Basic Problem Solving Search strategy  Problem can be solved by searching for a solution. An attempt is to transform initial state of a problem into some.
Informed Search Reading: Chapter 4.5 HW #1 out today, due Sept 26th.
Introduction to State Space Search
Search in State Spaces Problem solving as search Search consists of –state space –operators –start state –goal states A Search Tree is an efficient way.
Solving problems by searching A I C h a p t e r 3.
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.
Solving problems by searching Chapter 3. Types of agents Reflex agent Consider how the world IS Choose action based on current percept Do not consider.
ARTIFICIAL INTELLIGENCE
Solving problems by searching
CSE 373, Copyright S. Tanimoto, 2002 Graphs 2 -
Breadth First and Depth First
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.
CSE 473 Artificial Intelligence Oren Etzioni
Introduction to Artificial Intelligence
CSE (c) S. Tanimoto, 2002 Search Algorithms
Artificial Intelligence Lecture No. 6
Introduction Defining the Problem as a State Space Search.
Problem Solving by Searching
Artificial Intelligence Problem solving by searching CSC 361
Problem Reduction -AND-OR Graph -AO* Search CSE 402 K3R23/K3R20.
Lecture 1B: Search.
Problem Solving and Searching
Problem Solving and Searching
BEST FIRST SEARCH -OR Graph -A* Search -Agenda Search CSE 402
CSE (c) S. Tanimoto, 2001 Search-Introduction
Haskell Tips You can turn any function that takes two inputs into an infix operator: mod 7 3 is the same as 7 `mod` 3 takeWhile returns all initial.
Artificial Intelligence
Problem Spaces & Search
(1) Breadth-First Search  S Queue S
Solving problems by searching
HW 1: Warmup Missionaries and Cannibals
Informed Search Idea: be smart about what paths to try.
Problem Spaces & Search
Two – One Problem Legal Moves: Slide Rules: 1s’ move right Hop
HW 1: Warmup Missionaries and Cannibals
Two – One Problem Legal Moves: Slide Rules: 1s’ move right Hop
CSE (c) S. Tanimoto, 2004 State-Space Search
Solving problems by searching
Tree Searching Strategies
CSE (c) S. Tanimoto, 2004 Search Algorithms
Reading: Chapter 4.5 HW#2 out today, due Oct 5th
Informed Search Idea: be smart about what paths to try.
Search Strategies CMPT 420 / CMPG 720.
Solving Problems by Searching
Presentation transcript:

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search Computers should solve problems. A traditional problem domain for AI is the blocks world. Problem description: Given blocks A, B and C, with C on B, arrange the blocks so that A is on B and B is on C. You may only pick up and move one block at a time. A C B A B C ------------ --------------- CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search A state consists of a complete description or snapshot of a situation arrived at during the solution of a problem. Initial state: the starting position or arrangement, prior to any problem-solving actions being taken. Goal state: the final arrangement of elements or pieces that satisfies the requirements for a solution to the problem. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search The set of all possible states of the elements or components to be used in solving a problem forms the space of states for the problem. This is known as the state space. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search Moves A move is a transition from one state to another. An operator is a partial function that can be applied to a state to produce a move. An operator can serve as a type of move. A sequence of moves that leads from the initial state to a goal state constitutes a solution. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search State Representation Possible methods: Board position (for a puzzle or game). List of parameter values. Set of statements in propositional calculus. Set of statements in predicate calculus. B is on the table Ontable(B) C A is on the table Ontable(A) A B C is on B On(C, B) -------------- CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

Operator Preconditions Precondition: A necessary property of a state in which a particular operator can be applied. Example: In checkers, a piece may only move into a square that is vacant. Vacant(place) is a precondition on moving a piece into place. Example: In Chess, a precondition for moving a rook from square A to square B is that all squares between A and B be vacant. (A an B must also be either in the same row or the same column.) CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

The Combinatorial Explosion Suppose a search process begins with the initial state. Then it considers each of k possible moves. Each of those may have k possible subsequent moves. In order to look n steps ahead, the number of states that must be considered is 1 + k + k2 + . . . + kn. For k > 1, this expression grows rapidly as n increase. This is known as the combinatorial explosion. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search Search Trees By applying operators from a given state we generate its children or successors. Successors are descendants as are successors of descendants. If we ignore possible equivalent states among descendants, we get a tree structure. Depth-First Search: Examine the nodes of the tree by fully exploring the descendants of a node before trying any siblings of a node. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search Graph Search When descendant nodes can be reached with moves via two or more paths, we are really searching a more general graph than a tree. Depth-First Search: Examine the nodes of the graph by fully exploring the “descendants” of a node before trying any “siblings” of a node. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

Depth-First Search: Iterative Formulation 1. Put the start state on a list OPEN 2. If OPEN is empty, output “DONE” and stop. 3. Select the first state on OPEN and call it S. Delete S from OPEN. Put S on CLOSED. If S is a goal state, output its description 4. Generate the list L of successors of S and delete from L those states already appearing on CLOSED. 5. Delete any members of OPEN that occur on L. Insert all members of L at the front of OPEN. 6. Go to Step 2. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

Breadth-First Search: Iterative Formulation 1. Put the start state on a list OPEN 2. If OPEN is empty, output “DONE” and stop. 3. Select the first state on OPEN and call it S. Delete S from OPEN. Put S on CLOSED. If S is a goal state, output its description 4. Generate the list L of successors of S and delete from L those states already appearing on CLOSED. 5. Delete any members of OPEN that occur on L. Insert all members of L at the end of OPEN. 6. Go to Step 2. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search

CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search Best-First Search Similar to Depth-first and breadth-first searches. However, the list OPEN is maintained as a priority queue, with each state s on OPEN having a “heuristic value” f(s) such that the smaller f(s) is, the higher is the priority of that state for expansion. f(s) reflects an estimated “cost” of the state s. It can also be thought of as an estimate of a sort of distance between s and the nearest goal state. e.g., “longitude difference” estimates the distance between two cities. CSE 415 -- (c) S. Tanimoto, 2002 State-Space Search