Real Tim e Controller Synthesis
with
Gerd Behrmann, Franck Cassez, Agnes Counard, Alexandre David Emmanuel Fleury, Didier Lime
Real Tim e Controller Synthesis with Gerd Behrmann, Franck - - PowerPoint PPT Presentation
TI GA TI GA TI GA Real Tim e Controller Synthesis with Gerd Behrmann, Franck Cassez, Agnes Counard, Alexandre David Emmanuel Fleury, Didier Lime See CAV 2007 & CONCUR 2005 UCb UC Informationsteknologi Real Tim e Model Checking
Gerd Behrmann, Franck Cassez, Agnes Counard, Alexandre David Emmanuel Fleury, Didier Lime
See CAV 2007 & CONCUR 2005
sensors actuators
a c b 1 2 4 3 a c b 1 2 4 3 1 2 4 3 1 2 4 3 a c b
UPPAAL Model
Model
environment (user-supplied / non-determinism) Model
tasks (automatic?)
Continuous
Discrete
Continuous
Discrete
sensors actuators
a c b 1 2 4 3 a c b 1 2 4 3 1 2 4 3 1 2 4 3 a c b
Partial UPPAAL Model
Model
environment (user-supplied)
Synthesis
tasks/scheduler (automatic)
Production Cell GIVEN System moves S, Controller moves C, and property φ FIND strategy sC such that sC||S ² φ
GIVEN System moves S, Controller moves C, and property φ FIND strategy sC such that sC||S ² φ
Section Reading time is uncontrollable
Reachability / Safety Games
Uncontrollable Controllable
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2
Reachability / Safety Games
Uncontrollable Controllable
Strategy: F : Run(A) Ec Memoryless strategy: F : Q Ec Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ G = Ø Winning Strategy: Runs(F) ⊆ WinRuns
Reachability / Safety Games
Uncontrollable Controllable
Strategy: F : Run(A) Ec Memoryless strategy: F : Q Ec Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ G = Ø Winning Strategy: Runs(F) ⊆ WinRuns
Reachability / Safety Games
Uncontrollable Controllable
Strategy: F : Run(A) Ec Memoryless strategy: F : Q Ec Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ B = Ø Winning Strategy: Runs(F) ⊆ WinRuns
Reachability / Safety Games
Uncontrollable Controllable
Strategy: F : Run(A) Ec Memoryless strategy: F : Q Ec Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ B = Ø Winning Strategy: Runs(F) ⊆ WinRuns
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Uncontrollable Controllable Backwards Fixed-Point Computation
cPred(X) = { q∈Q | ∃ q’∈ X. q c q’} uPred(X) = { q∈Q | ∃ q’∈ X. q u q’}
Theorem: The set of winning states is
X a π(X) ∪ Goal
Reachability / Safety Games
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 Uncontrollable Controllable x≥2
Strategy: F : Run(A) Ec ∪ λ Memoryless strategy: F : Q Ec ∪ λ Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ G = Ø Winning Strategy: Runs(F) ⊆ WinRuns
Reachability / Safety Games
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 Uncontrollable Controllable x≥2
Strategy: F : Run(A) Ec ∪ λ Memoryless strategy: F : Q Ec ∪ λ Winning Run: States(ρ) ∩ G ≠ Ø States(ρ) ∩ G = Ø Winning Strategy: Runs(F) ⊆ WinRuns
x != 1 : λ x=1 : c x<2 : λ x≥2 : c x != 1 : λ x=1 : c
x<1 : λ x≥1 : c
Acyclic PTA [LTMM02] Bounded length [ABM04] Strong non-zeno cost-behaviour [BCFL04]
UPPAAL UPPAAL Cora Cora To be To be improved improved !! !! UPPAAL UPPAAL
Backwards Fixed-Point Computation
X Y
Predt(X,Y)
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2
1 ☺ 2 3 4
x·1 x<1 x:=0 x<1 x·1 x≥2 Backwards Fixed-Point Computation
1 2 We want Forward and On-The-Fly Algorithm in order to avoid constructing all (backwards) reachable state-space and to allow for discrete variables (e.g. in UPPAAL)
S Win(S)
S Win(S)
control: A[ p U q ] until control: A<> q ⇔ control: A[ true U q ]
control: A[ p W q ] weak until control: A[] p ⇔ control: A[ p W false ]
control_t*(u,g): A[ p U q ]
u is an upper-bound to prune the search, act like an invariant but on the path = expression on the current state. g is the time to the goal from the current state (a lower-bound in fact), also used to prune the search. States with t+g > u are pruned
Section Reading time is uncontrollable
16 MCD 2001, Twente Kim G. Larsen
U C b
First UPPAAL model
So Sorting of Lego Boxes ng of Lego Boxes
Conveyer Belt
Exercise: Design Controller so that only yellew boxes are being pushed out
Boxes
Piston
Black Yellow
9 18 81 90 99 Blck Yel remove eject
Controller
Ken Tindell
MAI N PUSH
Conveyer Belt
eject
Generic Plate Controller Piston
Generic Plate Controller Piston Strategy for EJECT
38 AMETIST Dortmund Dec 2002 Kim G. Larsen Ed Brinksma
thanks to Oded Maler
Problem: avoid having the plates falling down
39 AMETIST Dortmund Dec 2002 Kim G. Larsen Ed Brinksma
Problem: avoid having the plates falling down
thanks to Oded Maler
A Plate The Joggler
Strategy BDD/ CDD
Tricks (Alexandre):
* active clock reduction * PW-list * UPPAAL optimizations (successor computation, postponed evaluation, reduced copies..) * improved DBM library * improved copy-on-write implementations * improved subtraction (vital) * enormously improved merge (between DBMs) (vital)
With Jan J. Jessen Jacob I. Rasmussen
Temperature in neighbor zone (lower/higher) Neighbor wants to receive flow? Neighboring zone
Zone Controller
Zone Controller
Stragegy
get0 give0 give0 1 temp0 temp0 temp0 get1 get1 get1 get1 give1 give1 give1 give1 temp1 temp1 temp11296 cases BDD 289 nodes
500 1000 1500 2000 2500 3000 3500 4000 11.5 12 12.5 13 13.5 14 14.5 15 15.5 16 16.5 T1 T2 T3
Simulink
Optimal strategies undecidable in general [Raskin ao] Decidability in setting of 1 clock or strong non- zenoness.
Please do not hesitate to contact me: