ULB, November 2004 As cheap as possible: Linearly Priced Timed Automata Gerd Behrmann, Ed Brinksma, Ansgar Fehnker, Thomas Hune, Kim Larsen, Paul Pettersson,

Slides:



Advertisements
Similar presentations
BEST FIRST SEARCH - BeFS
Advertisements

Clocked Mazurkiewicz Traces and Partial Order Reductions for Timed Automata D. Lugiez, P. Niebert, S. Zennou Laboratoire d Informatique Fondamentale de.
Chapter 4: Informed Heuristic Search
Review: Search problem formulation
Real-Time Systems, DTU, Feb 15, 2000 Paul Pettersson, BRICS, Aalborg, Denmark. Timed Automata and Timed Computation Tree Logic Paul Pettersson
UCb Symbolic Reachability and Beyound or how UPPAAL really works Kim Guldstrand Larsen
A* Search. 2 Tree search algorithms Basic idea: Exploration of state space by generating successors of already-explored states (a.k.a.~expanding states).
Formal methods & Tools UCb CUPPAAL CUPPAAL Efficient Minimum-Cost Reachability for Linearly Priced Timed Automata Gerd Behrman, Ed Brinksma, Ansgar Fehnker,
Greedy best-first search Use the heuristic function to rank the nodes Search strategy –Expand node with lowest h-value Greedily trying to find the least-cost.
ECE 667 Synthesis and Verification of Digital Circuits
SAT Based Abstraction/Refinement in Model-Checking Based on work by E. Clarke, A. Gupta, J. Kukula, O. Strichman (CAV’02)
Informed Search Methods How can we improve searching strategy by using intelligence? Map example: Heuristic: Expand those nodes closest in “as the crow.
UPPAAL Introduction Chien-Liang Chen.
Hybrid System Verification Synchronous Workshop 2003 A New Verification Algorithm for Planar Differential Inclusions Gordon Pace University of Malta December.
Timed Automata.
UPPAAL Andreas Hadiyono Arrummaisha Adrifina Harya Iswara Aditya Wibowo Juwita Utami Putri.
ISE480 Sequencing and Scheduling Izmir University of Economics ISE Fall Semestre.
Efficient Reachability Analysis for Verification of Asynchronous Systems Nishant Sinha.
Hybrid Approach to Model-Checking of Timed Automata DAT4 Project Proposal Supervisor: Alexandre David.
ICS-171:Notes 4: 1 Notes 4: Optimal Search ICS 171 Summer 1999.
Biointelligence Lab School of Computer Sci. & Eng. Seoul National University Artificial Intelligence Chapter 8 Uninformed Search.
CSC 423 ARTIFICIAL INTELLIGENCE
Search in AI.
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
UCb Tools and Application of Timed Automata UPPAAL & Optimal Scheduling Kim G. Larsen
Planning under Uncertainty
Reachability, Schedulability and Optimality
Review: Search problem formulation
MAE 552 – Heuristic Optimization Lecture 27 April 3, 2002
Scheduling Using Timed Automata Borzoo Bonakdarpour Wednesday, April 13, 2005 Selected Topics in Algorithms and Complexity (CSE960)
1 Planning and Scheduling to Minimize Tardiness John Hooker Carnegie Mellon University September 2005.
1 Verification Options & Beyond Reachability or how to make UPPAAL perform better and more Kim Guldstrand Larsen
CHAPTER 10 Recursion. 2 Recursive Thinking Recursion is a programming technique in which a method can call itself to solve a problem A recursive definition.
1 Efficient Verification of Timed Automata Kim Guldstrand Larsen Paul PetterssonMogens Nielsen
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.
State-Space Searches.
Review: Search problem formulation Initial state Actions Transition model Goal state (or goal test) Path cost What is the optimal solution? What is the.
UPPAAL Ghaith Haddad. Introduction UPPAAL is a tool for modeling, validation and verification of real-time systems. Appropriate for systems that can be.
1 Outline:  Outline of the algorithm  MILP formulation  Experimental Results  Conclusions and Remarks Advances in solving scheduling problems with.
Transformation of Timed Automata into Mixed Integer Linear Programs Sebastian Panek.
Department of Mechanical Engineering The University of Strathclyde, Glasgow Hybrid Systems: Modelling, Analysis and Control Yan Pang Department of Mechanical.
Dina Workshop Analysing Properties of Hybrid Systems Rafael Wisniewski Aalborg University.
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.
CIS 540 Principles of Embedded Computation Spring Instructor: Rajeev Alur
For Monday Read chapter 4, section 1 No homework..
BLAST: Basic Local Alignment Search Tool Altschul et al. J. Mol Bio CS 466 Saurabh Sinha.
Real-Time Model Checking on Secondary Storage Stefan Edelkamp and Shahid Jabbar Chair for Programming Systems and Compiler Construction Computer Science.
Lecture 3: Uninformed Search
1 Outline:  Optimization of Timed Systems  TA-Modeling of Scheduling Tasks  Transformation of TA into Mixed-Integer Programs  Tree Search for TA using.
Neural Heuristics For Problem Solving: Using ANNs to Develop Heuristics for the 8-Puzzle by Bambridge E. Peterson.
Scheduling Lacquer Productions with Uppaal AXXOM case study of the Ametist project Angelika Mader Distributed and Embedded Systems Group, University of.
1 Model Checking of of Timed Systems Rajeev Alur University of Pennsylvania.
Slides by: Eric Ringger, adapted from slides by Stuart Russell of UC Berkeley. CS 312: Algorithm Design & Analysis Lecture #36: Best-first State- space.
Ricochet Robots Mitch Powell Daniel Tilgner. Abstract Ricochet robots is a board game created in Germany in A player is given 30 seconds to find.
Prof. Yuan-Shyi Peter Chiu
CS 312: Algorithm Analysis Lecture #33: Branch and Bound, Job Assignment This work is licensed under a Creative Commons Attribution-Share Alike 3.0 Unported.
1 ECE 517: Reinforcement Learning in Artificial Intelligence Lecture 21: Dynamic Multi-Criteria RL problems Dr. Itamar Arel College of Engineering Department.
ECE/CS 584: Verification of Embedded Computing Systems Model Checking Timed Automata Sayan Mitra Lecture 09.
IE 312 Review 1. The Process 2 Problem Model Conclusions Problem Formulation Analysis.
Solving problems by searching A I C h a p t e r 3.
Adversarial Search 2 (Game Playing)
Biointelligence Lab School of Computer Sci. & Eng. Seoul National University Artificial Intelligence Chapter 8 Uninformed Search.
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.
Instructor: Rajeev Alur
On Using Linearly Priced Timed Automata for Flow Analysis
Timed Automata Formal Systems Pallab Dasgupta Professor,
Alternating tree Automata and Parity games
Artificial Intelligence
CMSC 471 Fall 2011 Class #4 Tue 9/13/11 Uninformed Search
Presentation transcript:

