Using the Theory of Reals in. Analyzing Continuous and Hybrid Systems



Similar documents
Lecture 7: Finding Lyapunov Functions 1

3.2 Sources, Sinks, Saddles, and Spirals

Math Assignment 6

Nonlinear Systems and Control Lecture # 15 Positive Real Transfer Functions & Connection with Lyapunov Stability. p. 1/?

4 Lyapunov Stability Theory

LS.6 Solution Matrices

3. Reaction Diffusion Equations Consider the following ODE model for population growth

Lecture 13 Linear quadratic Lyapunov theory

x = + x 2 + x

MATH 425, PRACTICE FINAL EXAM SOLUTIONS.

Numerical Methods for Differential Equations

19 LINEAR QUADRATIC REGULATOR

Lecture 11: 0-1 Quadratic Program and Lower Bounds

DATA ANALYSIS II. Matrix Algorithms

Stability Analysis for Systems of Differential Equations

Inner Product Spaces

Brief Introduction to Vectors and Matrices

Similarity and Diagonalization. Similar Matrices

Numerical methods for American options

Bindel, Spring 2012 Intro to Scientific Computing (CS 3220) Week 3: Wednesday, Feb 8

LIMITS AND CONTINUITY

DERIVATIVES AS MATRICES; CHAIN RULE

Stability. Chapter 4. Topics : 1. Basic Concepts. 2. Algebraic Criteria for Linear Systems. 3. Lyapunov Theory with Applications to Linear Systems

Chapter 6. Orthogonality

Chapter 2. Parameterized Curves in R 3

Verification of hybrid dynamical systems

Eigenvalues, Eigenvectors, and Differential Equations

Student name: Earlham College. Fall 2011 December 15, 2011

Nonlinear Systems of Ordinary Differential Equations

Chapter 5. Methods for ordinary differential equations. 5.1 Initial-value problems

Continuity of the Perron Root

Chapter 13 Internal (Lyapunov) Stability 13.1 Introduction We have already seen some examples of both stable and unstable systems. The objective of th

Example 4.1 (nonlinear pendulum dynamics with friction) Figure 4.1: Pendulum. asin. k, a, and b. We study stability of the origin x

SIXTY STUDY QUESTIONS TO THE COURSE NUMERISK BEHANDLING AV DIFFERENTIALEKVATIONER I

Metric Spaces. Chapter Metrics

Chapter 20. Vector Spaces and Bases

Part IB Paper 6: Information Engineering LINEAR SYSTEMS AND CONTROL Dr Glenn Vinnicombe HANDOUT 3. Stability and pole locations.

1 if 1 x 0 1 if 0 x 1

Numerical Methods I Eigenvalue Problems

13 MATH FACTS a = The elements of a vector have a graphical interpretation, which is particularly easy to see in two or three dimensions.

Scalar Valued Functions of Several Variables; the Gradient Vector

Figure 2.1: Center of mass of four points.

An Introduction to Partial Differential Equations

NOV /II. 1. Let f(z) = sin z, z C. Then f(z) : 3. Let the sequence {a n } be given. (A) is bounded in the complex plane

CHAPTER 2. Eigenvalue Problems (EVP s) for ODE s

Some Lecture Notes and In-Class Examples for Pre-Calculus:

Section Inner Products and Norms

r (t) = 2r(t) + sin t θ (t) = r(t) θ(t) + 1 = 1 1 θ(t) Write the given system in matrix form x = Ax + f ( ) sin(t) x y z = dy cos(t)

Vector and Matrix Norms

EXIT TIME PROBLEMS AND ESCAPE FROM A POTENTIAL WELL

Monitoring Metric First-order Temporal Properties

Understanding Poles and Zeros

Numerical Analysis Lecture Notes

Reducing Clocks in Timed Automata while Preserving Bisimulation

MATH 132: CALCULUS II SYLLABUS

ab = c a If the coefficients a,b and c are real then either α and β are real or α and β are complex conjugates

Lecture 1: Schur s Unitary Triangularization Theorem

Reliability Guarantees in Automata Based Scheduling for Embedded Control Software

Introduction to Matrix Algebra

Differentiation of vectors

