Control Systems ILecture 4: Diagonalization, Modal Analysis, Intro to Feedback
Readings:
Emilio Frazzoli
Institute for Dynamic Systems and ControlD-MAVT
ETH Zurich
October 13, 2017
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 1 / 26
Tentative schedule
# Date Topic
1 Sept. 22 Introduction, Signals and Systems2 Sept. 29 Modeling, Linearization
3 Oct. 6 Analysis 1: Time response, Stability4 Oct. 13 Analysis 2: Diagonalization, Modal coordi-
nates.5 Oct. 20 Transfer functions 1: Definition and properties6 Oct. 27 Transfer functions 2: Poles and Zeros7 Nov. 3 Analysis of feedback systems: internal stability,
root locus8 Nov. 10 Frequency response9 Nov. 17 Analysis of feedback systems 2: the Nyquist
condition
10 Nov. 24 Specifications for feedback systems11 Dec. 1 Loop Shaping12 Dec. 8 PID control13 Dec. 15 Implementation issues14 Dec. 22 Robustness
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 2 / 26
Recap of the previous lecture
LTI system:
x(t) = Ax(t) + Bu(t),
y(t) = Cx(t) + Du(t).
Time response:
x(t) = eAtx0 +
∫ t
0
eA(t−τ)Bu(τ) dτ,
y(t) = CeAtx0 + C
∫ t
0
eA(t−τ)Bu(τ) dτ + Du(t).
Easy to compute if the matrix A is diagonal, in which case:
xi (t) = eλi tx0,i +
∫ t
0
eλi (t−τ)biu(τ) dτ,
y(t) =n∑
i=1
cixi (t) + Du(t).
The eigenvalues of A, λi , can be real or complex-conjugate, giving rise to simpleexponentials, or oscillations with exponentially changing magnitude, respectively.
Asymptotically stable if Re(λi ) < 0 for all i .
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 3 / 26
Today’s learning objectives
After today’s lecture, you should be able to:
Diagonalize a matrix using similarity transformations.
Describe the behavior of an LTI system in modal coordinates.
Understand concepts like controllability and observability.
Understand the basic effects of feedback control on the closed-loop dynamics.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 4 / 26
Similarity Transformations
The choice of a state-space model for a given system is not unique.
For example, let T be an invertible matrix, and consider a coordinatetranspormation x = Tx , i.e., x = T−1x . This is called a similaritytransformation.
The standard state-space model can be written as{x = Ax + Bu,y = Cx + Du.
⇒{
T ˙x = ATx + Bu,y = CT x + Du.
i.e.,
˙x = (T−1AT )x + (T−1B)u = Ax + Bu
y = (CT )x + Du = C x + Du.
You can check that the time response is exactly the same for the two models(A,B,C ,D) and (A, B, C , D)!
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 5 / 26
Diagonalization
Let λi , vi be respectively an eigenvalue and an eigenvector of A, i.e.,
Avi = λivi .
Now assume we have n (=dim. of x and A) independent eigenvectors; thenwe can assemble the eigenvectors into an invertible matrix V whose columnsare the eigenvectors vi . Then
AV = A
v1 v2 . . . vn
=
λ1v1 λ2v2 . . . λnvn
= VΛ.
In other words, if a square matrix A has a full set of independenteigenvectors, then it is diagonalizable (and vice-versa), with the similaritytransformation given by a matrix whose columns are the eigenvectors.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 6 / 26
Modal decomposition
The entries in the diagonal matrix A = Λ are the eigenvalues λ1, . . . , λn ofthe matrix A.
Since x(t) = eAt x(0), we get that each component of the homogeneoussolution is given by
xi (t) = eλi t xi (0).
Furthermore, if x(0) = vi for some i = 1, . . . , n, then by the definition ofmatrix exponential and eigenvalues/eigenvectors
x(t) = eAtvi = eλi tvi .
If the eigenvectors vi , i = 1, . . . , n form a basis, then we can always expressany initial condition as a linear combination of eigenvectors, i.e.,x(0) = V x(0), with x0 = V−1x0 , and write
x(t) =n∑
i=1
eλi t xi (0) vi .
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 7 / 26
Modal coordinates
Eigenvalues and eigenvectors of A define the modes of the system; thetransformed coordinates x = Vx are also called the modal coordinates.
The eigenvector vi defines the shape of the i-th mode;
The modal coordinate xi scales the mode (e.g., at the initial condition);
The eigenvalue λi defines how the amplitude of the mode evolves over time.
1 As an exponential eλi tx0 for real λi
2 As an sinusoid with exponentially changing amplitude eσt sin(ωit + φ0)x0 forcomplex-conjugate λi = σi + jωi .
3 As polynomially-scaled versions of the above tpeλi t for repeated λi .
The amplitude of the i mode goes to zero as t increases if and only ifRe(λi ) < 0.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 8 / 26
Example: Simple Pendulum
Recall the model for a simple pendulum, assuming no damping (and noinput/output for now):
x =
[0 1−g/l 0
]x
Eigenvalues are solutions of the characteristic equation:
det(λI − A) = det
[λ −1g/l λ
]= λ2 + g/l = 0,
i.e.,
λ1,2 = ±j√
g
l.
Eigenvectors are obtained as solutions of (λI − A)v = 0, e.g.,
v1,2 =
[1
±j√
gl
]
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 9 / 26
Pendulum mode shape
Assume x(0) = (1, 0), i.e., x(0) = (1/2, 1/2).
Re
Im
after time t:multiply by eλi t
Re
Im
Combining the two modes, we get
x1(t) = cosωt,
x2(t) = −ω sinωt.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 10 / 26
Cartesian vs. polar form of complex numbers
Complex numbers can be represented in basically two ways:
Cartesian form: z = a + jb
Polar form: z = |z |e j∠z
In the above formulas, |z | =√a2 + b2, and ∠z = arctan(b/a)
(arctan understood as the four-quadrant version).
The Cartesian form makes addition easy:
(a1 + jb1) + (a2 + jb2) = a1 + a2 + j(b1 + b2)
The polar form makes multiplication easy:
m1ejφ1 ·m2e
jφ2 = (m1 + m2)e j(φ1+φ2)
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 11 / 26
General evolution for complex-conjugate modes
Re
Im
after time t:multiply by eλi t
Re
Im
Combining the two modes, we get
x1(t) = c1eσt sin(ωt + φ1,
x2(t) = c2eσt sin(ωt + φ2).
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 12 / 26
Towards feedback control
So far we have looked at how a given system, represented as a state-spacemodel or as a transfer function, behaves given a certain input (and/or initialcondition).
Typically the system behavior may not be satisfactory (e.g., because it isunstable, or too slow, or too fast, or it oscillates too much, etc.), and onemay want to change it. This can only be done by feedback control!
However, we need to understand to what extent we can change the systembehavior. More precisely, for control design, one must also understand
how the control input can affect the state of the system;
how the state of the system affects the output.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 13 / 26
Controllability and Observability
An LTI system of the form x = Ax + Bu is said to be controllable if for anygiven initial state x(0) = xc there exists a control signal that takes the stateto the origin x(t) = 0 for some finite time t.
An LTI system of the form x = Ax + Bu, y = Cx + Du is said to beobservable if any given initial condition x(0) = xo can be reconstructedbased on the knowledge of the input and output signal only, over a finite timeinterval [0, t].
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 14 / 26
Intuition from the Modal Form
Recall that if the matrix A has a complete set of independent (right)eigenvectors {v1, . . . , vn}, with eigenvalues {λ1, . . . , λn} it can bediagonalized by the matrix T =
[v1 v2 . . . vn
].
The transformed state in the diagonalized system is such that x = Tx .
The transformed model is (A, B, C , D) = (T−1AT ,T−1B,CT ,D).
Component-wise, the dynamics of each modal coordinate xi are given by
d
dtxi (t) = λi xi (t) + biu(t), i = 1, . . . , n.
The output is given by
y = c1x1(t) + c2x2(t) + . . .+ cnxn(t) + Du(t).
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 15 / 26
Controllability/observability for diagonal systems
From the previous slide, we can deduce
The i-th coordinate can be controlled if and only if bi 6= 0.
The i-th coordinate appears in the output if and only if ci 6= 0.
Hence:
An LTI system in diagonal form is controllable if bi 6= 0, i = 1, . . . , n.
An LTI system in diagonal form is observable if ci 6= 0, i = 1, . . . , n.
An LTI system is stabilizable if all unstable modes are controllable.
An LTI system is detectable if all unstable modes are observable.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 16 / 26
An example
A =
1.618j
−1.618j0.618j
−0.618j
, B =
0.4472j−0.4472j
0.44720.4472
C =
[0.276j −0.276j 0.724 0.724
], D = [0].
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 17 / 26
An example
A =
j−j
j−j
, B =
0.707j−0.707j
00
C =
[0 0 0.707 0.707
], D = [0].
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 18 / 26
More general conditions
Consider the derivatives of the output:
y(0) = Cx(0), y ′(0) = CAx(0), y ′′(0) = CA2x(0), . . .
One can reconstruct x(0), i.e., the system is observable, as long as theobservability matrix
CCACA2
. . .CAn−1
has full rank.Note that it is sufficient to compute the observability matrix only up to thepower n − 1 of A (Cayley-Hamilton theorem).A similar condition can be obtained for controllability, with a somewhat morecomplicated proof: a system is controllable if the controllability matrix[
B AB A2B . . . An−1B]
has full rank.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 19 / 26
Pole placement — first order systems
Consider a first-order control system with dynamics x = ax + bu, and assumethat we are not happy about its behavior (e.g., it is unstable since a > 0, ormaybe stable but “slow” because |a| is small).
Can we change the behavior by choosing u in a clever way?
Feedback control: choose u = −kx ; then the dynamics would become
x = (a− bk)x
As long as b 6= 0 (i.e., if the system is controllable), by choosingk = (a− a∗)/b, we can place the ”closed-loop” eigenvalue at a desired valuea∗, or anywhere we want on the real axis!
This is the simplest example of a general technique called “pole placement”.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 20 / 26
Example
Assume x = 0.5x + u, i.e., the system is unstable with time constant 2.
We would like the system to be stable, with time constant 1/2.
Choose u = −(0.5 + 2)x = −2.5x ; the closed loop will be x = −2x asdesired.
t
open-loop
closed-loop
u
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 21 / 26
Effect on feedback for closed-loop dynamics
If we have an open-loop LTI system
x(t) = Ax(t) + Bu(t),
y(t) = Cx(t),
by choosing a linear feedback u = −ky = −kCx , we can transform it intoanother, closed-lopp LTI system:
x(t) = (A− BkC )x(t),
y(t) = Cx(t),
In general “negative feedback” (i.e., u = −ky ) has “stabilizing” effects, andthe bigger k , the faster the closed-loop system is, and the smaller the errorsare.
However this is not generally the case.
In the rest of the course, we will look at ways to analyze the behavior of theclosed-loop system, and choosing the feedback control law, withoutnecessarily lots of computation — but rather using primarily “graphical”methods.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 22 / 26
Examples
x(t) = 0.5x(t) + u(t),
y(t) = x(t),
-5 -4 -3 -2 -1 0 1-0.3
-0.2
-0.1
0
0.1
0.2
0.3Root Locus
Real Axis (seconds-1)
Imag
inar
y Ax
is (s
econ
ds-1
)
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 23 / 26
Examples
x(t) =
[1 1−1 1
]x(t) +
[0
1.5
]u(t),
y(t) =[1.34 0.67
]x(t),
-7 -6 -5 -4 -3 -2 -1 0 1 2-2.5
-2
-1.5
-1
-0.5
0
0.5
1
1.5
2
2.5Root Locus
Real Axis (seconds-1)
Imag
inar
y Ax
is (s
econ
ds-1
)
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 24 / 26
Examples
x(t) =
−1 1 0−1 −1 10 0 −2
x(t) +
005
u(t),
y(t) =[1 0 0
]x(t),
-6 -5 -4 -3 -2 -1 0 1-4
-3
-2
-1
0
1
2
3
4Root Locus
Real Axis (seconds-1)
Imag
inar
y Ax
is (s
econ
ds-1
)
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 25 / 26
Today’s learning objectives
After today’s lecture, you should be able to:
Diagonalize a matrix using similarity transformations.
Describe the behavior of an LTI system in modal coordinates.
Understand concepts like controllability and observability.
Understand the basic effects of feedback control on the closed-loop dynamics.
E. Frazzoli (ETH) Lecture 4: Control Systems I 13/10/2017 26 / 26