Chapter 5 Plan-Space Planning

Similar documents
Chapter 5 Plan-Space Planning

Chapter 4 State-Space Planning

1 Nondeterministic Finite Automata

Uninformed Search Lecture 4

Nondeterminism and Nodeterministic Automata

First Midterm Examination

Regular expressions, Finite Automata, transition graphs are all the same!!

Convert the NFA into DFA

CS 188: Artificial Intelligence Spring 2007

Intermediate Math Circles Wednesday, November 14, 2018 Finite Automata II. Nickolas Rollick a b b. a b 4

CSCI 340: Computational Models. Kleene s Theorem. Department of Computer Science

Chapter 2 Finite Automata

19 Optimal behavior: Game theory

Regular Language. Nonregular Languages The Pumping Lemma. The pumping lemma. Regular Language. The pumping lemma. Infinitely long words 3/17/15

Improper Integrals. The First Fundamental Theorem of Calculus, as we ve discussed in class, goes as follows:

Designing finite automata II

Chapter Five: Nondeterministic Finite Automata. Formal Language, chapter 5, slide 1

Lecture 9: LTL and Büchi Automata

CMPSCI 250: Introduction to Computation. Lecture #31: What DFA s Can and Can t Do David Mix Barrington 9 April 2014

We will see what is meant by standard form very shortly

CS415 Compilers. Lexical Analysis and. These slides are based on slides copyrighted by Keith Cooper, Ken Kennedy & Linda Torczon at Rice University

Bases for Vector Spaces

Parse trees, ambiguity, and Chomsky normal form

CS 330 Formal Methods and Models

Review of Gaussian Quadrature method

Reinforcement Learning

Bayesian Networks: Approximate Inference

The area under the graph of f and above the x-axis between a and b is denoted by. f(x) dx. π O

The University of Nottingham SCHOOL OF COMPUTER SCIENCE A LEVEL 2 MODULE, SPRING SEMESTER LANGUAGES AND COMPUTATION ANSWERS

CS 275 Automata and Formal Language Theory

Harvard University Computer Science 121 Midterm October 23, 2012

Fingerprint idea. Assume:

CS103B Handout 18 Winter 2007 February 28, 2007 Finite Automata

Linear Inequalities. Work Sheet 1

An LP-Based Heuristic for Optimal Planning

Homework 4. 0 ε 0. (00) ε 0 ε 0 (00) (11) CS 341: Foundations of Computer Science II Prof. Marvin Nakayama

CSCI 340: Computational Models. Transition Graphs. Department of Computer Science

Lecture 08: Feb. 08, 2019

Formal languages, automata, and theory of computation

Finite Automata. Informatics 2A: Lecture 3. John Longley. 22 September School of Informatics University of Edinburgh

Partial-Order Planning

How do we solve these things, especially when they get complicated? How do we know when a system has a solution, and when is it unique?

1 Online Learning and Regret Minimization

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2014

List all of the possible rational roots of each equation. Then find all solutions (both real and imaginary) of the equation. 1.

Quadratic Forms. Quadratic Forms

2.4 Linear Inequalities and Interval Notation

NFAs and Regular Expressions. NFA-ε, continued. Recall. Last class: Today: Fun:

Minimal DFA. minimal DFA for L starting from any other

CS 373, Spring Solutions to Mock midterm 1 (Based on first midterm in CS 273, Fall 2008.)

From LTL to Symbolically Represented Deterministic Automata

First Midterm Examination

Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Regular Expressions (RE) Kleene-*

p-adic Egyptian Fractions

1B40 Practical Skills

Coalgebra, Lecture 15: Equations for Deterministic Automata

CS S-12 Turing Machine Modifications 1. When we added a stack to NFA to get a PDA, we increased computational power

CS 188 Introduction to Artificial Intelligence Fall 2018 Note 7

Homework 3 Solutions