Undergraduate Notes in Mathematics. Arkansas Tech University Department of Mathematics

FOUNDATIONS OF ALGEBRAIC GEOMETRY CLASS 22

Algebra 2 Chapter 1 Vocabulary. identity - A statement that equates two equivalent expressions.

1 Introduction to Matrices

Method To Solve Linear, Polynomial, or Absolute Value Inequalities:

SOLUTIONS TO EXERCISES FOR. MATHEMATICS 205A Part 3. Spaces with special properties

Modeling, Verification and Testing using Timed and Hybrid. Automata. Stavros Tripakis and Thao Dang

An Introduction to Hybrid Automata

Elasticity Theory Basics

Zeros of a Polynomial Function

Fixed Point Theorems

Dynamical Systems Analysis II: Evaluating Stability, Eigenvalues

Applied Linear Algebra

Chapter 12 Modal Decomposition of State-Space Models 12.1 Introduction The solutions obtained in previous chapters, whether in time domain or transfor

Data Mining: Algorithms and Applications Matrix Math Review

What is Linear Programming?

Regular Languages and Finite State Machines

Linear-Quadratic Optimal Controller 10.3 Optimal Linear Control Systems

A QUICK GUIDE TO THE FORMULAS OF MULTIVARIABLE CALCULUS

MATH PROBLEMS, WITH SOLUTIONS

INTEGRAL METHODS IN LOW-FREQUENCY ELECTROMAGNETICS

Computational Geometry Lab: FEM BASIS FUNCTIONS FOR A TETRAHEDRON

(67902) Topics in Theory and Complexity Nov 2, Lecture 7

CHAPTER 9. Integer Programming

Network Traffic Modelling

Spectral Networks and Harmonic Maps to Buildings

Lecture 5 Principal Minors and the Hessian

x a x 2 (1 + x 2 ) n.

Class Meeting # 1: Introduction to PDEs

Solutions for Review Problems

OPTIMAL CONTROL OF A COMMERCIAL LOAN REPAYMENT PLAN. E.V. Grigorieva. E.N. Khailov

Techniques algébriques en calcul quantique

Reading 13 : Finite State Automata and Regular Expressions

V(x)=c 2. V(x)=c 1. V(x)=c 3

No: Bilkent University. Monotonic Extension. Farhad Husseinov. Discussion Papers. Department of Economics

Transcription:

Using the Theory of Reals in Analyzing Continuous and Hybrid Systems Ashish Tiwari Computer Science Laboratory (CSL) SRI International (SRI) Menlo Park, CA 94025 Email: ashish.tiwari@sri.com Ashish Tiwari Reals in Hybrid Systems: 1

Dynamical Systems A lot of engineering and science concerns dynamical systems State Space: The set of states, X Dynamics: The evolutions, T X Discrete Systems: T is N Continuous Systems: T is R Hybrid Systems: T is R N Ashish Tiwari Reals in Hybrid Systems: 2

Formal Models I Modeling languages: Continuous systems: Differential equations The state space formulation ẋ(t) = f(x(t), u(t), t) y(t) = h(x(t), t) u x y Discrete systems: (Finite) state machines t( x, x ) is a formula in some theory Ashish Tiwari Reals in Hybrid Systems: 3

Formal Models II Putting the two formal models together, Hybrid Automata: Embed a continuous dynamical system inside each state World now evolves in two different ways Move from one state to another via a discrete transition Remain in the state and let the continuous world evolve System has different modes of operation, while some discrete logic performs mode switches X Time Ashish Tiwari Reals in Hybrid Systems: 4

Hybrid Automata A tuple (Q, X, S 0, F, Inv, R): Q: finite set of discrete variables X: finite set of continuous variables X = R X, Q = set of all valuations for Q S = Q X S 0 S is the set of initial states F : Q (X R X ) specifies the rate of flow, ẋ = F (q)(x) Inv : Q 2 R X gives the invariant set R Q 2 X Q 2 X captures discontinuous state changes Ashish Tiwari Reals in Hybrid Systems: 5

Hybrid Automata: In picture q = off. x = kx 68 < x x < 70 x > 80 q = on. x = M kx x < 82 X Time Dense Time: Time does not elapse during discrete transition Ashish Tiwari Reals in Hybrid Systems: 6

