slides - LIX

Report 3 Downloads 74 Views
Characterizing Algebraic Invariants by Differential Radical Invariants Khalil Ghorbal Carnegie Mellon university Joint work with Andr´ e Platzer

CEA List April 3rd, 2014

K. Ghorbal (CMU)

Invited Talk

1

Differential Radical Invariants

1 / 30

Introduction

Context: Hybrid Systems Model

Sensing:

read data from sensors

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model

Sensing: Control:

read data from sensors actuate

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model

Sensing: read data from sensors Control: actuate Plant: evolve

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model

( Sensing: read data from sensors Control: actuate Plant: evolve )∗

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model

Init −→ ( Sensing: read data from sensors Control: actuate Plant: evolve )∗ Safety

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model

Init −→ [ ( Sensing: read data from sensors Control: actuate Plant: evolve )∗ ] Safety

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Context: Hybrid Systems Model Init −→ [ ( Sensing: read data from sensors Control: actuate Plant: Evolve )∗ ] Safety Evolution • Continuous time • Ordinary Differential Equations (ODE)

K. Ghorbal (CMU)

Invited Talk

2

Differential Radical Invariants

2 / 30

Introduction

Algebraic Differential Equations

Example x˙1 = −x2 x˙3 =

x˙2 = x1

x42

x˙4 = x3 x4

Formally dxi (t) = x˙ i = pi (x), 1 ≤ i ≤ n . dt

K. Ghorbal (CMU)

Invited Talk

3

Differential Radical Invariants

3 / 30

Introduction

Algebraic Invariant Expression x˙1 = −x2 x˙3 =

x˙2 = x1

x42

x˙4 = x3 x4

1.0

x2

0.5

0.0

-0.5

-1.0 -1.0

-0.5

0.0 x1

0.5

1.0

Solution for x0 = (1, 0, 0, 1) for t = [0, 1] K. Ghorbal (CMU)

Invited Talk

4

Differential Radical Invariants

4 / 30

Introduction

Algebraic Invariant Expression x˙1 = −x2 x˙3 =

x˙2 = x1

x42

x˙4 = x3 x4

1.0

x2

0.5

0.0

-0.5

-1.0 -1.0

-0.5

0.0 x1

0.5

1.0

Solution for x0 = (1, 0, 0, 1) for t = [0, 2] K. Ghorbal (CMU)

Invited Talk

4

Differential Radical Invariants

4 / 30

Introduction

Algebraic Invariant Expression x˙1 = −x2

x˙2 = x1

x42

x˙3 =

x˙4 = x3 x4

1.0

x2

0.5

0.0

-0.5

-1.0 -1.0

-0.5

0.0 x1

0.5

1.0

∀t, x1 (t)2 + x2 (t)2 − 1 = 0 K. Ghorbal (CMU)

Invited Talk

4

Differential Radical Invariants

4 / 30

Introduction

Algebraic Invariant Expression

Geometrically def

O(x0 ) = {x(t) | t ≥ 0} ∈ Set of roots of h(x1 , x2 )

K. Ghorbal (CMU)

Invited Talk

5

Differential Radical Invariants

5 / 30

Introduction

Algebraic Invariant Expression

Geometrically def

O(x0 ) = {x(t) | t ≥ 0} ∈ Set of roots of h(x1 , x2 ) Algebraically h(x1 , x2 ) = x12 + x22 − 1(= 0)

K. Ghorbal (CMU)

Invited Talk

5

Differential Radical Invariants

5 / 30

Introduction

Algebraic Invariant Expression

Geometrically def

O(x0 ) = {x(t) | t ≥ 0} ∈ Set of roots of h(x1 , x2 ) Algebraically h(x1 , x2 ) = x12 + x22 − 1(= 0) Algebraic Invariant Expression ∀t, h(x(t)) = 0, for all x(t) solution of the Initial Value Problem.

K. Ghorbal (CMU)

Invited Talk

5

Differential Radical Invariants

5 / 30

Introduction

Problems