NFA DFA Example 3 CMSC 330: Organization of Programming Languages. Equivalence of DFAs and NFAs. Equivalence of DFAs and NFAs (cont.

Finite Automata Theory and Formal Languages TMV027/DIT321 LP4 2018

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. NFA for (a b)*abb.

DATA Search I 魏忠钰. 复旦大学大数据学院 School of Data Science, Fudan University. March 7 th, 2018

CMSC 330: Organization of Programming Languages

Types of Finite Automata. CMSC 330: Organization of Programming Languages. Comparing DFAs and NFAs. Comparing DFAs and NFAs (cont.) Finite Automata 2

I1 = I2 I1 = I2 + I3 I1 + I2 = I3 + I4 I 3

CS 330 Formal Methods and Models Dana Richards, George Mason University, Spring 2016 Quiz Solutions

Chapter 0. What is the Lebesgue integral about?

Lecture 2e Orthogonal Complement (pages )

Java II Finite Automata I

Finite Automata. Informatics 2A: Lecture 3. Mary Cryan. 21 September School of Informatics University of Edinburgh

input tape head moves current state

Mathematics Number: Logarithms

Resources. Introduction: Binding. Resource Types. Resource Sharing. The type of a resource denotes its ability to perform different operations

Closure Properties of Regular Languages

Finite Automata-cont d

NON-DETERMINISTIC FSA

More on automata. Michael George. March 24 April 7, 2014

Lexical Analysis Finite Automate

Learning Goals. Relational Query Languages. Formal Relational Query Languages. Formal Query Languages: Relational Algebra and Relational Calculus

Automata Theory 101. Introduction. Outline. Introduction Finite Automata Regular Expressions ω-automata. Ralf Huuck.

Talen en Automaten Test 1, Mon 7 th Dec, h45 17h30

1. For each of the following theorems, give a two or three sentence sketch of how the proof goes or why it is not true.

Vectors , (0,0). 5. A vector is commonly denoted by putting an arrow above its symbol, as in the picture above. Here are some 3-dimensional vectors:

Chapter 6 Techniques of Integration

12.1 Nondeterminism Nondeterministic Finite Automata. a a b ε. CS125 Lecture 12 Fall 2016

Lecture 3: Equivalence Relations

Lecture 3. In this lecture, we will discuss algorithms for solving systems of linear equations.

CS 301. Lecture 04 Regular Expressions. Stephen Checkoway. January 29, 2018

Let's start with an example:

Centrum voor Wiskunde en Informatica REPORTRAPPORT. Supervisory control for nondeterministic systems

Some Theory of Computation Exercises Week 1

Connected-components. Summary of lecture 9. Algorithms and Data Structures Disjoint sets. Example: connected components in graphs

Converting Regular Expressions to Discrete Finite Automata: A Tutorial

Genetic Programming. Outline. Evolutionary Strategies. Evolutionary strategies Genetic programming Summary

CS 311 Homework 3 due 16:30, Thursday, 14 th October 2010

Formal Languages and Automata

Improper Integrals, and Differential Equations

This lecture covers Chapter 8 of HMU: Properties of CFLs

CS:4330 Theory of Computation Spring Regular Languages. Equivalences between Finite automata and REs. Haniel Barbosa

Transcription:

Lecture slides for Automted Plnning: Theory nd Prctice Chpter 5 Pln-Spce Plnning Dn S. Nu CMSC 722, AI Plnning University of Mrylnd, Spring 2008 1

Stte-Spce Plnning Motivtion g 1 1 g 4 4 s 0 g 5 5 g 2 2 g 0 Prolem with stte-spce serch In some cses we my try mny different orderings of the sme ctions efore relizing there is no solution g 3 3 ded end ded end ded end ded end ded end ded end c c c c gol Lest-commitment strtegy: don t commit to orderings, instntitions, etc., until necessry 2

Outline Bsic ide Open gols Threts The PSP lgorithm Long exmple Comments 3

Pln-Spce Plnning - Bsic Ide Bckwrd serch from the gol Ech node of the serch spce is prtil pln» A set of prtilly-instntited ctions» A set of constrints Types of constrints: precedence constrint: must precede inding constrints: foo(x Precond: Effects: p(x x y x = z p(z r(y Precond: p(y Effects: z(z Precond: p(z Effects:» inequlity constrints, e.g., v 1 v 2 or v c» equlity constrints (e.g., v 1 = v 2 or v = c nd/or sustitutions cusl link:» use ction to estlish the precondition p needed y ction 4

Pln-Spce Serch Initil pln Strt with n initil pln (will explin this lter Mke more nd more refinements to the pln, until solution is found If there re no refinements to pln during serch, then cktrck d d d c c c Questions: How to tell we hve solution?» No more flws in the pln How to refine pln?» Resolve the existing flws e d Fil! Solution! 5

Open gol: An ction hs precondition p tht we hven t decided how to estlish foo(x Precond: Effects: p(x Find n ction Resolving the flw: (either lredy in the pln, or insert it tht cn e used to estlish p cn precede nd produce p Instntite vriles nd/or constrin vrile indings Crete cusl link Flws: 1. Open Gols foo(x Precond: Effects: p(x p(z p(x z(z Precond: p(z Effects: z(x Precond: p(x Effects: 6

Flws: 2. Threts Thret: deleted-condition interction Action estlishes precondition (e.g., pq(x of ction Another ction c is cple of deleting p Resolving the flw: impose constrint to prevent c from deleting p cloer(y Precond: Effects: pq(y Three possiilities: Mke precede c Mke c precede foo(x Precond: Effects: pq(x pq(x z(x Precond: pq(x Effects: Constrin vrile(s to prevent c from deleting p 7

Initil pln The PSP Procedure d c d c d c e d Fil! Solution! PSP is oth sound nd complete It returns prtilly ordered solution pln Any totl ordering of this pln will chieve the gols Or could execute ctions in prllel if the environment permits it 8

Exmple Similr (ut not identicl to n exmple in Russell nd Norvig s Artificil Intelligence: A Modern Approch (1st edition Opertors: Strt Precond: none Effects:, sells(hws,drill, Sells(SM,Milk, Sells(SM,Bnn Finish Precond: Hve(Drill, Hve(Milk, Hve(Bnn, Effects: none Go(l,m Precond: At(l Effects: At(m, At(l Buy(p,s Precond: At(s, Sells(s,p Effects: Hve(p Strt nd Finish re dummy ctions tht we ll use insted of the initil stte nd gol 9

Exmple (continued Need to give PSP pln π s its rgument Initil pln: Strt, Finish, nd n ordering constrint Strt Effects:, Sells(HWS,Drill, Sells(SM,Milk, Sells(SM,Bnns Precond: Hve(Drill Hve(Milk Hve(Bnns Finish 10

Exmple (continued The first three refinement steps These re the only possile wys to estlish the Hve preconditions Strt At(s 1 Sells(s 1, Drill At(s 2 Sells(s 2,Milk At(s 3 Sells(s 3,Bnns Buy(Drill, s 1 Buy(Milk, s 2 Buy(Bnns, s 2 Hve(Drill Hve(Milk Hve(Bnns Finish 11

Exmple (continued Three more refinement steps The only possile wys to estlish the Sells preconditions Strt At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish 12

Exmple (continued Two more refinements: the only wys to estlish At(HWS nd At(SM This time, severl threts occur Strt At(l 2 At(l 1 Go(l 2, SM Go(l 1,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish 13

Exmple (continued Finlly, nondeterministic choice: how to resolve the thret to At(s 1? Our choice: mke Buy(Drill precede Go(SM This lso resolves the other two threts Strt At(l 2 At(l 1 Go(l 2, SM Go(l 1,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish 14

Exmple (continued Nondeterministic choice: how to estlish At(l 1? We ll do it from Strt, with l 1 =Home Strt At(l 2 Go(l 2, SM Go(Home,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish 15

Exmple (continued Nondeterministic choice: how to estlish At(l 2? We ll do it from Go(Home,HWS, with l 2 = HWS Strt At(HWS Go(HWS, SM Go(Home,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish 16

Exmple (continued The only possile wy to estlish for Finish This cretes unch of threts Strt At(HWS Go(HWS, SM Go(Home,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Go(l 3, Home Hve(Drill Hve(Milk Hve(Bnns Finish 17

Exmple (continued To remove the threts to At(SM nd At(HWS, mke them precede Go(l 3,Home This lso removes the other threts Strt At(HWS Go(HWS, SM Go(Home,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Go(l 3, Home Hve(Drill Hve(Milk Hve(Bnns Finish 18

Estlish At(l 3 with l 3 =SM Finl Pln Strt At(HWS Go(HWS, SM Go(Home,HWS At(HWS Sells(HWS,Drill At(SM Sells(SM,Milk At(SM Sells(SM,Bnns Buy(Drill, HWS s 1 Buy(Milk, SM Buy(Bnns, SM Hve(Drill Hve(Milk Hve(Bnns Finish Go(SM, Home 19

Discussion How to choose which flw to resolve first nd how to resolve it? We ll return to these questions in Chpter 10 PSP doesn t commit to orderings nd instntitions until necessry Avoids generting serch trees like this one: c Prolem: how to prune infinitely long pths? In stte-spce plnning, loop detection is sed on recognizing sttes we ve seen efore In prtilly ordered pln, we don t know the sttes c c c gol Cn we prune if we see the sme ction more thn once? go(, go(, go(, t( No. Sometimes we might need the sme ction severl times in different sttes of the world (see next slide 20

Exmple 3-digit inry counter strts t 000, wnt to get to 110 s 0 = {d3=0, d2=0, d1=0} g = {d3=1, d2=1, d1=0} Opertors to increment the counter y 1: incr0 Precond: d 1 =0 Effects: d 1 =1 incr01 Precond: d 2 =0, d 1 =1 Effects: d 2 =1, d 1 =0 incr011 Precond: d 3 =0, d 2 =1, d 1 =1 Effects: d 3 =1, d 2 =0, d 1 =0 21

A Wek Pruning Technique Cn prune ll prtil plns of n or more ctions, where n = {ll possile sttes} This doesn t help very much There s no good pruning technique for pln-spce plnning Russell nd Norvig s Artificil Intelligence: A Modern Approch descries preliminry pproch In erly 90 s, reserchers hve looked t lerning pruning rules during PSP plnning 22