Semantics of Hybrid Systems s1 s2 s3 s4 s5 s6 s1 S 0 is an initial state Discrete Evolution: s i s i+1 iff R(s i, s i+1 ) Continuous Evolution: s i = (l, x i ) s i+1 = (l, x i+1 ) iff there exists a f : R X R X and δ > 0 such that x i+1 = f(δ) x i = f(0) f = F (l) f(t) Inv(l) for 0 t δ Ashish Tiwari Reals in Hybrid Systems: 7

Questions What can we say (deduce, compute) about the model? Reachability. Is there a way to get from state x to x Safety. Does the system stay out of a bad region Can the car ever collide with the car in front? Liveness. Does something good always happen Stability. Eventually remain in good region Timing Properties. Something good happens in 10 seconds Does the model satisfy some property. Property is described in a logic interpreted over the formal models. Ashish Tiwari Reals in Hybrid Systems: 8

Problem Given a hybrid automata And a property: safety, reachability, liveness Show that the property is true of the model Discrete systems: mc, bmc, abs. inter., inf-bmc, k-induction, deductive rules Continuous systems:? Hybrid systems:... Ashish Tiwari Reals in Hybrid Systems: 9

Continuous Systems Approach 1: Solve the ODE and eliminate t Eg. If ẋ = 1, ẏ = 1, then Reach := t : (x = x 0 + t y = y 0 + t) x = A x, then Reach := t : x = e At x 0 If A is nilpotent: e At x 0 is a polynomial If A has all rational eigenvalues: e At x 0 is a polynomial with e If A has all imaginary rational eigenvalues: e At x 0 is a polynomial with sin, cos In all cases, reduces to elimination over RCF Ashish Tiwari Reals in Hybrid Systems: 10

Continuous Systems Approach 2: Use inductive invariants cf. Barrier Certificates, Lyapunov Functions Consider the CDS: x 1 = x 1 x 2 x 2 = x 1 x 2 0.5 0 0.5 x 2 1 +x 2 2 0.5 is an invariant set. But there are more invariants: 1 1.5 x 1 0.5 x 2 0.5 2 0.5 0 0.5 1 1.5 2 Ashish Tiwari Reals in Hybrid Systems: 11

Invariants for Dynamical Systems Illustration of invariant sets in 2-D: Invariant Region Box Invariance Box Invariance Arbitrarily shaped Box shaped Ashish Tiwari Reals in Hybrid Systems: 12

Box Invariants A positively invariant rectangular box l x u i.e., invariants of the form, l 1 x 1 x 1 u 1 l 2 x 2 x 2 u 2... Related Concepts Component-wise Asymptotic Stability (CWAS) Lyapunov stability under the infinity vector norm Unstable systems can have useful box invariants Ashish Tiwari Reals in Hybrid Systems: 13

Why Box Invariants? An Empirical Law for Biological Models: If a model of a biological system is stable, then it also has a rectangular box of attraction if the system enters this box, then it remains inside it. This law allows verification and parameter estimation for models of biological systems. Natural intuitive meaning Ashish Tiwari Reals in Hybrid Systems: 14

Computing Box Invariants Find Box( l, u) such that vector field points inwards on the boundary l, u : x : 1 j n (( x FaceL j ( l, u) dx j dt 0) ( x FaceU j ( l, u) dx j dt 0)), (1) If dx j is a polynomial expression, then existence of box invariants is dt decidable. Ashish Tiwari Reals in Hybrid Systems: 15

Linear Systems: Deciding Box Invariance A Q n n A m = matrix obtained from A s.t. a m ii = a ii, a m ij = a ij for i j. The following problems are all equivalent and can be solved in O(n 3 ) time: Is x = A x strictly box invariant? Is x = A m x strictly box invariant? Is there a z > 0 such that A m z < 0? Does there exist a positive diagonal matrix D s.t. µ(d 1 A m D) < 0 (in the infinity norm)? Is A m a P -matrix? Box invariance is stronger than stability for linear systems Ashish Tiwari Reals in Hybrid Systems: 16