ULB, November 2004 As cheap as possible: Linearly Priced Timed Automata Gerd Behrmann, Ed Brinksma, Ansgar Fehnker, Thomas Hune, Kim Larsen, Paul Pettersson, Judi Romijn, Frits Vaandrager Brics Aalborg, Nijmegen, Twente, Uppsala, CMU, TERMA, TUE

ULB, November 2004 Observation (VHS project) Many scheduling problems can be phrased in a natural way as reachability problems for timed automata. Unsafe Safe 25min20min10min5min Can they make it within 60 minutes ? Motivation

ULB, November 2004 unsafe L==0 take! y:=0 y>=25 release! L==1 take! y:=0 y>=25 release! safe Unsafe Safe 25min20min10min5min Can they make it within 60 minutes ? What is the fastest schedule? unsafe L==0 take! y:=0 y>=20 release! L==1 take! y:=0 y>=25 release! safe unsafe L==0 take! y:=0 y>=5 release! L==1 take! y:=0 y>=25 release! safe unsafe L==0 take! y:=0 y>=10 release! L==1 take! y:=0 y>=25 release! safe take? release? take? release? Motivation What schedule minmizes unsafe time? What schedule minimizes bridge crossings?

ULB, November 2004 Outline Timed Automata (A review) Linearly Priced Timed Automata –A basic Algorithm –Efficient Data Structures Uniformly Priced Timed Automata –More efficient Data Structures Improved State-Space Exploration –Minimum-Cost Order Search, Estimates of Remaining Cost, Heuristics Results –Bridge Problem –Job-Shop Problems –Aircraft Landing –others Conclusion

