Documente Academic
Documente Profesional
Documente Cultură
Automatic Control 2
University of Trento
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 1 / 37
Lecture: Frequency domain analysis Frequency response
Frequency response
Definition
The frequency response of a linear dynamical system with transfer function
G(s) is the complex function G(jω) of the real angular frequency ω ≥ 0
Theorem
If G(s) is asymptotically stable (poles with negative real part), for
u(t) = Ū sin(ωt) in steady-state conditions limt→∞ y(t) − yss (t) = 0, where
The frequency response G(jω) of a system allows us to analyze the response of the
system to sinusoidal excitations at different frequencies ω
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 2 / 37
Lecture: Frequency domain analysis Frequency response
We can repeat the proof for Ū 6= 1 and get the general result.
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 4 / 37
Lecture: Frequency domain analysis Frequency response
Example
u(t) = 5 sin 10t 10 y(t)
G(s) =
(1 + 0.1s)2
where
10 10
G(jω) = =
(1 + 0.1jω)2 1 + 0.2jω − 0.01ω2
For ω = 10 rad/s,
10 5
G(10j) = = = −5j
1 + 2j − 1 j
Finally, we get
π π
yss (t) = 5 · 5 sin(10t − ) = 25 sin(10t − )
2 2
Wednesday, April 28, 2010
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 5 / 37
Lecture: Frequency domain analysis Frequency response
Example (cont’d)
30
20
10
0
yss(t)
−10
y(t)
−20 u(t)
−30
0 0.5 1 1.5 2
time (s)
π
u(t) = 5 sin(10t) → yss (t) = 25 sin(10t − )
2
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 6 / 37
Lecture: Frequency domain analysis Frequency response
Theorem
If G(z) is asymptotically stable (poles inside the unit circle), for
u(k) = Ū sin(kθ ) in steady-state conditions limk→∞ y(k) − yss (k) = 0,
where
yss (k) = Ū|G(ejθ )| sin(kθ + ∠G(ejθ ))
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 7 / 37
Lecture: Frequency domain analysis Bode plot
Bode plot
The Bode plot is a graph of the module |G(jω)| and phase ∠G(jω) of a
transfer function G(s), evaluated in s = jω
The Bode plot shows the system’s frequency response as a function of ω, for
all ω > 0
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 8 / 37
Lecture: Frequency domain analysis Bode plot
Bode plot
−10
Magnitude (dB)
−30
1
−40 G(s) =
−50 (1 + 0.1s)(1 + 0.002s + 0.0001s2 )
−60
−70
−80
0
−45
−90
Phase (deg)
−135
Example: frequency response of a
−180
»evalfr(G,w)
Example: the DC-gain G(0) = 1, |G(j0)|db = 20 log10 1 = 0
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 9 / 37
Lecture: Frequency domain analysis Bode
Bode form
To study the frequency response of the system is useful to rewrite the transfer
function G(s) in Bode form
2ζ0i
1 2
Π
K Πi (1 + sτi ) i 1 + ωni
0 s + ω0 ni
2 s
G(s) = h
s Πj (1 + sTj ) Π 1 + j s + 1 s2
2ζ
j ωnj ω 2
nj
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 10 / 37
Lecture: Frequency domain analysis Bode
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 11 / 37
Lecture: Frequency domain analysis Bode
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 12 / 37
Lecture: Frequency domain analysis Bode
Basic component #1
jG(j!)jdb
40
20 log10jKj
20
20 log10 |K|
1 10 100 1000 !
-20
Basic component #2
jG(j!)jdb
40
20 log10 |ω|
20
-20
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 13 / 37
Lecture: Frequency domain analysis Bode
Basic component #3
jG(j!)jdb
40
-20
Basic component #4
jG(j!)jdb
40
40 db/
decade
20
ω ω2
20 log10 1 + 2jζ
− 6 ³=1
ωn ω2n 0
1 10 100 !n 1000 !
³¸0 ³ crescente
-20
|G(jω)| ≈ 1 for ω ωn
ω2
|G(jω)| ≈ for ω ωn For ζ < p1
the peak of the response is obtained
ω2n 2
at the resonant frequency ωpeak = ωn 1 − 2ζ2
p
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 14 / 37
Lecture: Frequency domain analysis Bode
Example
1000(1 + 10s)
G(s) = 50
s2 (1 + s)2
-60 db/
decade
0
!
-50
0.01 0.1 1 10 100
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 15 / 37
Lecture: Frequency domain analysis Bode
2jζ0i ω
ω2
K Πi (1 + jωτi ) iΠ 1 + ωni
0 − ω0 ni
2
∠G(jω) = ∠
(jω) Πj (1 + jωTj ) Π 1 + ω
h
2jζ j ω2
j ωnj − ω2 nj
we get
∠G(jω) = ∠K − ∠ (jω)h
X X
+ ∠(1 + jωτi ) − ∠(1 + jωTj )
i j
2jζ0i ω 2jζj ω
ω2 ω2
X X
+ ∠ 1+ − 2 − ∠ 1+ − 2
i
ω0ni ω0 ni j
ωnj ωnj
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 16 / 37
Lecture: Frequency domain analysis Bode
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 17 / 37
Lecture: Frequency domain analysis Bode
Basic component #1
¼=2 \G(j!)
0
K>0
§ K>0
0 for 1 10 100 1000 !
∠K =
−π for K<0 -¼=2
-¼ K<0
Basic component #2
¼=2 \G(j!)
hπ 0 h=0
∠ (jω)h = 1 10 100 1000 !
2 -¼=2 h=1
-¼ h=2
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 18 / 37
Lecture: Frequency domain analysis Bode
Basic component #3
∠(1 + jωT) = atan(ωT)
¼=2 \G(j!)
1
∠G(jω) ≈ 0 for ω T ¼=4 T>0
π
∠G(jω) ≈ 2 for ω T1 , T>0 0
1 10 1 100 1000 !
-¼=4 T
T<0
∠(1 − jωT) = −atan(ωT) -¼=2
Basic
component #4
ω ω2
∠ 1 + 2jζ − 2 ¼ \G(j!)
ωn ωn ³¸0
¼=2 ³ crescente
∠G(jω) ≈ 0 for ω ωn
π
For ζ ≥ 0, ∠G(jω) = for ω = ωn ,
2 0
2
1 10 100 !n 1000 !
∠G(jω) ≈ ∠ − ω2 = π for ω ωn
ωn
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 19 / 37
Lecture: Frequency domain analysis Bode
Example (cont’d)
jG(j!)jdb
-¼=2
-3¼=4
1000(1 + 10s)
G(s) = -¼
s2 (1 + s)2 !
-5¼=4
-3¼=
2
0.01 0.1 1 10 100
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 20 / 37
Lecture: Frequency domain analysis Bode
Example
100
-40
Modulo (db)
50
0
-60
-50
-40
-100
-60
10(1 + s) 0
G(s) = 2
s (1 − 10s)(1 + 0.1s) -50
Fase (deg)
-100
-150
-200 -2 -1
10 10 1 10 10 2
Frequenza (rad/s)
10
For ω 0.1: |G(jω)| ≈ ω2 (slope=-40 dB/dec), ∠G(jω) ≈ −π
10
For ω = 0.1: 20 log10 ω 2 = 60 dB
For 0.1 < ω < 1: effect of unstable pole s = 0.1, decrease module by
20 dB/dec, increase phase by π2
For 1 < ω < 10: effect of zero s = −1, +20 dB/dec module, + π2 phase
For ω > 10: effect of pole s = −10, -20 dB/dec module, - π2 phase
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 21 / 37
Lecture: Frequency domain analysis Bode
magnitude phase
stable real pole T>0 −20 dB/dec −π/2
unstable real pole T<0 −20 dB/dec π/2
stable real zero τ>0 +20 dB/dec π/2
unstable real zero τ<0 +20 dB/dec −π/2
pair of stable complex poles ζ>0 −40 dB/dec −π
pair of unstable complex poles ζ<0 −40 dB/dec π
pair of stable complex zeros ζ0 > 0 +40 dB/dec π
pair of unstable complex zeros ζ0 < 0 +40 dB/dec −π
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 22 / 37
Lecture: Frequency domain analysis Bode
p a
ωn = a2 + b2 = |a ± jb|, ζ = −p = − cos ∠(a ± jb)
a2 + b2
Note that ζ > 0 if and only if a < 0
Vice versa, a = −ζωn , and b = ωn 1 − ζ2
p
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 23 / 37
Lecture: Frequency domain analysis Bode
MATLAB
»zpk(G)
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 24 / 37
Lecture: Frequency domain analysis Nyquist plot
The Nyquist plot (or polar plot) is the graph in polar coordinates of G(jω) for
ω ∈ [0, +∞) in the complex plane
The Nyquist plot is one of the classical methods used in stability analysis of
linear systems
The Nyquist plot combines the Bode magnitude & phase plots in a single plot
Harry Nyquist
(1889–1976)
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 25 / 37
Lecture: Frequency domain analysis Nyquist plot
Nyquist plot
To draw a Nyquist plot of a transfer function G(s), we can give some hints:
Nyquist plot of G(s)
0.6 6 dB
gain G(0)
0.4 −10 dB
10 dB
20 dB −20 dB
−0.2
In this case the angle of arrival equals
+ + π +[−]
(n−
z − nz − np + np ) 2 , where nz[p] is the #
−
−0.4
−0.6
−0.8
of zeros [poles] with positive [negative] real
−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1
Real Axis
part
1
G(s) =
(1 + 0.1s)(1 + 0.002s + 0.0001s2 ) G(−jω) = G(jω)
A system without any zero with positive real part is called minimum phase
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 26 / 37
Lecture: Frequency domain analysis Nyquist criterion
Nyquist criterion
Consider a transfer function G(s) = N(s)/D(s) under unit static feedback
u(t) = −(y(t) − r(t))
As y(t) = G(s)(−y(t) + r(t)), the closed-loop transfer function from r(t) to y(t)
is
G(s) N(s)
W(s) = =
1 + G(s) D(s) + N(s)
Proof:
Follows by the Argument principle: “The polar diagram of 1 + G(s) has a
number of clock-wise rotations around the origin equal to the number of
zeros of 1 + G(s) (=roots of N(s) + G(s)) minus the number of poles of
1 + G(s) (=roots of D(s)) of 1 + G(s)”
The poles of W(s) are the zeros of 1 + G(s)
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 28 / 37
Lecture: Frequency domain analysis Nyquist criterion
Example
10 10
Consider the transfer function G(s) = = 2 under static output
(s + 1)2 s + 2s + 1
feedback u(t) = −(y(t) − r(t))
Nyquist Diagram
G(s)
−2
W(s) =
−4
1 + G(s)
−6
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 29 / 37
Lecture: Frequency domain analysis Nyquist criterion
Example
10
Consider the transfer function G(s) = under unit output feedback
s3 + 3s2 + 2s + 1
u(t) = −2(y(t) − r(t))
Nyquist Diagram
25
20
15
10
Imaginary Axis
−15
2G(s)
−20 W(s) =
−25
−10 −5 0 5 10 15 20
1 + 2G(s)
Real Axis
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 30 / 37
Lecture: Frequency domain analysis Nyquist criterion
ω0+
jω0x
ω0−
+∞ +∞ +∞
j0 x 0 x
0 x
Re(ω) Re(ω) Re(ω)
−ω0+
−jω0 x
−ω0−
KG(s)
W(s) =
1 + KG(s)
60
G(s) =
(s2 + 2s + 20)(s + 1)
Phase margin
Assume G(s) is open-loop asymptotically stable
Let ωc be the gain crossover frequency, that is |G(jωc )| = 1
To avoid encircling the point −1 + j0, we want the phase ∠G(jωc ) as far away
as possible from −π
The phase margin is the quantity
Mp = ∠G(jωc ) − (−π)
If Mp > 0, unit negative feedback control is asymptotically stabilizing
For robustness of stability we would like a large positive phase margin
!G(jω)
−1 + j0
!G(jω)
Mp
G(jωc )
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 33 / 37
Lecture: Frequency domain analysis Phase and gain margins
Gain margin
Assume G(s) is open-loop asymptotically stable
Let ωπ be the phase crossover frequency such that ∠G(jωπ ) = −π
To avoid encircling the point −1 + j0, we want the point G(jωπ ) as far as
possible away from −1 + j0.
The gain margin is the inverse of |G(jωπ )|, expressed in dB
1
Mg = 20 log10 = −|G(jωπ )|dB
|G(jωπ )|
For robustness of stability we like to have a large gain margin
!G(jω)
1
Sometimes the gain margin is
Mg
−1 + j0 defined as
1
!G(jω) Mg =
|G(jωπ )|
G(jωπ )
and therefore G(jωπ ) = − M1g + j0
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 34 / 37
Lecture: Frequency domain analysis Phase and gain margins
8
G(s) =
s3 + 4s2 + 4s + 2
The phase and gain margins help assessing the degree of robustness of a
closed-loop system against uncertainties in the magnitude and phase of the
process model
They can be also applied to analyze the stability of dynamic output feedback
laws u(t) = C(s)(y(t) − r(t)), by looking at the Bode plots of the loop function
C(jω)G(jω) (see next lecture on “loop shaping”)
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 35 / 37
Lecture: Frequency domain analysis Phase and gain margins
−1 + j0
!G(jω)
Mp
The system is characterized by a large phase margin, but the polar plot is
very close to the point (−1, 0)
The system is not very robust to model uncertainties changing G(s) from its
nominal value
In conclusion, phase and gain margins give good indications on how the loop
Thursday, April 29, 2010
function should be modified, but the complete Bode and Nyquist plots must
be checked to conclude about closed-loop stability
Prof. Alberto Bemporad (University of Trento) Automatic Control 2 Academic year 2010-2011 36 / 37
Lecture: Frequency domain analysis Phase and gain margins
English-Italian Vocabulary