hybrid systems and computer science a short tutorial
play

Hybrid systems and computer science a short tutorial Eugene Asarin - PowerPoint PPT Presentation

Hybrid systems and computer science a short tutorial Eugene Asarin Universit e Paris 7 - LIAFA SFM04 - RT, Bertinoro p. 1/4 Introductory equations Hybrid Systems = Discrete+Continuous SFM04 - RT, Bertinoro p. 2/4


  1. Hybrid systems and computer science a short tutorial Eugene Asarin Universit´ e Paris 7 - LIAFA SFM’04 - RT, Bertinoro – p. 1/4

  2. Introductory equations • Hybrid Systems = Discrete+Continuous SFM’04 - RT, Bertinoro – p. 2/4

  3. Introductory equations • Hybrid Systems = Discrete+Continuous • Hybrid Automata = A class of models of Hybrid systems SFM’04 - RT, Bertinoro – p. 2/4

  4. Introductory equations • Hybrid Systems = Discrete+Continuous • Hybrid Automata = A class of models of Hybrid systems • Original motivation (1990) = physical plant + digital controller SFM’04 - RT, Bertinoro – p. 2/4

  5. Introductory equations • Hybrid Systems = Discrete+Continuous • Hybrid Automata = A class of models of Hybrid systems • Original motivation (1990) = physical plant + digital controller • New applications = also scheduling, biology, economy, numerics, and more SFM’04 - RT, Bertinoro – p. 2/4

  6. Introductory equations • Hybrid Systems = Discrete+Continuous • Hybrid Automata = A class of models of Hybrid systems • Original motivation (1990) = physical plant + digital controller • New applications = also scheduling, biology, economy, numerics, and more • Hybrid community = Control scientists’ + Applied mathematicians + Some computer scientists’ SFM’04 - RT, Bertinoro – p. 2/4

  7. Outline 1. Hybrid automata - the model 2. Verification 3. Conclusions and perspectives SFM’04 - RT, Bertinoro – p. 3/4

  8. 1. The Model SFM’04 - RT, Bertinoro – p. 4/4

  9. Outline 1. Hybrid automata - the model • The definition • Semantic issues • Modeling with hybrid automata • “Hybrid” languages • Running a hybrid automaton 2. Verification 3. Conclusions and perspectives SFM’04 - RT, Bertinoro – p. 5/4

  10. The first example I’m sorry, a thermostat. SFM’04 - RT, Bertinoro – p. 6/4

  11. The first example I’m sorry, a thermostat. • When the heater is OFF, the room cools down : x = − x ˙ • When it is ON, the room heats: x = H − x ˙ SFM’04 - RT, Bertinoro – p. 6/4

  12. The first example I’m sorry, a thermostat. • When the heater is OFF, the room cools down : x = − x ˙ • When it is ON, the room heats: x = H − x ˙ • When t>M it switches OFF • When t<m it switches ON SFM’04 - RT, Bertinoro – p. 6/4

  13. The first example I’m sorry, a thermostat. • When the heater is OFF, the room cools down : x = − x ˙ • When it is ON, the room heats: x = H − x ˙ • When t>M it switches OFF • When t<m it switches ON A strange creature. . . SFM’04 - RT, Bertinoro – p. 6/4

  14. A bad syntax Some mathematicians prefer to write x = f ( x, q ) ˙ where f ( x, Off) = − x f ( x, On) = H − x with some switching rules on q . SFM’04 - RT, Bertinoro – p. 7/4

  15. A bad syntax Some mathematicians prefer to write x = f ( x, q ) ˙ where f ( x, Off) = − x f ( x, On) = H − x with some switching rules on q . But we will draw an automaton! SFM’04 - RT, Bertinoro – p. 7/4

  16. Hybrid automaton label x = M dynamics On Off x = H − x x = − x ˙ ˙ x ≤ M x ≥ m x = m /γ invariant reset guard SFM’04 - RT, Bertinoro – p. 8/4

  17. Hybrid automaton label x = M dynamics On Off x = H − x x = − x ˙ ˙ x ≤ M x ≥ m x = m /γ invariant reset guard A formal definition: It is a tuple . . . SFM’04 - RT, Bertinoro – p. 8/4

  18. Hybrid automaton label x = M dynamics On Off x = H − x x = − x ˙ ˙ x ≤ M x ≥ m x = m /γ invariant reset guard x M m SFM’04 - RT, Bertinoro – p. 8/4 t

  19. Hybrid versus timed a, x = 5 /x := 0 q 1 q 2 label x = M On Off dynamics b, x = 2 b, x > 7 a, x < 10 x = H − x x = − x ˙ ˙ x ≤ M x = m /γ x ≥ m a, x = 8 q 3 q 4 invariant reset guard b, x = 5 /x := 0 SFM’04 - RT, Bertinoro – p. 9/4

  20. Hybrid versus timed Element Timed Aut. Hybrid Aut. Discrete locations q ∈ Q (finite) q ∈ Q (finite) x ∈ R n x ∈ R n Continuous variables � � x dynamics x = 1 ˙ x = f ( x ) (and more) ˙ Guards bool. comb. of x i ≤ c i � x ∈ G SFM’04 - RT, Bertinoro – p. 9/4

  21. Semantic issues • A trajectory (run) is an f : R → Q × R n • Some mathematical complications (notion of solution, existence and unicity not so evident). • Zeno trajectories (infinitely many transitions in a finite period of time). • can be forbidden • one can consider trajectories up to the first anomaly (Sastry et al., everything OK) • one can consider the complete Zeno trajectories (very funny : Asarin-Maler 95) SFM’04 - RT, Bertinoro – p. 10/4

  22. Variants • Discrete-time ( x n +1 = f ( x n ) ) or continuous-time x = f ( x ) ˙ • Deterministic (e.g. ˙ x = f ( x ) ) or non-deterministic (e.g. ˙ x ∈ F ( x ) ) • Eager or lazy. • With control and/or disturbance (e.g. ˙ x = f ( x, u, d ) ) • Various restrictions on dynamics, guards and resets: “Piecewise trivial dynamics”. LHA, RectA, PCD, PAM, SPDI . . . They are still highly non-trivial. SFM’04 - RT, Bertinoro – p. 11/4

  23. Special classes of Hybrid Automata 1 • The famous one: Linear Hybrid Automata x ∈ P 1 / x := A 1 x + b 1 x = c 1 x = c 2 ˙ ˙ x ∈ P 2 / x := A 2 x + b 2 SFM’04 - RT, Bertinoro – p. 12/4

  24. Special classes of Hybrid Automata 2 • My favorite: PCD = Piecewise Constant Derivatives c 1 P 1 y x x = c i for x ∈ P i ˙ SFM’04 - RT, Bertinoro – p. 13/4

  25. PCD is a linear hybrid automaton (LHA) e 2 e 3 e 4 e 12 e 1 e 9 e 10 e 11 e 5 e 8 e 7 e 6 SFM’04 - RT, Bertinoro – p. 14/4

  26. PCD is a linear hybrid automaton (LHA) e 2 e 3 e 2 e 3 e 4 e 12 e 1 e 9 e 4 e 12 e 1 e 9 e 10 e 11 e 5 e 8 e 10 e 11 e 5 e 8 e 6 e 7 e 7 e 6 SFM’04 - RT, Bertinoro – p. 14/4

  27. PCD is a linear hybrid automaton (LHA) e 2 e 3 R 4 R 2 x = a 4 ˙ x = a 2 ˙ Inv ( ℓ 4 ) Inv ( ℓ 2 ) e 12 e 9 x = e 4 x = e 1 R 5 R 1 x = a 5 ˙ x = a 1 ˙ Inv ( ℓ 5 ) Inv ( ℓ 1 ) x = e 10 x = e 11 x = e 5 x = e 8 R 6 R 7 R 8 x = e 6 x = e 7 x = a 6 ˙ x = a 7 ˙ x = a 8 ˙ Inv ( ℓ 6 ) Inv ( ℓ 7 ) Inv ( ℓ 8 ) SFM’04 - RT, Bertinoro – p. 14/4

  28. PCD is a linear hybrid automaton (LHA) R 4 R 2 R 3 x = e 3 x = e 2 x = a 4 ˙ x = a 3 ˙ x = a 2 ˙ Inv ( ℓ 4 ) Inv ( ℓ 3 ) Inv ( ℓ 2 ) x = e 4 x = e 9 x = e 1 x = e 12 R 5 R 1 x = a 5 ˙ x = a 1 ˙ Inv ( ℓ 5 ) Inv ( ℓ 1 ) x = e 10 x = e 11 x = e 5 x = e 8 R 6 R 7 R 8 x = e 6 x = e 7 x = a 6 ˙ x = a 7 ˙ x = a 8 ˙ Inv ( ℓ 6 ) Inv ( ℓ 7 ) Inv ( ℓ 8 ) SFM’04 - RT, Bertinoro – p. 14/4

  29. PCD is a linear hybrid automaton (LHA) R 4 R 2 R 3 x = e 3 x = e 2 x = a 4 ˙ x = a 3 ˙ x = a 2 ˙ Inv ( ℓ 4 ) Inv ( ℓ 3 ) Inv ( ℓ 2 ) x = e 4 x = e 9 x = e 1 x = e 12 R 5 R 1 x = a 5 ˙ x = a 1 ˙ Inv ( ℓ 5 ) Inv ( ℓ 1 ) x = e 10 x = e 11 x = e 5 x = e 8 R 6 R 7 R 8 x = e 6 x = e 7 x = a 6 ˙ x = a 7 ˙ x = a 8 ˙ Inv ( ℓ 6 ) Inv ( ℓ 7 ) Inv ( ℓ 8 ) SFM’04 - RT, Bertinoro – p. 14/4

  30. Special classes of Hybrid Automata 3 • The most illustrative: Piecewise Affine Maps P 1 P 2 x := A i x + b i for x ∈ P i A 1 x + b 1 A 2 x + b 2 SFM’04 - RT, Bertinoro – p. 15/4

  31. How to model? • a control system SFM’04 - RT, Bertinoro – p. 16/4

  32. How to model? • a control system • a scheduler with preemption SFM’04 - RT, Bertinoro – p. 16/4

  33. How to model? • a control system • a scheduler with preemption • a genetic network SFM’04 - RT, Bertinoro – p. 16/4

  34. How to model? • a control system • a scheduler with preemption • a genetic network A network of interacting Hybrid automata SFM’04 - RT, Bertinoro – p. 16/4

  35. Hybrid languages • SHIFT • Charon • Hysdel • IF, Uppaal (Timed + ε ) • why not Simulink? or Simulink+CheckMate. SFM’04 - RT, Bertinoro – p. 17/4

  36. What to do with a hybrid model • Simulate • With Matlab/Simulink • With dedicated tools • Analyze with techniques from control science: • Stability analysis • Optimal control • etc.. • Analyze with your favorite techniques. The most important invention is the model. SFM’04 - RT, Bertinoro – p. 18/4

  37. 2. Verification SFM’04 - RT, Bertinoro – p. 19/4

  38. Outline 1. Hybrid automata - the model � 2. Verification • Verification and reachability problems • Exact methods • The curse of undecidability • Decidable classes • Can realism help? • Approximate methods • The abstract algorithm • Data structures and concrete algorithms • Beyond reachability, beyond verification • Verification tools 3. Conclusions and perspectives SFM’04 - RT, Bertinoro – p. 20/4

  39. Verification and reachability problems • Is automatic verification possible for HA? SFM’04 - RT, Bertinoro – p. 21/4

  40. Verification and reachability problems • Is automatic verification possible for HA? • Safety: are we sure that HA never enters a bad state? • It can be seen as reachability : verify that ¬ Reach ( Init, Bad ) SFM’04 - RT, Bertinoro – p. 21/4

  41. Verification and reachability problems • Is automatic verification possible for HA? • Safety: are we sure that HA never enters a bad state? • It can be seen as reachability : verify that ¬ Reach ( Init, Bad ) • It is a natural and challenging mathematical problem. • Many works on decidability • Some works on approximated techniques SFM’04 - RT, Bertinoro – p. 21/4

Recommend


More recommend