ULB, November 2004 Network of Automata –Synchronization (CCS-like) a!a? Timed Automata (UPPAAL)

ULB, November 2004 a? y = 4 y:=0 a! 3 < x < 7 x < 7 Timed Automata (UPPAAL) Network of Automata –Synchronization (CCS-like) Clocks in description –Time passes uniformly –Guard/reset on action -Invariants on location Infinitely many states!

ULB, November 2004 Regions (review) An equivalence class (i.e. a region). In fact there is only a finite number of regions!! x y Alur & Dill x<3 y>2 a b c 3 x y x y {x:=0} x<3

ULB, November 2004 x Regions (review) Transitions with and w/o reset and delay can be considered as transitions on regions! y 12 Alur & Dill x<3 y>2 a b c 3 x y x y x<3 {x:=0}

ULB, November 2004 Data Structures like DBMs, CDDs  efficiency! x Zones (review) Convex unions of regions are called zones. Delay, reset, transition in terms of zones y 12 x<3 y>2 x<3 a b c 3 x y x y {x:=0}

ULB, November 2004 Problem: Finding the minimum cost of reaching location c Linearly Priced Timed Automata Timed Automata + Costs on transitions and locations –Cost of performing transition: Transition cost –Cost of performing delay d: ( d x location cost ) (a,x=y=0)(b,x=y=0)(b,x=y=2.5)  (2.5) (a,x=0,y=2.5) 42.5 x 20 Cost of Execution Trace: Sum of costs: = 9 Trace: b x<3 y>2 x<3 {x:=0} a c cost’=1 cost+=4 cost’=0 cost’=2

ULB, November 2004 Example: Aircraft Landing cost t E LT E earliest landing time T target time L latest time e cost rate for being early l cost rate for being late d fixed cost for being late e*(T-t) d+l*(t-T) Planes have to keep separation distance to avoid turbulences caused by preceding planes

ULB, November 2004 Example: Aircraft Landing Planes have to keep separation distance to avoid turbulences caused by preceding planes land! x >= 4 x=5 x <= 5 x=5 x <= 5 land! x <= 9 cost+=2 cost’=3cost’=1 4 earliest landing time 5 target time 9 latest time 3 cost rate for being early 1 cost rate for being late 2 fixed cost for being late

ULB, November 2004 Priced Regions cost

ULB, November 2004 Priced Regions cost

ULB, November 2004 x y costs Priced Regions cost

ULB, November 2004 An Algorithm State-Space Exploration + Use of global variable Cost Updated Cost whenever goal state with min( C ) < Cost is found: Terminates when entire state-space is explored 80 Cost=80 60 Cost=60 Cost= 

ULB, November 2004 An Algorithm Cost:= , Pass := {}, Wait := {(l 0,C 0 )}, Goal=  while Wait  {} do select (l,C) from Wait if (l,C) =  and mincost(C)<Cost then Cost:=mincost(C) if forall (l,C’) in Pass: C’ C then add (l,C) to Pass forall (m,D) such that (l,C) (m,D): add (m,D) to Wait Return Cost

ULB, November 2004 An Algorithm Performs: symbolic operations Delay, Conjun- ction, and Reset of clocks. Cost:= , Pass := {}, Wait := {(l 0,C 0 )}, Goal=  while Wait  {} do select (l,C) from Wait if (l,C) =  and mincost(C)<Cost then Cost:=mincost(C) if forall (l’,C’) in Pass: C’ C then add (l,C) to Pass forall (m,D) such that (l,C) (m,D): add (m,D) to Wait Return Cost

ULB, November 2004 Cost:= , Pass := {}, Wait := {(l 0,C 0 )}, Goal=  while Wait  {} do select (l,C) from Wait if (l,C) =  and mincost(C)<Cost then Cost:=mincost(C) if forall (l’,C’) in Pass: C’ C then add (l,C) to Pass forall (m,D) such that (l,C) (m,D): add (m,D) to Wait Return Cost : preorder that defines “better” cost zones. An Algorithm