I. Checking the invariance of Algebraic Expression Given p, and x0 root of h(x) (h(x0 ) = 0), is h(x) = 0 an algebraic invariant expression ? (∀t ≥ 0, h(x(t)) = 0)

II. Generate Algebraic Invariant Expression Given p, and Init, how to generate algebraic invariant expressions ? (h(x) = 0)

K. Ghorbal (CMU)

Invited Talk

6

Differential Radical Invariants

6 / 30

Time Abstraction

Outline

1

Introduction

2

Time Abstraction

3

Characterization of Invariant Expressions

4

Checking & Generation

5

Conclusion

K. Ghorbal (CMU)

Invited Talk

7

Differential Radical Invariants

7 / 30

Time Abstraction

Variety Embedding of Orbits Zariski Closure

Vanishing Ideal: all polynomials that vanish on O(x0 ) def

I (O(x0 )) = {h ∈ R[x] | ∀x ∈ O(x0 ), h(x) = 0} Affine (Real) Variety: common roots of all polynomials in I def

V (I ) = {x ∈ Rn | ∀h ∈ I , h(x) = 0} Closure: Sound Abstraction O(x0 ) ⊆ V (I (O(x0 )))

K. Ghorbal (CMU)

Invited Talk

8

Differential Radical Invariants

8 / 30

Time Abstraction

Variety Embedding of Orbits Zariski Closure

Vanishing Ideal: all polynomials that vanish on O(x0 ) def

I (O(x0 )) = {h ∈ R[x] | ∀x ∈ O(x0 ), h(x) = 0} Affine (Real) Variety: common roots of all polynomials in I def

V (I ) = {x ∈ Rn | ∀h ∈ I , h(x) = 0} Closure: Sound Abstraction O(x0 ) ⊆ V (I (O(x0 )))

K. Ghorbal (CMU)

Invited Talk

8

Differential Radical Invariants

8 / 30

Time Abstraction

Variety Embedding of Orbits Zariski Closure

Vanishing Ideal: all polynomials that vanish on O(x0 ) def

I (O(x0 )) = {h ∈ R[x] | ∀x ∈ O(x0 ), h(x) = 0} Affine (Real) Variety: common roots of all polynomials in I def

V (I ) = {x ∈ Rn | ∀h ∈ I , h(x) = 0} Closure: Sound Abstraction O(x0 ) ⊆ V (I (O(x0 )))

K. Ghorbal (CMU)

Invited Talk

8

Differential Radical Invariants

8 / 30

Time Abstraction

Variety Embedding of Orbits Zariski Closure

Vanishing Ideal: all polynomials that vanish on O(x0 ) def

I (O(x0 )) = {h ∈ R[x] | ∀x ∈ O(x0 ), h(x) = 0} Affine (Real) Variety: common roots of all polynomials in I def

V (I ) = {x ∈ Rn | ∀h ∈ I , h(x) = 0} Closure: Sound Abstraction O(x0 ) ⊆ V (I (O(x0 ))) V (I (O(x0 ))) is the smallest variety that contains O(x0 ) K. Ghorbal (CMU)

Invited Talk

8

Differential Radical Invariants

8 / 30

Time Abstraction

Variety Embedding

O(x0 ) Orbit

α

−→

I (O(x0 )) Vanishing Ideal

K. Ghorbal (CMU)

γ

−→

Invited Talk

V (I (O(x0 ))) Closure

9



O(x0 ) Orbit

Differential Radical Invariants

9 / 30

Time Abstraction

Variety Embedding

O(x0 ) Orbit

α

−→

I (O(x0 )) Vanishing Ideal

K. Ghorbal (CMU)

γ

−→

Invited Talk

V (I (O(x0 ))) Closure

9



O(x0 ) Orbit

Differential Radical Invariants

9 / 30

Time Abstraction

Variety Embedding

O(x0 ) Orbit

α

−→

I (O(x0 )) Vanishing Ideal

K. Ghorbal (CMU)

γ

−→

Invited Talk

V (I (O(x0 ))) Closure

9



O(x0 ) Orbit

Differential Radical Invariants