Linear Systems, Box Invariance, Metzler Matrices Matrices with non-negative off-diagonal terms, such as A m, are known as Metzler matrices. A m R n n is Metzler and irreducible. Then it has an eigenvalue τ s.t.: 1. τ is real; furthermore, τ > Re(λ), where λ is any other eigenvalue of A m different from τ; 2. τ is associated with a unique (up to multiplicative constant) positive (right) eigenvector; 3. τ 0 iff c > 0, such that A m c 0; τ < 0 iff there is at least one strict inequality in A m c 0; 4. τ < 0 iff all the principal minors of A m are positive; 5. τ < 0 iff (A m ) 1 > 0. Ashish Tiwari Reals in Hybrid Systems: 17

Examples Glucose/Insulin metabolism in Human Body: Compartmental model of whole body is typically box invariant. Boxes give bounds on blood sugar concentration in different organs. EGFR / HER2 trafficking model: Proposed affine model is box invariant. Delta-Notch lateral signaling model: The stable modes are box invariants Tetracycline Antibiotics Resistance: The resistant mode is box invariant Ashish Tiwari Reals in Hybrid Systems: 18

Nonlinear Systems d x dt = p( x) l, u : x : 1 j n (( x FaceL j ( l, u) dx j dt 0) ( x FaceU j ( l, u) dx j dt 0)), (2) If p are all polynomials, then inductive properties of the form x c can be computed Efficiency is an issue Ashish Tiwari Reals in Hybrid Systems: 19

Nonlinear Systems: Multiaffine d x dt = p( x) Multiaffine: Degree at most one in each variable Example: x 1 x 2 x 2 x 3 is multiaffine If p is multiaffine and x Box( l, u), then p( x) is bounded by values of p at vertices of the box Box Invariance Box Invariance (2n) to (n2 n ): Generalize: Degree of x j can be arbitrary in p j Ashish Tiwari Reals in Hybrid Systems: 20

Nonlinear Systems: Monotone Generalize multiaffine systems If f is a monotone function, then f( x) is bounded by values f( v) at the vertices v x = p is monotone if p i is monotone wrt x j for all j i. Examples: x = 1 x 2 is monotone, but not multiaffine x = x 3 + x is monotone, but not multiaffine (2n) to (n2 n ) Ashish Tiwari Reals in Hybrid Systems: 21

Nonlinear Systems: Uniformly Monotone f is uniformly monotone wrt y if it is monotone in the same way for all choices of x y Examples: xy yz is not uniformly monotone wrt y, whereas it is monotonic wrt y xy yz is uniformly monotone wrt x in domain {y 0} (2n) to (n2 n ) to (2n) Linear systems are uniformly monotone Linear Uniformly monotone Monotone Ashish Tiwari Reals in Hybrid Systems: 22

Uniformly Monotone Nonlinear Example Phytoplankton Growth Model: ẋ 1 = 1 x 1 x 1x 2 4, ẋ 2 = (2x 3 1)x 2, ẋ 3 = x 1 4 2x 2 3, Monotone, but not multiaffine Uniformly monotone in the positive quadrant Box invariant sets can be computed by solving 1 u 1 u 1l 2 4 0, u 2 (2u 3 1) 0, 1 l 1 l 1u 2 4 0, l 2 (2l 3 1) 0, u 1 4 2u 2 3 0, l 14 2l3 2 0. One possible solution: l = (0, 0, 0) and u = (2, 1, 1/2) Ashish Tiwari Reals in Hybrid Systems: 23

Continuous to Hybrid Systems Hybrid systems = control flow graph over continuous systems Analysis of each node Control flow: loops If dynamics are simple (timed, multirate), discrete control flow can be complex If dynamics are complex, control flow needs to be restricted Ashish Tiwari Reals in Hybrid Systems: 24

Summary Continuous and Hybrid Systems can model biological and control systems We can use ideas, such as, inductive invariants, for analysis All symbolic analysis requires reasoning over the reals Biological systems tend to be box invariant Monotonicity interesting property that can be utilized for analysis Biological systems are monotone or nearly-monotone (Sontag) Ashish Tiwari Reals in Hybrid Systems: 25