ULB, November 2004 An Algorithm Cost:= , Pass := {}, Wait := {(l 0,C 0 )}, Goal=  while Wait  {} do select (l,C) from Wait if (l,C) =  and mincost(C)<Cost then Cost:=mincost(C) if forall (l’,C’) in Pass: C’ C then add (l,C) to Pass forall (m,D) such that (l,C) (m,D): add (m,D) to Wait Return Cost

ULB, November 2004 An Algorithm Theorem When the algorithm terminates, the value of COST equals mincost(  ) Theorem The algorithm terminates Can it be done efficiently?

ULB, November 2004 Outline Timed Automata. (A review} Linearly Priced Timed Automata –A basic Algorithm –Efficient Data Structures Uniformly Priced timed Automata –More efficient Data Structures Improved State-Space Exploration –Minimum-Cost Order Search, Estimates of Remaining Cost, Heuristics Results –Bridge Problem –Job-Shop Problems –Aircraft Landing –others Conclusion

ULB, November 2004 Priced Zones Basic idea: Define a linear cost function on zones cost=c+a x + a y xy x y BUT: Priced zones are not closed under delay, transitions, resets

ULB, November 2004 Priced Zones Basic idea: Define a linear cost function on zones cost=c+2 x – 1 y x<3 y>2 x<3 {x:=0} a c cost’=1 cost+=4 cost’=0 cost’=2 b x y BUT: Priced zones are not closed under delay, transitions, resets cost=c’+2 x – 0 y cost=c’’+3 x – 1 y

ULB, November 2004 Priced Zones Basic idea: Define a linear cost function on zones cost=c+2 x – 1 y x<3 y>2 x<3 {x:=0} a c cost’=1 cost+=4 cost’=0 cost’=2 b x y BUT: Priced zones are not closed under delay, transitions, resets

ULB, November 2004 Priced Zones Basic idea: Define a linear cost function on zones cost=c’+2 x – 2 y x<3 y>2 x<3 {x:=0} a c cost’=1 cost+=4 cost’=0 cost’=2 b x y BUT: Priced zones are not closed under delay, transitions, resets cost=c’’+1 x – 1 y

ULB, November 2004 Priced Zones Basic idea: Define a linear cost function on zones x y BUT: Priced zones are not closed under delay, transitions, resets cost=c+2 x – 1 y x<3 y>2 x<3 {x:=0} a c cost’=1 cost+=4 cost’=0 cost’=2 b cost=c’ – 1 y cost=c’’ + 1 y

ULB, November 2004 Outline Timed Automata. (A review} Linearly Priced Timed Automata –A basic Algorithm –Efficient Data Structures Uniformly Priced Timed Automata –More efficient Data Structures Improved State-Space Exploration –Minimum-Cost Order Search, Estimates of Remaining Cost, Heuristics Results –Bridge Problem –Job-Shop Problems –Aircraft Landing –others Conclusion

ULB, November 2004 Unsafe Safe 25min20min10min5min What is the fastest schedule ? Uniformly Priced Timed Automata UPTA are LPTA where all locations have the same rate

ULB, November 2004 Uniformly Priced Timed Automata UPTA are LPTA where all locations have the same rate Result A small modification of the DBM-operations for ordinary timed automata is sufficient to solve cost (time) optimality problems

ULB, November 2004 Outline Timed Automata. (A review} Linearly Priced Timed Automata –A basic Algorithm –Efficient Data Structures Uniformly Priced Timed Automata –More efficient Data Structures Improved State-Space Exploration –Minimum-Cost Order Search, Estimates of Remaining Cost, Heuristics Results –Bridge Problem –Job-Shop Problems –Aircraft Landing –others Conclusion

ULB, November 2004 Verification vs. Optimization Verification Algorithms: –Check a logical property of the entire state-space of a model –Efficient blind search Optimization Algorithms: –Find (near) optimal solutions –Use techniques to avoid non- optimal parts of the state-space (e.g. Branch and Bound) Objective: –Bridge the gap between these two –New techniques and applications in UPPAAL Safe side reachable? Min time of reaching safe side?

ULB, November 2004 Minimum-Cost Order The basic algorithm finds the minimum cost trace Breadth or Depth-first search-order Problem: Searches the entire state-space Minimum-Cost Search Order: Always explore state with smallest minimum cost first

