Upload
others
View
10
Download
0
Embed Size (px)
Citation preview
Modeling and Analysis of Dynamic Systems
Dr. Guillaume Ducard
Fall 2017
Institute for Dynamic Systems and Control
ETH Zurich, Switzerland
G. Ducard c© 1 / 62
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 2 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 3 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Remark:(from script p.89) For those students who followed thecourses “Control Systems I and II,” most of the material presentedin this chapter will be a repetition. However, since several pointsare discussed in more detail and since additional material isintroduced, it is not recommended to skip these classes.
Motivations
Once the modeling of a system is done, we are interested inanalysing this system for:
stability
controllability, observability
performance
Methodology?
G. Ducard c© 4 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Introduction
Models are usually nonlinear with physical (“non-normalized”):
states x, inputs u,
and outputs y.
according to dynamic and output equations:
d
dtx(t) = f(x(t), u(t), t), y(t) = g(x(t), u(t), t)
However, difficulties arise for systems which:
1 are nonlinear: difficult to analyze
2 have non-normalized variables:
are prone to numerical problemsthe state variables are hard to compare to one another.
Solution for analysis: Normalize and linearize around a chosen setpoint.G. Ducard c© 5 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Analysis of Linear Systems
Questions
1 Assuming known input signals and initial conditions:⇒ what output signals are to be expected?
2 Which points in the state space may be:
reached by appropriate input signals?
observed by analyzing the associated output signals?
3 What parts of a dynamic system are relevant for the input/outputcharacteristics?
G. Ducard c© 6 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
NormalizationConsider the scaling factors: xi,0, uj,0, yk,0 such that
xi(t) =xi(t)
xi,0, uj(t) =
uj(t)
uj,0, yk(t) =
yk(t)
yk,0,
The new normalized variables xi(t), uj(t) and yk(t) will have nophysical units, and are usually close to 1.Since xi,0 is constant
d
dtxi(t) = xi,0
d
dtxi(t)
→ no change in the dynamics (only scaled).The normalization may be expressed in vector notation as
x = T · x, T = diag{x1,0, . . . , xn,0}
“Similarity transformation” matrix does not change the systemscharacteristics (stability, input-output behavior, etc.).
G. Ducard c© 7 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 8 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Linearization
The system after normalization has the form
1 Dynamics equation
d
dtx(t) = x(t) = f0(x(t),u(t), t),
2 Output equation
y(t) = g0(x(t),u(t), t)
with x(t) ∈ Rn,u(t) ∈ R
m,y(t) ∈ Rp,
where f0 and g0 nonlinear normalized functions.
Remark: here we can use, the true variable or the normalized. In the
following we will simply use the notations x, y, u.G. Ducard c© 9 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
System dynamics in vector form
x(t) = f(x, u, t)
x1x2...xn
=
f1(x, u)f2(x, u)
...fn(x, u)
G. Ducard c© 10 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Notion of Neighborhood
Linearization behavior in a “small” neighborhood
1 operating point {xo, uo}
Br := {x ∈ Rn | ||x− xo||
2 + ||u− uo||2 ≤ r}
2 equilibrium point {xe, ue}
Br := {x ∈ Rn | ||x− xe||
2 + ||u− ue||2 ≤ r}
around a chosen equilibrium point {xe, ue}, f0(xe, ue, t) = 0.
G. Ducard c© 11 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Geometric Interpretation
In the 1-D case, the dynamics of the system are x = f(x, u)
x
u
x&
0 0,x u
0 0( , )f x u
0 0,x u
f
u
¶
¶
0 0,x u
f
x
¶
¶
G. Ducard c© 12 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Geometric Interpretation
x
u
x&
0 0,x u
0 0( , )f x u
0 0,x u
f
u
¶
¶
0 0,x u
f
x
¶
¶
x = f(x, u) = f(x0, u0)+∂f
∂x|x0,u0 (x− x0)︸ ︷︷ ︸
δx
+∂f
∂u|x0,u0 (u− u0)︸ ︷︷ ︸
δu
+1
2
∂2f
∂x2|x0,u0 (x− x0)
2 + . . .G. Ducard c© 13 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Geometric Interpretation
x
u
x&
0 0,x u
0 0( , )f x u
0 0,x u
f
u
¶
¶
0 0,x u
f
x
¶
¶
˙δx = f(x, u)− f(x0, u0) ≈∂f
∂x|x0,u0 (x− x0)︸ ︷︷ ︸
δx
+∂f
∂u|x0,u0 (u− u0)︸ ︷︷ ︸
δu
G. Ducard c© 14 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Deviation Around Equilibrium Point
x(t) = x(t)− xe,
u(t) = u(t)− xe,
y(t) = y(t)− g0(xe, ue, t)
such that in the new coordinates the ODEs are
d
dtx(t) = f0(x(t), u(t), t),
y(t) = g0(x(t), u(t), t)
with f0(0, 0, t) = 0.G. Ducard c© 15 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Only small deviations from the setpoint are considered. Thefollowing new variables are introduced
x(t) = xe + δx(t) with |δx| ≪ |xe|,
u(t) = ue + δu(t) with |δu| ≪ |ue|,
y(t) = ye + δy(t) with |δy| ≪ |ye|
Taylor series neglecting all terms of second and higher order yields
d
dtδx(t) =
∂f0∂x
|xe,ueδx(t) +∂f0∂u
|xe,ueδu(t)
and
δy(t) =∂g0∂x
|xe,ueδx(t) +∂g0∂u
|xe,ueδu(t)
G. Ducard c© 16 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Notationddtx(t) = Ax(t) +Bu(t)
y(t) = Cx(t) +Du(t)
System can be described using (infinitely) many other coordinatesystems (similarity transformations)
x = T x, T ∈ Rn×n, det(T ) 6= 0
The columns of T are the unit vectors of the new coordinate frameexpressed in the old coordinate system.In the new coordinates
ddt x(t) = T−1ATx(t) + T−1Bu(t) = Ax(t) + Bu(t)
y(t) = CT x(t) +Du(t) = Cx(t) +Du(t)
G. Ducard c© 17 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
The input-output behavior (i.e., the transfer function) is notaffected by the specific choice of coordinates
P (s) = CT [sI − T−1AT ]−1T−1B +D
= C[sI −A]−1B +D = P (s)
Fundamental system properties (stability, controllability, etc.) areindependent of the coordinates chosen. However, if the systemsODEs are derived by physical arguments there are reasons forsticking to these “natural” coordinates.
G. Ducard c© 18 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 19 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Solution of Linear Ordinary Differential Equations (ODE)
Objective:prediction of the state x and the output y of a linear systemdescribed by its matrices {A,B,C,D},
ddtx(t) = x(t) = Ax(t) +Bu(t)
y(t) = Cx(t) +Du(t)
with
initial conditions x(0),
control signal u,
are known.
G. Ducard c© 20 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Matrix exponential
eAt = I +1
1!At+
1
2!(At)2 +
1
3!(At)3 + · · ·+
1
n!(At)n + · · ·
Main property
deAt
dt= A eAt = eAtA (commute)
Properties
1 In general, eA · eB 6= eA+B.
2 Only if A and B commute (AB = BA), eA · eB = eA+B.
3 Accordingly, eAte−At = eA(t−t) = e0 = I ⇒ (eAt)−1 = e−At.
G. Ducard c© 21 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Solution to the initial value problem
x(t) = A x(t) +B u(t), x(0) = x0
Multiplying (1) on the left-hand side by the term e−At yields
e−Atx(t) = e−AtAx(t) + e−AtBu(t) ,
⇐⇒ e−Atx(t)− e−AtAx(t) = e−AtBu(t) . (1)
The left-hand side of (1) is equal to d(e−Atx(t))dt ,indeed
d(e−Atx(t))
dt= −Ae−Atx(t) + e−Atx(t) (2)
therefore (1) is rewritten as
d(e−Atx(t))
dt= e−AtBu(t) . (3)
G. Ducard c© 22 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Integrating the above equation on the time interval [0, t] yields
∫ t
0
d(e−Aτx(τ))
dτdτ =
∫ t
0e−AσBu(σ)dσ,
e−Atx(t)− x(0) =
∫ t
0e−AσBu(σ)dσ ,
e−Atx(t) = x(0) +
∫ t
0e−AσBu(σ)dσ ,
x(t) = eAtx(0) +
∫ t
0eA(t−σ)Bu(σ)dσ .
G. Ducard c© 23 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
x(t) = eAtx(0) +
∫ t
0eA(t−σ)Bu(σ)dσ
The continuous-time transition matrix is defined as follows:
Φ(t) = eAt = I +At+(At)2
2!+ ...+
(At)n
n!+ ...
and finally the continuous solution for x(t) is written as
x(t) = Φ(t)x(0) +
∫ t
0Φ(t− σ)B u(σ)dσ
y(t) = Cx(t) +Du(t)
G. Ducard c© 24 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 25 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Introduction
Stability = most important concept in analysis of dynamic systems
Stability is always connected to a “metric,” i.e., the size of vectorsis important.⇒ The symbol ||x|| will be used to denote this operation, andany norm will be acceptable.
For instance the Euclidean length:
x ∈ Rn, ||x||2 :=
n∑
i=1
x2i
G. Ducard c© 26 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Lyapunov Stability
Linear and time-invariant systems:
d
dtx(t) = A · x(t), x(0) = x0, 0 < ||x0|| <∞ (4)
The input u(t) = 0 for stability analysis, only A is important.
For stability: three possible cases. The system (4) is
1 asymptotically stable if limt→∞
||x(t)|| = 0;
2 stable if ||x(t)|| <∞ ∀ t ∈ [0,∞]; and
3 unstable if limt→∞
||x(t)|| = ∞,
where the norm is the Euclidean length (defined before).Remark: A general definition for nonlinear systems will be seen later.
G. Ducard c© 27 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
For linear systems, the stability of the system
d
dtx(t) = Ax(t), x(0) = x0 6= 0
is tightly related to the eigenvalues of the matrix A.
Recall Matrix A characterizes linear mapping Rn → R
n
y = A x, x, y ∈ Rn, A ∈ R
n×n
Eigenvalue - eigenvector
An eigenvector vi of A is a vector which is mapped onto itself,through the scaling parameter λi called the eigenvalue of vi,according to:
A vi = λi vi
Remark: Even for real matrices A ∈ Rn×n, λi and vi can be complex
(always complex conjugate pairs).G. Ducard c© 28 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
If n linearly independent eigenvectors exist, then the matrix
T = [v1 . . . vn]
which – by definition – diagonalizes A, i.e.,
A T = T Λ ⇒ T−1 A T = Λ
where
Λ =
λ1 0 . . . 0...
......
...0 . . . 0 λn
Remark:If all eigenvalues are distinct, i.e., λi 6= λj for all i 6= j, then nindependent eigenvectors always exist.
G. Ducard c© 29 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
If there are multiple (same) eigenvalues ⇒ situation more complex.
Two scalars are important:
multiplicity of eigenvalue λi: ri
rank loss of the matrix [λiI −A]: ρi, associated with theeigenvalue λi.
In the general case, three distinct situations arise:
1 ρi = 1, ⇒ only 1 eigenvector exists for the (ri > 1) identicaleigenvalues λi,
2 ρi < ri, ⇒ there are less than ri independent eigenvectors,
3 ρi = ri, ⇒ exactly r independent eigenvectors exist.
The third case is similar to the regular case.
Remark: When all eigenvalues are distinct: ri = ρi = 1 for alli = 1, . . . , n and the matrix A is “diagonal.”
G. Ducard c© 30 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Jordan Form
In the first and in the second case, A is not diagonalizable but canbe brought to what is known as a “Jordan Form”
Ji =
λi 1 0 . . . . . . 00 λi 1 0 . . . 0... . . . . . . . . . . . .
...... . . . . . . . . . . . .
...0 . . . . . . 0 λi 10 . . . . . . . . . 0 λi
G. Ducard c© 31 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
G. Ducard c© 32 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Stability of Linear Systems
If the matrix Λ is diagonal three situations can be encountered:
1 all eigenvalues have negative real parts σi < 0 ⇒ system isasymptotically stable;
2 some eigenvalues have zero real parts σi = 0, but none has apositive real part⇒ system is Lyapunov stable,
3 At least one eigenvalue has a positive real part σi > 0 ⇒system is unstable.
Remark: For cyclic or mixed matrices A, this is no longer true. In fact,
systems with multiple eigenvalues on the imaginary axis can be stable
only if all Jordan blocks associated to multiple eigenvalues with real part
zero are diagonal.
G. Ducard c© 33 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
NormalizationLinearizationSolution of Linear ODEStability of Linear Systems
Example: “series double integrator structure”
d
dt
[x1x2
]=
[0 01 0
]·
[x1x2
]
The continuous-time transition matrix is defined as follows:
Φ(t) = eAt = I +At+(At)2
2!+ ...+
(At)n
n!+ ...
and finally the continuous solution for x(t) is written as
x(t) = Φ(t)x(0) +
∫ t
0Φ(t− σ)B u(σ)dσ
Transition matrix (stability analysis u = 0).
x(t) =
{
I +1
1!A t +
1
2!A
2t2+
1
3!A
3t3+ · · ·
}
x(0) =
1 0
t 1
x(0)
G. Ducard c© 34 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 35 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Reachability of Linear Systems
x(t) = eAtx(0) +
∫ t
0eA(t−σ)Bu(σ)dσ
Investigate all states that can be reached at time τ starting atx(0) = 0
x(τ) = eAτ∫ τ
0e−AσBu(σ) dσ
Matrix eAτ regular for all τ <∞, therefore use x∗(τ) = e−Aτx(τ)
x∗(τ) =
∫ τ
0e−AσBu(σ) dσ
Using the definition of the matrix exponential
x∗(τ) =
∫ τ
0
{I −
1
1!Aσ +
1
2!(Aσ)2 −
1
3!(Aσ)3 + · · ·
}Bu(σ) dσ
G. Ducard c© 36 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
and from that
x∗(τ) = B
∫ τ
0u(σ) dσ−AB
∫ τ
0
1
1!σu(σ) dσ+A2B
∫ τ
0
1
2!σ2u(σ) dσ+· ·
Let’s define the integral basis as:
vi =
∫ τ
0
1
i!σiu(σ) dσ, i = 0, 1, . . .
The reachable states x∗ are then defined by the linear equation
x∗(τ) =[B AB A2B A3B · · ·
]
v1
v2
v3
v4...
= Rv
G. Ducard c© 37 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Define
Rn =[B AB A2B A3B · · · An−1B
]
Therefore, condition rank(Rn) = n guarantees that for arbitraryx(0) = x∗ 6= 0 a suitable control signal u∗(x∗) exists. The system is saidto be reachable.
Read page 105 in the script, last 2 paragraphs.
G. Ducard c© 38 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 39 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Observability of Linear SystemsIs it possible to reconstruct x(0) using the output signal y(t) only?Input u(t) = 0 for all times t, therefore
y(t) = Cx(t) ddty(t) = CAx(t) d2
dt2y(t) = CA2x(t) etc.
Evaluating this equation for t = 0 yields the linear equation
y(t)
ddty(t)
ddt2
y(t)...
(t=0)
= w(0) =
C
CA
CA2
...
x(0) = Ox(0)
By “measuring” the vector w(0), the unknown initial state vectorx(0) can be found uniquely if O is invertible ⇐⇒ det(O) 6= 0,⇐⇒ O is full rank. G. Ducard c© 40 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Cayley-Hamilton theorem
On =
C
CA...
CAn−1
If rank(On) = n, the system is observable.
G. Ducard c© 41 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 42 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Ball on Wheel
y(t)
u(t)
r,m, ϑχ(t)
R,Θ
ϕ(t)
ψ(t)
mg
wheel: mass moment of inertia around c.o.g. is Θ, radius R,
ball: mass m, mass moment of inertia around c.o.g. ϑ, radius rG. Ducard c© 43 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Ball-on-WheelLinearizing system at equilibrium ψ = ψ = χ = χ = 0 yields
δx(t) = A · δx(t) + b · δu(t), δy(t) = c · δx(t)
with
δx(t) =
δψ(t)
δψ(t)
δχ(t)
δχ(t)
A =
0 1 0 0
0 0 a1 0
0 0 0 1
0 0 a2 0
b =
0
b1
0
b2
cT =
0
0
c1
0
G. Ducard c© 44 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Parameters defined by
a1 = mgRϑΓ , a2 =
mg(R2ϑ+ r2Θ)(R + r)Γ
b1 = mr2 + ϑΓ , b2 = Rϑ
(R+ r)Γ, c1 = R+ r
To simplify the notation
Θ = 5ϑ, R = 3 r, ϑ = r2m, g = 10m2/s, r = 0.2m, m = 1kg
Controllability matrix
Rn =
0 50
190 75
76
50
190 75
760
0 5625
7220 13125
1444
5625
7220 13125
14440
,
det(Rn) = 263.444 ( 6= 0), not rank deficient, i.e., the system is completely controllable.G. Ducard c© 45 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Observability matrix
On =
0 0 45 0
0 0 0 45
0 0 14019 0
0 0 0 14019
det(On) = 0 (first 2 columns are equal to 0).
For this special case it is easy to see that the two state variables ψand ψ cannot be estimated using the output signal y as the onlyinformation.
G. Ducard c© 46 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
The linearized system is unstable. Its eigenvalues are
λ1 = λ2 = 0, λ3 = −λ4 = 3.03488
According to the Lyapunov principle, the nonlinear system must beunstable as well.However, this does not mean that the system cannot meet thedesired objective, i.e., to balance the ball at the equilibriumposition!
The question is now, can the system be stabilized by anappropriate feedback action?⇒ As it will be shown below, this is not possible.
G. Ducard c© 47 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
Transfer function from u→ y
P (s) =15
19 s2 − 175
The two observable states are those whose dynamics aredescribed by the two eigenvalues λ3,4.
The dynamics described by the two eigenvalues λ1,2, cannotbe influenced by feedback action. This subsystem has adouble eigenvalue at zero with rank loss only 1.
Therefore, this subsystem is unstable (intuition confirmed)!For simulations use simple feedback (lead-lag) controller
C(s) =k2 s+ k1τ s+ 1
=2.2417 s + 17.05
0.01 s + 1
G. Ducard c© 48 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
time t(s)
closed-loop step response y(t); solid=nolinear, dashed=linear
0 1 2 3 4 5 6 7 8 9 100
0.05
0.1
0.15
0.2
0.25
Figure: Reference step responses of the closed-loop “ball-on-wheel”system; all initial conditions equal to zero.
G. Ducard c© 49 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
time t(s)
closed-loop step response, hidden variables; solid=ψ, dashed=dψ/dt
0 1 2 3 4 5 6 7 8 9 10-160
-140
-120
-100
-80
-60
-40
-20
0
20
Figure: Behavior of the “hidden state variables” for the same referencestep as illustrated in previous Figure.
G. Ducard c© 50 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Reachability ConditionsObservability ConditionsExample: Ball on Wheel
time t(s)
solid=χ, dashed=dχ/dt
time t(s)
solid=ψ, dashed=dψ/dt
0 2 4 60 2 4 6-10
-9
-8
-7
-6
-5
-4
-3
-2
-1
0
1
-0.4
-0.3
-0.2
-0.1
0
0.1
0.2
0.3
Figure: Behavior of the closed-loop system for an initial condition ofχ(0) = π/12 rad, χ(0) = π/12 rad/s and reference values χr = χr = 0.
G. Ducard c© 51 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 52 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Balanced Realization and Order ReductionWith the matrices R and O one obtains “yes/no” answers. Whatabout quantitative criteria?Is a specific subspace “well or hardly” reachable?Closely linked to that question is the notion of system orderreduction.
System order reduction
consists in :
1 identifying those states that do not influence significantly theinput/output behavior of the system,
2 finding a smart way eliminate those “not so important” states.
G. Ducard c© 53 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Outline
1 Lecture 11: Analysis of Linear SystemsNormalizationLinearizationSolution of Linear ODEStability of Linear Systems
2 Lecture 11: Reachability and ObservabilityReachability ConditionsObservability ConditionsExample: Ball on Wheel
3 Lecture 11: Balanced Realization and Order ReductionIntroduction / ExampleGramian Matrices
G. Ducard c© 54 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Gramian Matrices
Controllability Gramian
WR =
∫∞
0eAσBBT eA
T σ dσ
The closer WR is to a singular matrix (det close to 0), the lesscontrollable the corresponding system will be.
Observability Gramian
WO =
∫∞
0eA
T σCT C eAσ dσ
The closer WO is to a singular matrix, the less observable thecorresponding system will be.
G. Ducard c© 55 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Gramian Matrices
The computation of the two Gramians appears to be difficult. Thefollowing result, however, simplifies those steps considerably.
If the system is Hurwitz, the two Gramian matrices are the
solutions of the two Lyapunov equations
AWR +WRAT = −BBT
andATWO +WOA = −CTC
G. Ducard c© 56 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Bad idea:
simply delete those system parts that do not significantlycontribute to the controllability or observability Gramian matrices(poor controllability compensated by excellent observability).
Better idea:
look for a coordinate transformation T · xb = x, which transformsthe original system into a system whose controllability andobservability Gramians are equal and diagonal, i.e.,
WR,b =WO,b = diag(σi), i = 1, . . . , n
Proper normalization is very important for this procedure to workcorrectly!
G. Ducard c© 57 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Assume: the last ν elements σj with j = n− ν + 1, . . . , n aresubstantially smaller than the other first n− ν elements σi withi = 1, . . . n− ν. Then the contribution of the last ν balancedmodes to the system’s IO behavior may be neglected.
First step: system partitioning
ddt
[x1(t)x2(t)
]=
[A11 A1,2
A2,1 A2,2
] [x1(t)x2(t)
]+
[B1
B2
]u(t)
y(t) = [C1 C2]
[x1(t)x2(t)
]+Du(t)
where x1 ∈ Rn−ν and x2 ∈ R
ν .
G. Ducard c© 58 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Since the contribution of the last ν states is small, the system canbe reduced by simply omitting the corresponding elements, i.e.,
ddtx1(t) = A11x1(t) +B1u(t)
y(t) = C1x1(t) +Du(t)
Typically, this will yield good agreement in the frequency domainbut, in general the DC gains of the original system and of thereduced-order system will be different.
G. Ducard c© 59 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
If this is to be avoided, a “singular perturbation” approach isbetter suited where:
1 the dynamics of the last ν states is neglected,2 but not their DC contributions.
The details of that approach are
d
dtx2(t) = 0 → x2(t) = −A−1
2,2[A2,1x1(t) +B2u(t)]
and
ddtx1(t) = [A11 −A1,2A
−12,2A2,1]x1(t) + [B1−A1,2A
−12,2B2]u(t)
y(t) = [C1 − C2A−12,2A2,1]x1(t) + [D − C2A
−12,2B2]u(t)
Always feasible if the original system was asymptotically stable (notrestrictive, otherwise Gramians do not exist).The next figure shows the step responses for increasing ν, red = originaland blue = reduced-order outputs, system order n = 7. G. Ducard c© 60 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
0 5 10 15 20 0 5 10 15 20
-0.6
-0.6-0.6
-0.4
-0.4-0.4
-0.2
-0.2-0.2
0
00
0.2
0.20.2
-0.5
0
0.5
00 55 1010 1515 2020
ν = 3 ν = 4
ν = 5 ν = 6
Time (sec)Time (sec)
Time (sec)Time (sec)
Amplitude
Amplitude
Amplitude
Amplitude
Step ResponseStep Response
Step ResponseStep Response
G. Ducard c© 61 / 62
Lecture 11: Analysis of Linear SystemsLecture 11: Reachability and Observability
Lecture 11: Balanced Realization and Order Reduction
Introduction / ExampleGramian Matrices
Next lecture + Upcoming Exercise
Next lecture
Case Study
Next exercises:
LinerarizingSystem balancing and order reduction
G. Ducard c© 62 / 62