Sfety Controller Synthesis for Switched Systems using Multiscle Symolic Models Antoine Girrd Lortoire des Signux et Systèmes Gif sur Yvette, Frnce Workshop on switching dynmics & verifiction Pris, Jnury 28-29, 2016 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 1 / 33
Introduction Controller synthesis for clss of continuous-time switched systems Incrementlly stle systems: the influence of initil condition symptoticlly vnishes. Sfety specifiction: controlled invrince. Approch sed on the use of symolic models Discrete (time nd spce) pproximtion of the switched system. Approch sed on uniform discretiztion of time nd spce. [Girrd, Pol nd Tud, 2010] Distnce etween trjectories of incrementlly stle switched system nd of symolic model is uniformly ounded, nd cn e mde ritrrily smll. Sfety controller synthesis using symolic models vi lgorithmic discrete controller synthesis. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 2 / 33
Motivtion Limittions of the symolic control pproch Sptil nd time resolution must e chosen crefully to chieve given precision: fst switching requires fine sptil resolution; Uniform sptil discretiztion: excessive computtion time nd memory consumption. Overcome this prolem with multiscle symolic models Use of multiscle discretiztions of time nd spce Incrementl explortion of symolic models during controller synthesis: The finer scles explored only if sfety cnnot e ensured t corser level. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 3 / 33
Outline 1 Incrementlly stle switched systems 2 Multiscle symolic models 3 Sfety controller synthesis using multiscle symolic models 4 Computtionl experiments A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 4 / 33
Switched systems Definition A switched system is tuple Σ = (R n, P, P, F ), where R n is the stte spce; P = {1,..., m} is the finite set of modes; P is suset of S(R + 0, P), the set of functions from R+ 0 to P with finite numer of discontinuities on every ounded intervl of R + 0 ; F = {f 1,..., f m } is collection of smooth vector fields indexed y P. For switching signl p P, initil stte x R n, x(., x, p) is the trjectory of Σ, solution of: ẋ(t) = f p(t) (x(t)), x(0) = x. S τd (R + 0, P) is the set of switching signls p with minimum dwell-time τ d R + : discontinuities of p re seprted y t lest τ d. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 5 / 33
Incrementl stility Definition Σ is incrementlly glolly uniformly symptoticlly stle (δ-guas) if there exists KL function β such tht for ll x 1, x 2 R n, p P, t R + 0 : x(t, x 1, p) x(t, x 2, p) β( x 1 x 2, t). x(t, x 2, p) x(t, x 1, p) t A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 6 / 33
Lypunov chrcteriztion Definition V p : R n R n R + 0, p P re multiple δ-guas Lypunov functions for Σ if there exist κ, µ R + with µ 1, K functions α, α, such tht for ll x 1, x 2 R n, p, p P: α( x 1 x 2 ) V p (x 1, x 2 ) α( x 1 x 2 ); V p x 1 (x 1, x 2 )f p (x 1 ) + Vp x 2 (x 1, x 2 )f p (x 2 ) κv p (x 1, x 2 ); V p (x 1, x 2 ) µv p (x 1, x 2 ). Theorem Let τ d R +, Σ = (R n, P, P, F ) with P S τd (R + 0, P) dmitting multiple δ-guas Lypunov functions. If τ d > log µ κ, then Σ is δ-guas. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 7 / 33
Additionl ssumption In the following, we will ssume tht there exists K function γ such tht for ll x 1, x 2, x 3 R n V p (x 1, x 2 ) V p (x 1, x 3 ) γ( x 2 x 3 ), p P; This is not restrictive if V p re smooth nd we work on ounded suset of R n. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 8 / 33
Outline 1 Incrementlly stle switched systems 2 Multiscle symolic models 3 Sfety controller synthesis using multiscle symolic models 4 Computtionl experiments A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 9 / 33
Trnsition systems Definition A trnsition system is tuple T = (X, U, Y,, X 0 ) where X, U, Y, X 0 re the sets of sttes, inputs, outputs nd initil sttes; X U X Y is trnsition reltion. T is metric if Y is equipped with metric d, symolic if X nd U re finite or countle sets. (x, u, x, y) is denoted (x, y) (x, u); u U is enled t x X, denoted u en(x), if (x, u) ; If en(x) =, then x is locking, otherwise it is non-locking; T is deterministic if for ll x X nd u en(x), (x, u) = 1. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 10 / 33
Trjectories A trjectory of T is finite or infinite sequence of trnsitions σ = (x 0, u 0, y 0 )(x 1, u 1, y 1 )(x 2, u 2, y 2 )... where (x i+1, y i ) (x i, u i ), for ll i 0. It is: initilized if x 0 X 0 ; mximl if it is infinite or it is finite nd ends in locking stte. x X is rechle if there exists n initilized trjectory reching x. T is non-locking if ll initilized mximl trjectories re infinite or equivlently if ll rechle sttes re non-locking. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 11 / 33
Approximte isimultion Definition Let T i = (X i, U, Y, i, X 0 i ), with i = 1, 2 e metric trnsition systems with the sme sets of inputs U nd outputs Y equipped with the metric d. Let ε R + 0, R X 1 X 2 is n ε-pproximte isimultion reltion etween T 1 nd T 2 if for ll (x 1, x 2 ) R, u U: (x 1, y 1) 1 (x 1, u), (x 2, y 2) 2 (x 2, u), d(y 1, y 2 ) ε nd (x 1, x 2 ) R; (x 2, y 2) 2 (x 2, u), (x 1, y 1) 1 (x 1, u), d(y 1, y 2 ) ε nd (x 1, x 2 ) R. T 1 nd T 2 re ε-pproximtely isimilr, denoted T 1 ε T 2, if X 0 1 R 1 (X 0 2 ) nd X 0 2 R(X 0 1 ). A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 12 / 33
Switched systems s trnsition systems Let Σ τd = (R n, P, P, F ) e switched system with P = S τd (R + 0, P). We consider controllers tht cn select: 1 mode p P; 2 durtion θ Θ N τ during which the mode remins ctive where Θ N τ = {θ s = 2 s τ s = 0,..., N}. where τ R +, N N re time smpling nd scle prmeters. We ssume τ d = θ Nd for some N d {0,..., N}, then Θ N d τ = {θ s Θ N τ θ s τ d }. Let C(I, R n ) denote the set of continuous functions from I to R n. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 13 / 33
Switched systems s trnsition systems Let T N τ (Σ τd ) = (X, U, Y,, X 0 ) where: X = R n P, z = (x, p) X consists of continuous stte x nd n ctive mode p. U = P Θ N τ, u = (p, θ s ) U consists of mode p nd durtion θ s. Y = s=n s=0 C([0, θ s], R n ) is set of continuous functions, equipped with the metric: { d(y, y y y ) = if θ s = θ s + if θ s θ s X 0 = R n P. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 14 / 33
Switched systems s trnsition systems For z = (x, p) X, z = (x, p ) X, u = ( p, θ s ) U, y Y, (z, u, z, y) ( p, θ s ) {p} Θ N τ (P \ {p}) Θ N d τ x = x(θ s, x, p) nd p = p. y = x θs (., x, p) y = x θs (., x, p) x = x(θ s, x, p) x T N τ (Σ τd ) is deterministic nd metric. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 15 / 33
Computtion of the symolic model We pproximte R n y sequence of emedded multiscle lttices { [R n ] 2 s η = q R n 2 s+1 } η q[i] = k i, k i Z, i = 1,..., n n where η R + is stte spce smpling prmeter. We ssocite multiscle quntizer Q s η : R n [R n ] 2 s η such tht Q s η(x) = q q[i] 2 s η n x[i] < q[i] + 2 s η n, i = 1,..., n. Let X s η = [R n ] 2 s η P, then X 0 η X 1 η X N η. We define the symolic model s T N τ,η(σ τd ) = (X N η, U, Y, η, X 0 η ). A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 16 / 33
Computtion of the symolic model For r = (q, p) X, r = (q, p ) X, u = ( p, θ s ) U, y Y, ( p, θ s ) {p} Θ N (r, u, r τ (P \ {p}) Θ N d τ, y) q = Q s η(x(θ s, q, p)) nd p = p. y = x θs (., q, p) q = Q 1 η(x(θ 1, q, p)) q y = x θ1 (., q, p)) A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 17 / 33
Computtion of the symolic model For r = (q, p) X, r = (q, p ) X, u = ( p, θ s ) U, y Y, ( p, θ s ) {p} Θ N (r, u, r τ (P \ {p}) Θ N d τ, y) q = Q s η(x(θ s, q, p)) nd p = p. y = x θs (., q, p) q = Q 0 η(x(θ 0, q, p)) q y = x θ0 (., q, p)) A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 17 / 33
Approximtion result T N τ (Σ τd ) is symolic, deterministic nd metric. Theorem Let Σ τd dmit multiple δ-guas Lypunov functions V p, p P. Consider prmeters τ, η R +, N N, nd precision ε R +. If τ d > log µ κ nd { s=nd (( ) )] 1µ η min min [2 s γ 1 s=0 e κθs α(ε), [ ( s=n 1 e min 2 s γ 1 κθ s ( )} 1µ α(ε) )], α 1 s=0 µ α(ε) then T N τ (Σ τd ) ε T N τ,η(σ τd ). A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 18 / 33
Outline 1 Incrementlly stle switched systems 2 Multiscle symolic models 3 Sfety controller synthesis using multiscle symolic models 4 Computtionl experiments A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 19 / 33
Sfety specifiction Let T = (X, U, Y,, X 0 ) e symolic, deterministic trnsition system where Y C([0, θ y ], R n ). θ y R + Let S R n e suset of sfe sttes. We define the trnsition system T S = (X, U, Y, S, X 0 ) where for x, x X, u U, y Y, u en(x); (x, y) S (x, u) (x, y) = (x, u); t [0, θ y ], y(t) S. T S is symolic nd deterministic. Remrk: sfety is defined on continuous-time outputs. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 20 / 33
Sfety controller Definition A sfety controller for T S = (X, U, Y, S, X 0 ) is reltion C X U such tht for ll x X : C(x) en(x); if C(x), then u C(x), C(x ) with S (x, u) = (x, y). We denote the domin of C s dom(c) = {x X C(x) }. The controlled trnsition system is T S/C = (X, U, Y, S/C, X 0 C ) where X 0 C = X 0 dom(c) nd for x, x X, u U, y Y, (x, y) S/C (x, u) { u C(x); (x, y) = S (x, u). T S/C is symolic, deterministic nd non-locking. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 21 / 33
Mximl sfety controller Lemm There exists unique mximl sfety controller C X U such tht for ll sfety controllers C, C C. Definition A stte x X is sfety controllle if nd only if x dom(c ). The set of sfety controllle sttes is denoted cont(t S ). Computtion of C requires complete explortion of T S. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 22 / 33
Lzy sfety synthesis Lzy sfety synthesis: trde-off etween mximlity nd efficiency. Give priority to inputs with longer durtion, which led to sttes on corser grids. Compute the symolic model on the fly. Finer scles re explored (computed) only if sfety cnnot e ensured t the corser scles. Let us define priority reltion on inputs: totl preorder U U The ssocited equivlence nd strict wek order reltions re u u u u nd u u; u u u u nd u u. For multiscle symolic models where U = P Θ N τ : (p, θ s ) (p, θ s) θ s θ s; (p, θ s ) (p, θ s) θ s = θ s; (p, θ s ) (p, θ s) θ s < θ s. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 23 / 33
Mximl lzy sfety controller Definition A mximl lzy sfety (MLS) controller for T S = (X, U, Y, S, X 0 ) is sfety controller C X U such tht: ll sfety controllle initil sttes re in dom(c): X 0 cont(t S ) dom(c); ll sttes x dom(c) re rechle in T S/C ; for ll sttes x dom(c): 1 if u C(x), then u en(x) with u u, (x, y) = S (x, u ), u C(z) x cont(t S ); 2 if u C(x), then u en(x) with u u, (x, y) = S (x, u ), x / cont(t S ). A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 24 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Mximl lzy sfety controller Theorem There exists unique MLS controller for T S. MLS controller synthesis: X 0 = {x 1, x 2, x 3 },. x 1 x 2 x 3 x 1 x 2 x 3 x 4 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 25 / 33
Outline 1 Incrementlly stle switched systems 2 Multiscle symolic models 3 Sfety controller synthesis using multiscle symolic models 4 Computtionl experiments A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 26 / 33
Switched system with dwell-time We consider the switched system: ẋ(t) = A p(t) x(t) + p(t), p(t) {1, 2}, with A 1 = [ ] 0.25 1 2 0.25, A2 = [ ] 0.25 2 1 0.25, 1 = [ ] 0.25 2, 2 = [ 0.25 1 ]. The switched system dmits multiple δ-guas Lypunov functions nd is incrementlly stle for switching signls with minimum dwell-time τ d = 2. Multiscle strction with prmeters τ = 4, η = 8 100, N = 3 2 Uniform strction with prmeters τ = 1 2, η = 1 100 2 = precision ε = 0.4. Sfe set: S = [ 6, 6] [ 4, 4] \ [ 1.5, 1.5] [ 1, 1]. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 27 / 33
Switched system with dwell-time Controller synthesis: Uniform symolic model Multiscle symolic model Time 160s 7.3s Size (10 3 ) 5228 33 Durtions 0.5 (100%) 4 (26%) 2 (54%) 1 (11% 0.5 (9%) A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 28 / 33
Switched system with dwell-time MLS Controller: Mode 1 is ctive Mode 2 is ctive A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 29 / 33
Switched system with dwell-time Controlled switched system: 4 3 2 1 0-1 -2-3 -4-6 -5-4 -3-2 -1 0 1 2 3 4 5 6 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 30 / 33
Circulr n-room uilding We consider the system: Ṫ i (t) = α(t i+1 (t) + T i 1 (t) 2T i (t)) +β(t e T i (t)) + γ(t h T i (t))u i (t) where: T i (t) is the temperture of room i, 1 i n, T 0 (t) = T n (t) nd T n+1 (t) = T 1 (t). u i (t) = 1 if room i is heted, u i (t) = 0 otherwise nd n i=1 u i(t) 1. n-dimensionl switched system with n + 1 modes dmits common Lypunov function nd is incrementlly stle. Multiscle strction with prmeters τ = 80, η = 0.28, N = 4 = Precision ε = 0.4. Sfe set: S = [19, 21.5] n. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 31 / 33
Circulr n-room uilding Controller synthesis: Multiscle symolic models n = 3 n = 4 n = 5 Time 0.2s 6s 312s Size (10 3 ) 2 45 1 077 Durtions 40 (1%) 20 (25%) 20 (6%) 20 (37%) 10 (73%) 10 (92%) 10 (62%) 5 (2%) 5 (2%) Computtionl complexity increses with dimension: Stte nd input spce re lrger. The control prolem is lso intrinsiclly more complex in higher dimension ecuse of the constrint: n u i (t) 1. i=1 A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 32 / 33
Conclusions Multiscle pproximtely isimilr symolic models for incrementlly stle switched systems: Bsed on multiscle smpling of time nd spce; Allow significnt complexity reduction for controller synthesis. Multiscle sfety controller synthesis: Bsed on the notion of mximl lzy sfety controller; Prtil explortion of the symolic strctions; Cn e extended to more generl sfety properties, e.g. specified y hyrid utomton. Future work: MLS controller synthesis lgorithm for non-deterministic systems; Consider other types of specifictions, e.g. rechility: mximl lzy rechility controller my not e unique. Girrd, Gössler nd Mouelhi, Sfety controller synthesis for incrementlly stle switched systems using multiscle symolic models. IEEE TAC, 2016. A. Girrd (L2S-CNRS) Synthesis using multiscle symolic models 33 / 33