Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 3 of 41 Wednesday 25.

Slides:



Advertisements
Similar presentations
Announcements Course TA: Danny Kumar
Advertisements

Problem Solving by Searching Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 3 Spring 2007.
Part2 AI as Representation and Search
Solving Problem by Searching Chapter 3. Outline Problem-solving agents Problem formulation Example problems Basic search algorithms – blind search Heuristic.
Computing & Information Sciences Kansas State University Lecture 4 of 42 CIS 530 / 730 Artificial Intelligence Lecture 4 of 42 William H. Hsu Department.
CHAPTER 3 CMPT Blind Search 1 Search and Sequential Action.
An Introduction to Artificial Intelligence Lecture 3: Solving Problems by Sorting Ramin Halavati In which we look at how an agent.
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.
A RTIFICIAL I NTELLIGENCE Problem-Solving Solving problems by searching.
CS 380: Artificial Intelligence Lecture #3 William Regli.
Search Problems Russell and Norvig: Chapter 3, Sections 3.1 – 3.3 Slides adapted from: robotics.stanford.edu/~latombe/cs121/2003/home.htm by Prof. Jean-Claude.
Problem Solving by Searching Copyright, 1996 © Dale Carnegie & Associates, Inc. Chapter 3 Spring 2004.
Artificial Intelligence Chapter 3: Solving Problems by Searching
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?
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.
Copyright R. Weber Search in Problem Solving Search in Problem Solving INFO 629 Dr. R. Weber.
1 Problem Solving and Searching CS 171/271 (Chapter 3) Some text and images in these slides were drawn from Russel & Norvig’s published material.
Solving Problems by Searching CPS Outline Problem-solving agents Example problems Basic search algorithms.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 26 of 41 Friday, 22 October.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 3 Wednesday 27 August.
Computing & Information Sciences Kansas State University Lecture 2 of 42 CIS 530 / 730 Artificial Intelligence Lecture 2 of 42 William H. Hsu Department.
1 Solving problems by searching This Lecture Chapters 3.1 to 3.4 Next Lecture Chapter 3.5 to 3.7 (Please read lecture topic material before and after each.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 9 of 14 Friday, 10 September.
Dr.Abeer Mahmoud ARTIFICIAL INTELLIGENCE (CS 461D) Dr. Abeer Mahmoud Computer science Department Princess Nora University Faculty of Computer & Information.
Computing & Information Sciences Kansas State University Wednesday, 15 Oct 2008CIS 530 / 730: Artificial Intelligence Lecture 20 of 42 Wednesday, 15 October.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 2 Tuesday, August 29,
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 21 of 41 Wednesday, 08.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 2 of 41 Monday, 23 August.
Computing & Information Sciences Kansas State University Wednesday, 25 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 26 of 42 Wednesday. 25 October.
Lecture 2 of 42 Problem Solving by Search
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 13 of 41 Monday, 20 September.
1 Solving problems by searching 171, Class 2 Chapter 3.
Computing & Information Sciences Kansas State University Wednesday, 30 Aug 2006CIS 490 / 730: Artificial Intelligence Lecture 4 of 42 Wednesday, 30 August.
Search CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 9 of 42 Wednesday, 14.
An Introduction to Artificial Intelligence Lecture 3: Solving Problems by Sorting Ramin Halavati In which we look at how an agent.
SOLVING PROBLEMS BY SEARCHING Chapter 3 August 2008 Blind Search 1.
A General Introduction to Artificial Intelligence.
Problem solving by search Department of Computer Science & Engineering Indian Institute of Technology Kharagpur.
Artificial Intelligence
For Friday Read chapter 4, sections 1 and 2 Homework –Chapter 3, exercise 7 –May be done in groups.
Uninformed Search ECE457 Applied Artificial Intelligence Spring 2007 Lecture #2.
Goal-based Problem Solving Goal formation Based upon the current situation and performance measures. Result is moving into a desirable state (goal state).
Informed Search Reading: Chapter 4.5 HW #1 out today, due Sept 26th.
CPSC 420 – Artificial Intelligence Texas A & M University Lecture 3 Lecturer: Laurie webster II, M.S.S.E., M.S.E.e., M.S.BME, Ph.D., P.E.
Artificial Intelligence Lecture No. 6 Dr. Asad Ali Safi ​ Assistant Professor, Department of Computer Science, COMSATS Institute of Information Technology.
Computing & Information Sciences Kansas State University Monday, 23 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 25 of 42 Monday, 23 October.
Computing & Information Sciences Kansas State University Friday, 20 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 24 of 42 Friday, 20 October.
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.
Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 5 of 41 Wednesday 03.
Computing & Information Sciences Kansas State University Friday, 08 Sep 2006CIS 490 / 730: Artificial Intelligence Lecture 7 of 42 Friday, 08 September.
Solving problems by searching A I C h a p t e r 3.
Computing & Information Sciences Kansas State University Monday, 09 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 19 of 42 Monday, 09 October.
G5AIAI Introduction to AI
Computing & Information Sciences Kansas State University Wednesday, 04 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 17 of 42 Wednesday, 04 October.
Lecture 2: Problem Solving using State Space Representation CS 271: Fall, 2008.
Computing & Information Sciences Kansas State University Friday, 13 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 21 of 42 Friday, 13 October.
Biointelligence Lab School of Computer Sci. & Eng. Seoul National University Artificial Intelligence Chapter 8 Uninformed Search.
Computing & Information Sciences Kansas State University Wednesday, 25 Oct 2006CIS 490 / 730: Artificial Intelligence Lecture 26 of 42 Wednesday. 25 October.
Introduction to Artificial Intelligence
Artificial Intelligence Lecture No. 6
Problem Solving by Searching
Artificial Intelligence
Artificial Intelligence
CS 2710, ISSP 2160 Foundations of Artificial Intelligence
EA C461 – Artificial Intelligence Problem Solving Agents
ECE457 Applied Artificial Intelligence Fall 2007 Lecture #2
Solving Problems by Searching
Presentation transcript:

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture 3 of 41 Wednesday 25 August 2004 William H. Hsu Department of Computing and Information Sciences, KSU Reading for Next Class: Sections , Russell and Norvig Search and Constraints

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Lecture Outline Today’s Reading: Sections , Russell and Norvig 2e Thinking Exercises (Discussion): p, , 3.9, 3.10 Solving Problems by Searching –Problem solving agents: design, specification, implementation –Specification components Problems – formulating well-defined ones Solutions – requirements, constraints –Measuring performance Formulating Problems as (State Space) Search with Backtracking Example Search Problems –Toy problems: 8-puzzle, 8-queens, cryptarithmetic, robot worlds –Real-world problems: layout, scheduling Today: Data Structures, Uninformed Search (DFS, BFS, B&B) Friday: Informed Search Strategies (see handouts)

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Agent Frameworks: Utility-Based Agents Agent Sensors Effectors Utility What action I should do now Environment State How world evolves What my actions do What world is like now What it will be like if I do A How happy will I be

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Review: Problem-Solving Agents function Simple-Problem-Solving-Agent (p: percept) returns a: action –inputs: p, percept –static:s, action sequence (initially empty) state, description of current world state g, goal (initially null) problem, problem formulation –state  Update-State (state, p) –if s.Is-Empty() then g  Formulate-Goal (state)// focus of today’s class problem  Formulate-Problem (state, g)// focus of today’s class s  Search (problem)// next 3 classes –action  Recommendation (s, state) –s  Remainder (s, state)// discussion: meaning? –return (action) Chapters 3-4: Implementation of Simple-Problem-Solving-Agent

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Formulating Problems [1]: Single versus Multi-State Single-State Problems –Goal state is reachable in one action (one move) –World is fully accessible –Example: vacuum world (Figure 3.2, R&N) – simple robot world –Significance Initial step analysis “Base case” for problem solving by regression (General Problem Solver) Multi-State Problems –Goal state may not be reachable in one action –Assume limited access: effects of actions known (may or may not have sensors) –Significance Need to reason over states that agent can get to May be able to guarantee reachability of goal state anyway Determining A State Space Formulation –State space – single-state problem –State set space – multi-state problems

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Defining Problems Definition –Collection of information used by agent to decide on actions –First specification: single-state problem State Space: Definitions –State space: set of states reachable from initial state by any action sequence –Path: sequence of actions leading from one state to another Given –Initial state: agent’s knowledge of current location, situation of world –Operator set: agent’s knowledge of possible action Operator: description of action in terms of state transition mapping Successor function: alternative formulation – reachable states in one action –Goal test: boolean test for termination (e.g., explicit set of “accepting” states) –Path cost function: sum, g, of individual costs over sequence of actions datatype Problem of (Initial-State, Operators, Goal-Test, Cost-Function)

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Defining Solutions What Is A Solution? –Based on previous problem definition –Requirements Satisfies goal test Consists of sequence of legal actions –Possible constraints (criteria) Plausibility: adaptation of “legal” to uncertain domains Optimality: path cost minimization (online) Efficiency: search (offline) Towards Finding Solutions –State space search Process: systematic exploration of representation of state space One implementation: graph search –Subject to objectives: requirements, possible constraints

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Measuring Problem-Solving Performance Search Cost –Measures cost of applying actions Some typical units: time, computer memory (primary / secondary) Incurred during interaction with environment –Called offline cost in theoretical computer science –Incurred during interaction with environment –Formal analytical indicator of search cost: asymptotic complexity Path Cost –Measures cost of applying actions Some typical units: distance, energy, resources, risk (e.g., micromorts) Often attributed (as satellite data) to edges of state space graph –Called online cost in theoretical computer science –Incurred during interaction with environment –Discussion: is path cost always incurred “later”? Total Cost = Search Cost + Path Cost

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Choosing States and Actions Intuitive Ideas –Now have: specification of problem, solution –Example: “Drive from A to B using the roads in the map in Figure 3.3 R&N” –How to determine path cost function? Depends on goals Example 1: total mileage Example 2: expected travel time Examples 3a, 3b: cities visited (positive or negative?!) May itself be problem to be optimized (by search!) –What aspects of world state should be represented? Again, depends: on details of operators, states needed to make decisions Example: traveling companions, radio broadcast, resources (food / fuel) Example: Navigation (Simplified Single-Pairs Shortest Path) –Suppose path cost is number of cities visited (to be minimized) –What assumptions are made? (hint: what does agent know?) –Is regression (abstraction in problem formulation) needed in “real life”?

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Abstraction in AI Why Not Exhaustively Represent World? –Too much detail – intractable: Representation Problem solving (e.g., search and decision problems) –Not feasible to implement perception of state of world Sampling (sensor bandwidth) Updating (memory bandwidth) Eliminating Irrelevant Detail –Eliminate granularity (e.g., frequency of measurement, aka resolution) Spatial (location, distance) Temporal (time, ordering of events) –What to reduce Precision of measurements Exactness or crispness of qualitative and quantitative assertions Some times need to do this in vague domains anyway (what is “vague”?) Discussion: How Can Abstraction Be Generalized to Other Problems?

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Toy Problem Example [1]: 8-Puzzle Objectives (Informal) –Given: permutation of 8 squares plus “blank”, allowable moves (of blank) –Achieve: specified ordering (1, 2, 3, 4, 5, 6, 7, 8,_) States –(x, n) denoting that square n is at x –Could also use Cartesian coordinates – ramifications? –Initial state: “scrambled” but a reachable permutation Operators –Move blank –Precondition: (x, n), (x’, _) –Assert: (x’, n), (x, _) – here’s where representation helps… –Delete: (x, n) Goal Test: Specified Ordering Achieved? –How to represent test? –Efficiency issues? Path Cost: Number of Moves

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Toy Problem Example [2]: Simple Constraint Problems Missionaries and Cannibals (Microserfs and Open Source Advocates) –Objectives (informal) Given: M1, M2, M3, C1, C2, C3, 2-person canoe (holds 1-2 people) Achieve: all people on opposite bank without violating constraint –States: people on each bank (exercise: better rep?) –Operators: ferry (Passenger-1, Passenger-2) Parity can be implicit or not Constraint on postcondition: cannibals can’t outnumber missionaries on bank –Goal test: trivial –Discussion: Farmer, Fox, Goose, Grain –Objectives (informal): (F,X,G,R | empty)  (empty | F,X,G,R) –States: entities on each side –Operators: ferry (Entity-1, Entity-2) –Goal test: unique final state (equality) Other Constraint Problems: Cryparithmetic, Monkeys and Bananas

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Real-World Problems Route Finding –Objectives (informal): finding shortest path for situated agent – exploration cost –States: graph representation (see Machine Problem 1); implicit representations –Operators: move from location to location; other degrees of freedom (navigation) –Goal test: “are we there yet?”; “did we get there in time?”; “found target?” Travelling Salesperson Problems (TSP) and Other Touring Problems –aka Hamiltonian tour –Objectives (informal): finding shortest cost tour that visits all v  V exactly once –States: current location in V of agent –Operators: visit a neighbor (constraint: previously unvisited) –Goal test: Other –Very Large-Scale Integrated (VLSI) circuit layout –Robot navigation –Assembly sequencing (possible real-time scheduling application)

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Blind Search Example (Russell and Norvig)

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Terminology State Space Search –Initial state / conditions, goal test, operator set, path costs –Graph formulation Definitions: vertex (node) set V, edge (link, arc) set E  V  V Unbounded graphs: infinite V, E sets Constraint Satisfaction Problems Uninformed (Blind) Search Algorithms –Properties of algorithms: completeness, optimality, optimal efficiency –Depth-first search (DFS): “British Museum” search –“Breadth-first search (BFS) –Branch-and-bound search – from operations research (OR) Problems –Dealing with path costs –Heuristics (next)

Kansas State University Department of Computing and Information Sciences CIS 730: Introduction to Artificial Intelligence Summary Points Today’s Reading: Sections , Russell and Norvig Solving Problems by Searching –Problem solving agents: design, specification, implementation –Specification components Problems – formulating well-defined ones Solutions – requirements, constraints –Measuring performance Formulating Problems as (State Space) Search Example Search Problems –Toy problems: 8-puzzle, 8-queens, cryptarithmetic, toy robot worlds, constraints –Real-world problems: layout, scheduling Data Structures Used in Search Uninformed Search Algorithms: BFS, DFS, Branch-and-Bound Next Tuesday: Informed Search Strategies –State space search handout (Winston) –Search handouts (Ginsberg, Rich and Knight)