9 / 30

Time Abstraction

Variety Embedding

O(x0 ) Orbit

α

−→

I (O(x0 )) Vanishing Ideal

K. Ghorbal (CMU)

γ

−→

Invited Talk

V (I (O(x0 ))) Closure

9



O(x0 ) Orbit

Differential Radical Invariants

9 / 30

Time Abstraction

Variety Embedding

O(x0 ) Orbit

α

−→

I (O(x0 )) Vanishing Ideal

γ

−→

Limitation: Zariski Dense Varieties x˙ = x O(x0 ) = [x0 , ∞[ I = h0i

K. Ghorbal (CMU)

Invited Talk

V (I (O(x0 ))) Closure



O(x0 ) Orbit

V (I (O(x0 ))) = R

9

Differential Radical Invariants

9 / 30

Characterization of Invariant Expressions

Outline

1

Introduction

2

Time Abstraction

3

Characterization of Invariant Expressions

4

Checking & Generation

5

Conclusion

K. Ghorbal (CMU)

Invited Talk

10

Differential Radical Invariants

10 / 30

Characterization of Invariant Expressions

Properties of I (O(x0 )) (abstract domain)

I (O(x0 )): The set of all polynomials that vanish on O(x0 ) I (O(x0 )) is an ideal • 0 ∈ I (O(x0 )) • if h1 , h2 ∈ I (O(x0 )), then h1 + h2 ∈ I (O(x0 )) • if h ∈ I (O(x0 )), then q h ∈ I (O(x0 )), for any polynomial q

K. Ghorbal (CMU)

Invited Talk

11

Differential Radical Invariants

11 / 30

Characterization of Invariant Expressions

Properties of I (O(x0 )) (abstract domain)

I (O(x0 )): The set of all polynomials that vanish on O(x0 ) I (O(x0 )) is an ideal • 0 ∈ I (O(x0 )) • if h1 , h2 ∈ I (O(x0 )), then h1 + h2 ∈ I (O(x0 )) • if h ∈ I (O(x0 )), then q h ∈ I (O(x0 )), for any polynomial q

I (O(x0 )) is a Differential Ideal if h ∈ I (O(x0 )), then

K. Ghorbal (CMU)

dh dt

∈ I (O(x0 )).

Invited Talk

11

Differential Radical Invariants

11 / 30

Characterization of Invariant Expressions

Properties of I (O(x0 )) (abstract domain) I (O(x0 )): The set of all polynomials that vanish on O(x0 ) I (O(x0 )) is an ideal • 0 ∈ I (O(x0 )) • if h1 , h2 ∈ I (O(x0 )), then h1 + h2 ∈ I (O(x0 )) • if h ∈ I (O(x0 )), then q h ∈ I (O(x0 )), for any polynomial q

I (O(x0 )) is a Differential Ideal if h ∈ I (O(x0 )), then Instead of

dh dt ,

dh dt

∈ I (O(x0 )).

we will use Lp (h): The Lie Derivative of h.

K. Ghorbal (CMU)

Invited Talk

11

Differential Radical Invariants

11 / 30

Characterization of Invariant Expressions

Lie derivative along a vector field

Definition n X ∂h Lp (h) = pi (x) ∈ R[x] ∂xi def

i=1

Properties • Algebraic differentiation (chain rule) • Do not require x(t) (the solution of the ODE) • Corresponds to the time derivative when x = x(t)

K. Ghorbal (CMU)

Invited Talk

12

Differential Radical Invariants

12 / 30

Characterization of Invariant Expressions

Differential Radical Invariants

Theorem h ∈ I (O(x0 )) if and only if (N)

• ∃ g0 , . . . , gN−1 ∈ R[x]: Lp (h) =

PN−1 i=0

(i)

gi Lp (h)

• N finite (0)

(N−1)

• Lp (h)(x0 ) = 0, . . . , Lp

K. Ghorbal (CMU)

(h)(x0 ) = 0

Invited Talk

13

Differential Radical Invariants

13 / 30

Characterization of Invariant Expressions

Special Cases

Invariant Polynomial Functions Lp (h) = 0 ←→ N = 1 and g0 = 0

Darboux Polynomials [Darboux 1878, Painlev´e, Poincar´e . . . ] Lp (h) = g0 h ←→ N = 1

K. Ghorbal (CMU)

Invited Talk

14

Differential Radical Invariants

14 / 30

Characterization of Invariant Expressions

Special Cases

Invariant Polynomial Functions Lp (h) = 0 ←→ N = 1 and g0 = 0

Darboux Polynomials [Darboux 1878, Painlev´e, Poincar´e . . . ] Lp (h) = g0 h ←→ N = 1

K. Ghorbal (CMU)

Invited Talk

14

Differential Radical Invariants

14 / 30

Checking & Generation

Outline

1

Introduction

2

Time Abstraction

3

Characterization of Invariant Expressions

4

Checking & Generation

5

Conclusion

K. Ghorbal (CMU)

Invited Talk

15

Differential Radical Invariants

15 / 30

Checking & Generation

Checking Invariance of Candidates

I. Checking the invariance of Algebraic Expression Given p, and x0 root of h(x) (h(x0 ) = 0), is h(x) = 0 is an algebraic invariant expression ? (∀t ≥ 0, h(x(t)) = 0)

A Necessary and Sufficient Proof Rule V (i) h = 0 → N−1 i=0 Lp (h) = 0 (DRI) . (h = 0) → [x˙ = p](h = 0)

K. Ghorbal (CMU)

Invited Talk

16

Differential Radical Invariants

16 / 30

Checking & Generation

DRI: Algorithm Data: h, p, x Result: Boolean: True, False. N ←1 GB ← {h} `←h symbs ← Variables[p, h] while true do GB ← Gr¨obnerBasis[GB, x] LieD ← LieDerivative[`, p, x] Rem ← PolynomialRemainder[LieD, GB, x] if Rem = 0 then return True else Reduce ← QE[∀ symbs, h = 0 → LieD = 0] if ¬Reduce then return False Append[GB, LieD] ` ← LieD N ← N +1

K. Ghorbal (CMU)

Invited Talk

17

Differential Radical Invariants

17 / 30

Checking & Generation

Benchmarks Joint work with Andrew Sogokon

log10 HtL

1 DI

0

Darboux Lie

-1

LieZero LieStar

-2

DRI

-3 0

K. Ghorbal (CMU)

10

20 30 40 50 Number of problems solved

Invited Talk

18

60

70

Differential Radical Invariants

18 / 30

Checking & Generation

Generation of Invariant Varieties II. Generate Algebraic Invariant Expression Given p, and Init, how to generate algebraic invariant expressions ? (h(x) = 0)

Theorem S ⊆ Rn is an invariant variety if and only if S is the set of roots of the system ^ (i) Lp (h) = 0, 0≤i≤N−1

for some polynomial h.

K. Ghorbal (CMU)

Invited Talk

19

Differential Radical Invariants

19 / 30

Checking & Generation

In practice

In practice Find h and N, such that: (N)

Lp (h) =

N−1 X

(i)

gi Lp (h)

i=0

: The set of roots of

^

(i)

Lp (h) = 0,

0≤i≤N−1

is an invariant variety.

K. Ghorbal (CMU)

Invited Talk

20

Differential Radical Invariants

20 / 30

Checking & Generation

Matrix Representation: Intuition invariant of degree 1 x˙1 = a1 x1 + a2 x2 x˙2 = b1 x1 + b2 x2

h = α1 x1 + α2 x2 + α3 x0 Lp (h) = α1 (a1 x1 + a2 x2 ) + α2 (b1 x1 + b2 x2 )

∃ ?β ∈ R s.t. Lp (h) = βh

   (−a1 + β)α1 + (−b1 )α2 = 0 −a1 + β −b1 0 α1 (−a2 )α1 + (−b2 + β)α2 = 0 ↔  −a2 −b2 + β 0  α2  = 0 (β)α3 =0 0 0 β α3 K. Ghorbal (CMU)

Invited Talk

21

Differential Radical Invariants

21 / 30

Checking & Generation

Matrix Representation Polynomial h gi

↔ ↔ ↔

n+d d



Coefficients (d degree of h) α = (α1 , α2 , . . . , αr ) β i = (β1 , β2 , . . . , βsi )

Matrix Representation (N)

Lp (h) =

N−1 X

(i)

gi Lp (h) ↔ M(β)α = 0

i=0

def

α lies in the Kernel of M(β) = {α ∈ Rr | M(β)α = 0}

K. Ghorbal (CMU)

Invited Talk

22

Differential Radical Invariants

22 / 30

Checking & Generation

Example: n = 2, d = 1, N = 1

invariant of degree 1 x˙1 = a1 x1 + a2 x2 x˙2 = b1 x1 + b2 x2

h = α1 x1 + α2 x2 + α3 x0 Lp (h) = α1 (a1 x1 + a2 x2 ) + α2 (b1 x1 + b2 x2 )

|M(β)| = β(β 2 − (a1 + b2 )β − a2 b1 + a1 b2 ) • ker(M(0)) = h(0, 0, 1)i • α ∈ h(0, 0, 1)i ∩ x0 ⊥

K. Ghorbal (CMU)

Invited Talk

23

Differential Radical Invariants

23 / 30

Checking & Generation

Example System

x˙1 = −x2

x˙2 = x1

x˙3 = x42

x˙4 = x3 x4

Differential Radical Invariants (2)

h = −1 + x1 x4 and Lp (h) = x3 − x2 x4 and Lp (h) = x42 − x32 − 1

Orbit K. Ghorbal (CMU)

Roots of Lp (h) Invited Talk

24

(2)

Roots of Lp (h) Differential Radical Invariants

24 / 30

Checking & Generation

Example: cont’d

Overapproximation of O(x0 ) K. Ghorbal (CMU)

Invited Talk

25

Differential Radical Invariants

25 / 30

Checking & Generation

Case Study: Longitudinal Dynamics of an Airplane 6th Order Longitudinal Equations X − g sin(θ) − qw m Z w˙ = + g cos(θ) + qu m x˙ = cos(θ)u + sin(θ)w u˙ =

u : axial velocity w : vertical velocity x : range

z˙ = − sin(θ)u + cos(θ)w M q˙ = Iyy θ˙ = q

K. Ghorbal (CMU)

Invited Talk

z : altitude q : pitch rate θ : pitch angle

26

Differential Radical Invariants

26 / 30

Checking & Generation

Case Study: Generated Invariants

Automatically Generated Invariant Functions     X Z Mz + gθ + − qw cos(θ) + + qu sin(θ) Iyy m m     Mx Z X − + qu cos(θ) + − qw sin(θ) Iyy m m 2Mθ − q2 + Iyy

K. Ghorbal (CMU)

Invited Talk

27

Differential Radical Invariants

27 / 30

Conclusion

Conclusion

• Variety embedding of the reachable set (Zariski Closure) • Characterizing elements of the vanishing ideal I (O(x0 )) • New Necessary and sufficient proof rule (DRI) • Leveraging linear algebra tools to generate algebraic invariant equations

K. Ghorbal (CMU)

Invited Talk

28

Differential Radical Invariants

28 / 30

Conclusion

Thank you for attending !

[email protected]

K. Ghorbal (CMU)

Invited Talk

29

Differential Radical Invariants

29 / 30

Conclusion

Enforcing Invariants

def

δ = (a1 − b2 )2 + 4a2 b1 ≥ 0 √ √ • β ∈ {0, 12 (a1 + b2 + δ), 12 (a1 + b2 − δ)}   ⊥  √ √ • If x0 ∈ a1 − b2 ± δ, 2a2 , 0 then α = a1 − b2 ± δ, 2a2 , 0 • α is an Eigenvector

If a2 = 0, β ∈ {0, a1 , b2 }

K. Ghorbal (CMU)

...

Invited Talk

30

Differential Radical Invariants

30 / 30