ULB, November 2004 Minimum-Cost Order Fact 1: First goal state found is optimal Cost grows along all paths The search can terminate when first goal state found Like Dijkstra’s shortest path algorithm Fact 2: No other search order explores fewer states Simpler algorithm: variable Cost no longer needed

ULB, November 2004 Estimates of Remaining Cost Often a conservative estimate of the remaining cost can be found R EM ( l, C ) = conservative estimate of remaining cost Bridge example: R EM ( l, C ) = time of slowest person on Unsafe side At least 25 mins needed to complete schedule

ULB, November 2004 Estimates of Remaining Cost Basic Algorithm + Estimate of remaining cost: Only states with (min(C) + R EM (l, C)) < Cost are further explored Cost=80 + R EM ( l, C )  80 min( C )

ULB, November 2004 Estimates of Remaining Cost Minimum Cost + Estimate of remaining cost: Explore states with smallest ( min(C) + R EM ( l, C ) ) first Cost=80 + R EM ( l, C )  80 min( C ) Basic Algorithm + Estimate of remaining cost: Only states with (min(C) + R EM (l, C)) < Cost are further explored

ULB, November 2004 Using Heuristics Allows the users to control the search order according to heuristics Symbolic states extended to (l, C, h), where h is the priority of a state Transitions are annotated with assignments to h Flexible! Basic Algorithm + Heuristics: State with highest h is explored first

ULB, November 2004 Using Heuristics Try to schedule planes in the order of their preferred landing times

ULB, November 2004 Outline Timed Automata. (A review} Linearly Priced Timed Automata –A basic Algorithm –Efficient Data Structures Uniformly Priced Timed Automata –More efficient Data Structures Improved State-Space Exploration –Minimum-Cost Order Search, Estimates of Remaining Cost, Heuristics Results –Bridge Problem –Sidmar –Aircraft Landing –others Conclusion

ULB, November 2004 Example: Bridge Problem Number of symbolic states generated with cost- extended version of UPPAAL Minimum Cost Order + Estimate of Remaining cost <10% of Breadth-First Search BF = Breadth-First, DF = Depth-First, MC = Minimum Cost Order, MC+ = MC + REM What is the fastest schedule?

ULB, November 2004 Machine 1 Machine 2Machine 3 Machine 4Machine 5 Buffer Continuos Casting Machine Storage Place Crane B Crane A A. Fehnker [RTCSA99], T. Hune, K. G. Larsen, P. Pettersson [DSV00] Case study of Esprit-LTR project VHS Physical plant of SIDMAR located in Gent, Belgium Part between blast furnace and hot rolling mill Objective: model the plant, obtain schedule and control program for plant Lane 1 Lane 2 SIDMAR Steel Production Plant

ULB, November 2004 Machine 1 Machine 2Machine 3 Machine 4Machine 5 Buffer Continuos Casting Machine Storage Place Crane B Crane A Input: sequence of steel Load follows Recipe to obtain certain quality, e.g: start; end within 120 Output: sequence of higher quality steel. Lane 1 Lane  =127 SIDMAR Steel Production Plant Optimal schedules for ten batches using guiding with priorities. Only for two batches without

ULB, November 2004 Aircraft Landing Problem runways Benchmark by Beasley et al 2000

ULB, November 2004 Advantages Easy and flexible modeling of systems Whole range of verification techniques becomes available Controller/Program synthesis Disadvantages Existing scheduling approaches (still) perform somewhat better Our goal See how far we get Integrate model checking and scheduling theory New discipline of Timing Technology? EU IST project Ametist Conclusion

ULB, November 2004 Conclusion Papers: –Efficient Guiding Towards Cost-Optimality in UPPAAL [TACAS’01] –Minimum Cost-Reachability for Priced Timed Automata [HSCC’01] –As Cheap as Possible: Efficient Cost-Optimal Reachability for Priced Timed Automata [CAV’01] –Citius, Vilius, Melius: Guiding and Cost-Optimality in Model Checking of Timed and Hybrid Systems, PhD Thesis Ansgar Fehnker, University of Nijmegen, April 2002 Tool : –UPPAAL CORA!!

ULB, November 2004 End of slide show

ULB, November 2004 THE END