CS.462 Artificial Intelligence SOMCHAI THANGSATHITYANGKUL Lecture 02 : Search.

Slides:



Advertisements
Similar presentations
Artificial Intelligent
Advertisements

Additional Topics ARTIFICIAL INTELLIGENCE
CS344 : Introduction to Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 2 - Search.
Review: Search problem formulation
Announcements Course TA: Danny Kumar
Uninformed search strategies
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal.
Artificial Intelligence By Mr. Ejaz CIIT Sahiwal.
Artificial Intelligence Solving problems by searching
January 26, 2003AI: Chapter 3: Solving Problems by Searching 1 Artificial Intelligence Chapter 3: Solving Problems by Searching Michael Scherger Department.
Problem Solving and Search Andrea Danyluk September 9, 2013.
Problem Solving Agents A problem solving agent is one which decides what actions and states to consider in completing a goal Examples: Finding the shortest.
1 Lecture 3 Uninformed Search. 2 Uninformed search strategies Uninformed: While searching you have no clue whether one non-goal state is better than any.
Solving Problems by Searching Currently at Chapter 3 in the book Will finish today/Monday, Chapter 4 next.
CS 480 Lec 3 Sept 11, 09 Goals: Chapter 3 (uninformed search) project # 1 and # 2 Chapter 4 (heuristic search)
Blind Search1 Solving problems by searching Chapter 3.
CPSC 322, Lecture 5Slide 1 Uninformed Search Computer Science cpsc322, Lecture 5 (Textbook Chpt 3.4) January, 14, 2009.
Search Strategies Reading: Russell’s Chapter 3 1.
1 Lecture 3: 18/4/1435 Uninformed search strategies Lecturer/ Kawther Abas 363CS – Artificial Intelligence.
Implementation and Evaluation of Search Methods. Use a stack data structure. 1. Push root node of tree on the stack. 2. Pop the top node off the stack.
Touring problems Start from Arad, visit each city at least once. What is the state-space formulation? Start from Arad, visit each city exactly once. What.
Artificial Intelligence (CS 461D)
UNINFORMED SEARCH Problem - solving agents Example : Romania  On holiday in Romania ; currently in Arad.  Flight leaves tomorrow from Bucharest.
Artificial Intelligence Lecture No. 7 Dr. Asad Safi ​ Assistant Professor, Department of Computer Science, COMSATS Institute of Information Technology.
Review: Search problem formulation
UnInformed Search What to do when you don’t know anything.
Artificial Intelligence Chapter 3: Solving Problems by Searching
1 Solving Problems by Searching. 2 Terminology State State Space Initial State Goal Test Action Step Cost Path Cost State Change Function State-Space.
Blind Search-Part 2 Ref: Chapter 2. Search Trees The search for a solution can be described by a tree - each node represents one state. The path from.
Uninformed Search (cont.)
Solving problems by searching
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.
Solving Problems by Searching
Artificial Intelligence Course outline Introduction Problem solving Generic algorithms Knowledge Representation and Reasoning Expert Systems Uncertainty.
Review: Search problem formulation Initial state Actions Transition model Goal state (or goal test) Path cost What is the optimal solution? What is the.
Introduction to search Chapter 3. Why study search? §Search is a basis for all AI l search proposed as the basis of intelligence l inference l all learning.
Introduction to search Chapter 3. Why study search? §Search is a basis for all AI l search proposed as the basis of intelligence l all learning algorithms,
CS 344 Artificial Intelligence By Prof: Pushpak Bhattacharya Class on 15/Jan/2007.
CS 415 – A.I. Slide Set 5. Chapter 3 Structures and Strategies for State Space Search – Predicate Calculus: provides a means of describing objects and.
Search Tamara Berg CS 560 Artificial Intelligence Many slides throughout the course adapted from Dan Klein, Stuart Russell, Andrew Moore, Svetlana Lazebnik,
Artificial Intelligence
For Friday Finish reading chapter 4 Homework: –Lisp handout 4.
For Monday Read chapter 4, section 1 No homework..
CS344: Introduction to Artificial Intelligence (associated lab: CS386)
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.
Lecture 3: Uninformed Search
Search CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Lecture 3: 18/4/1435 Searching for solutions. Lecturer/ Kawther Abas 363CS – Artificial Intelligence.
For Friday Read chapter 4, sections 1 and 2 Homework –Chapter 3, exercise 7 –May be done in groups.
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.
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.
1 Solving Problems by Searching. 2 Terminology State State Space Goal Action Cost State Change Function Problem-Solving Agent State-Space Search.
Introduction to Artificial Intelligence (G51IAI) Dr Rong Qu Blind Searches - Introduction.
CPSC 322, Lecture 6Slide 1 Uniformed Search (cont.) Computer Science cpsc322, Lecture 6 (Textbook finish 3.5) Sept, 17, 2012.
Breadth First Search and Depth First Search. Greatest problem in Computer Science Has lead to a lot of new ideas and data structures Search engines before.
Implementation: General Tree Search
CPSC 322, Lecture 5Slide 1 Uninformed Search Computer Science cpsc322, Lecture 5 (Textbook Chpt 3.5) Sept, 13, 2013.
CS621: Artificial Intelligence Pushpak Bhattacharyya CSE Dept., IIT Bombay Lecture 3: Search, A*
Brian Williams, Fall 041 Analysis of Uninformed Search Methods Brian C. Williams Sep 21 st, 2004 Slides adapted from: Tomas Lozano Perez,
For Monday Read chapter 4 exercise 1 No homework.
Artificial Intelligence Solving problems by searching.
ARTIFICIAL INTELLIGENCE
Last time: Problem-Solving
Introduction to Artificial Intelligence
Iterative Deepening Search
Iterative Deepening Search
Artificial Intelligence
Search Exercise Search Tree? Solution (Breadth First Search)?
ARTIFICIAL INTELLIGENCE
Presentation transcript:

CS.462 Artificial Intelligence SOMCHAI THANGSATHITYANGKUL Lecture 02 : Search

Searching for Solutions The state space model provides a formal definition of a problem and what constitutes a solution to a problem. State space is the set of all states reachable from the initial state by any sequence of operators/actions. Operators -- generate new states from existing states A solution is a state (called a goal state) whose attributes have certain properties and maybe a sequence of operators that will change the initial state to a goal state  A solution is found by searching through the state space until a (goal) state with “specific” properties is found Artificial IntelligenceChapter 12

What is a Solution in this type of Search? A solution to a search problem is a sequence of operators that generate a path from the initial state to a goal state. An optimal solution is a minimal cost solution. Solution cost versus search cost -- which one to optimize? Artificial IntelligenceChapter 13

4 A directed graph in state space

5 Three coins problem Given three coins arrange as in the picture, which is the initial state I. These are goal state G.

6 Three coins problem Operation : Flipping the coin one at a time Let A represent flipping the first coin Let B represent flipping the middle coin Let C represent flipping the last coin The search problem: find a path from a state in I to a state in G. Draw the state space Graph

7 Three coins problem State space graph

8 Three coins problem Let put some rule into the problem Rule : Use exactly 3 flips. This means that 1flip cannot reach the goal and 2 flips also cannot reach the goal. For example: state I : HHT  c HHH not goal State I : HHT  B HTT  A TTT not goal Let draw the state space

9 Three coins problem State space tree

10 Search Many AI problems can be formulated as search. Iterative deepening is good when you don’t know much. First Method of Search Uninformed Search

11 Depth First Search (DFS) Search Put start state in the agenda Loop Get a state from the agenda If goal, then return Expand state (put children in agenda) Avoiding loops Don’t add a node to the agenda if it’s already in the agenda Don’t expand a node (or add it to the agenda) if it has already been expanded.

12 DFS Graph:

13 DFS Agenda: –Expansion: put children at top of stack –Get new nodes from top of stack Expand nodeNodes list s {s} {A s,B s,C s }

14 Try this Find a path from node A to the goal nod B. Use DFS method. A B Z O SF C P R T L M D

15 Breadth First Search (BFS) Search Put start state in the agenda Loop Get a state from the agenda If goal, then return Expand state (put children in agenda) Avoiding loops Don’t add a node to the agenda if it’s already in the agenda Don’t expand a node (or add it to the agenda) if it has already been expanded.

16 BFS Graph:

17 BFS Agenda: –Expansion: put children at end of queue –Get new nodes from the front of queue Expand nodeNodes list s {s} {A s,B s,C s }

18 Try this Find a path from node A to the goal nod B. Use BFS method. A B Z O SF C P R T L M D