Documente Academic
Documente Profesional
Documente Cultură
FEEDBACK CONTROL
Control is a very common concept.
DEFINITION:
DEFINITION:
Some applications:
Airplane autopilots that can land a plane in fog.
Space telescopes with pointing accuracy of 106 degrees.
Disk-drive read heads with < 1 micron accuracy.
Robots for various applications.
...
12
FEEDBACK CONTROL
Specic Applications
Ecological
Medical
Home
appliances
Power/energy
Transportation
Manufacturing
Aerospace and Missile guidance and control; automatic piloting; spacecraft conmilitary
(reproduced from: J.R. Rowland, Linear Control Systems: Modeling, Analysis, and Design, John Wiley & Sons, (New York: 1986), p. 6.)
13
FEEDBACK CONTROL
Rube Goldberg walks in his sleep, strolls through a cactus eld in his bare feet, and screams out an idea for self-operating
napkin: As you raise spoon of soup (A) to your mouth it pulls string (B), thereby jerking ladle (C) which throws cracker (D) past
parrot (E). Parrot jumps after cracker and perch (F) tilts, upsetting seeds (G) into pail (H). Extra weight in pail pulls cord (I),
which opens and lights automatic cigar lighter (J), setting off sky-rocket (K) which causes sickle (L) to cut string (M) and allow
pendulum with attached napkin to swing back and forth thereby wiping off your chin. After the meal, substitute a harmonica for
the napkin and youll be able to entertain the guests with a little music.
Thermostat
Gas
Valve
Furnace
Q in
House
Room
Temp.
14
FEEDBACK CONTROL
Reference
Sensor
Compensator
Actuator
Output
Plant
Output
Sensor
Negative Feedback
Compensator
Plant
Output
FEEDBACK CONTROL
15
16
FEEDBACK CONTROL
Block diagram:
Road Grade
Desired
Speed
Control
Variable
Compensator
Throttle
Actuator
Engine
Plant
Actual
Speed
Auto Body
Speedometer
Measured
Speed
Output
Sensor
Sensor Noise
3. Model of system:
1. Operate system 55 MPH. Assume linear response near 55 MPH.
2. Measure: 1% change in throttle 10 MPH change in speed.
3. Measure: 1% change in grade 5 MPH change in speed.
4. Measure: Speedometer accurate to a fraction of 1 MPH, so is
assumed exact.
5. Functional block diagram:
r (t)reference speed, MPH.
w(t)
u(t)throttle posn., %.
y(t)actual speed, MPH.
w(t)road grade, %.
0.5
r (t)
Compen- u(t)
sator
10
y(t)
17
FEEDBACK CONTROL
4. Design compensator/controller
First attempt = open loop controller.
w(t)
0.5
r (t)
Compensator
u(t)
1/10
yol(t)
10
r(t)
0.5w(t)
10
= r(t) 5w(t).
5. Evaluate design.
r(t) = 55, w(t) = 0% yol(t) = 55.
No Error. . . Good.
Suppose you load the trunk with all your course materials and the
car becomes more sluggish.
18
FEEDBACK CONTROL
Compensator
r (t)
100
u(t)
ycl(t)
10
...
0.2% Error!
19
FEEDBACK CONTROL
0.5
Compensator
r (t)
u(t)
10
ycl(t)
10
5
w(t)
r(t)
1 + 10
1 + 10
1
set to 1: =1 10
5
w(t).
10
Best results yet! (Try for yourself with = 100.)
= r(t)
Supply
Float
110
FEEDBACK CONTROL
Damper
Riser
Eggs
Water
Float
Flue
Gasses
Mercury
Metal plate
Fire Alcohol
Butterfly
valve
Steam
Ball
Rotation
FEEDBACK CONTROL
111
1868: Maxwell found stability criteria for second and third order
(simple) systems.
1877: Routh found stability criteria for more complex (general) linear
systems.
1893: Lyapunov: stability of nonlinear systems.
1932: Nyquists graphical stability criteria
(1945: Bodes simpler graphical method)
1936: PID Control.
1948: Evans root locus.
1960s: State variable (modern) control design.
1980s: Post Modern H Robust control. Adaptive control...?
FEEDBACK CONTROL
112
1624
Chronological History
of Feedback Control
Drebble, Incubator
1728
Watt, Flyball governor
1868
Maxwell, Flyball stability analysis
1877
Routh, Stability
1890
Liapunov, Nonlinear stability
1910
Sperry, Gyroscope and autopilot
1927
Black, Feedback electronic amplier: Bush, Differential analyzer
1932
Nyquist, Nyquist stability criterion
1938
Bode, Frequency response methods
1942
Wiener, Optimal lter design: Ziegler-Nichols PID tuning
1947
Hurewicz, Sampled data systems; Nichols, Nichols chart
1948
Evans, Root locus
1950
Kochenberger, Nonlinear analysis
1956
Pontryagin, Maximum principle
1957
Bellman, Dynamic programming
1960
Draper, Inertial navigation; Kalman, Optimal estimation
1969
Hoff, Microprocessor
(reproduced from: G.F. Franklin, J.D. Powell, A. Emami-Naeini, Feedback Control of Dynamic Systems, 3rd edition,
Addison Wesley, (Reading, Mass: 1994), yleaf.)
21
22
LINEAR :
a.k.a. superposition.
TIME INVARIANT :
KEY POINT:
A Simple Model
Consider a resistor:
i(t)
v(t)
23
Apply 1 Volt;
1 Amp of current is predicted to ow.
Power dissipated = V 2/R = 1 Watt.
Now apply 10 Volts.
10 Amps of current is predicted to ow.
Power dissipated = V 2/R = 100 Watts!
Model will no longer be accurate.
True behavior depends on input signal levelnonlinear.
Model is accurate in certain range of input-signal values.
Dynamics of Mechanical Systems I (translational)
Newtons Law:
F = ma. Vector sum of forces = mass of object
times inertial acceleration.
Free-body diagrams are a tool to apply this law.
EXAMPLE :
Write the equations of motion for the speed and forward motion of a
car assuming that the engine imparts a forward force of u(t).
1. Assume rotational inertia of wheels is negligible.
2. Assume that friction is proportional to cars speed (viscous friction).
F = ma
.
or,
x(t)
..
.
b x(t)
u(t)
24
EXAMPLE :
Car suspension.
Quarter-car model
y(t)
b
m1
x(t)
kw
r (t)
Free-body diagram:
Road Surface
Inertial Reference
.
.
b( y (t) x(t))
ks (y(t) x(t))
m1
kw (x(t) r (t))
m2
x(t)
ks (y(t) x(t))
y(t)
.
.
b( y (t) x(t))
25
The force from the spring is proportional to its stretch. The force from the
shock absorber is proportional to the rate-of-change of its stretch.
F = ma
.
..
..
x(t) +
.
kw
kw
b .
ks
( x(t) y (t)) +
(x(t) y(t)) +
x(t) =
r(t)
m1
m1
m1
m1
..
k
b .
.
y (t) +
y (t) x(t)) + s (y(t) x(t)) = 0
(
m2
m2
1. Mass
x1 (t)
2. Spring
x2 (t)
x1 (t)
3. Damper
x2 (t)
.
.
f (t) = b(x 1 (t) x 2 (t))
M = J
(or I )
Satellite control.
Satellites require attitude control so that sensors, antennas, etc., are
properly pointed. Lets consider one axis of rotation.
26
(t)
Fc (t)d = J (t)
d
..
Fc (t)d
(t) =
J
Note: Output of system (t) integrates
Gas jet
Fc (t)
torques twicedouble-integrator plant.
EXAMPLE : Torsional pendulum.
A torsional pendulum is used, for example, in clocks enclosed in glass
domes. A similar device is the read-write head on a hard-disk drive.
k: Springiness of suspension wire.
k
J
b: Viscous friction.
..
M = J (t)
..
J
J
J
Important components for mechanical rotational systems:
1. Inertia
J
1 (t)
2. Spring
2 (t)
1 (t)
3. Damper
2 (t)
.
.
(t) = b( 1 (t) 2 (t))
27
EXAMPLE :
(t), (t)
mg
Linear.
F = ma,
M = J .
28
Node analysis is a tool to apply these laws. (i.e., select one node as
reference (e.g., ground) and assume all other voltages are unknown.
Write equations for the unknowns using KCL. KVL must be used for
voltage sources.)
EXAMPLE :
Bridged-Tee circuit.
C2
R1
vi (t)
R2
C1
Select reference = .
KVL at : v(t) = vi (t).
v(t) v(t) v(t) v(t)
.
KCL at :
C 1v (t) = 0.
R1
R2
v(t) v(t)
.
.
KCL at :
+ C 2(v (t) v (t)) = 0.
R2
.
R1
.
R2
.
..
..
29
..
..
2
2
R1 R2 C 1C 2 v (t) + R2 C 2 + R1 R2C 2 + R1 R2C 1 v (t) + (R2 ) v (t)
..
2
2
= (R1 R2 C 1C 2)v (t) + (R2 C 2 + R1 R2C 2)v (t) + (R2)v(t)
v(t)
i(t)
v(t) = Ri(t)
2. Capacitor
v(t)
i(t)
i(t) = C
d v(t)
dt
3. Inductor
v(t)
i(t)
v(t) = L
d i(t)
dt
4. Voltage source
v(t)
vs
v(t) = vs
5. Current source
is
i(t)
i(t) = i s
6. Operational
Amplier
i (t)
vd (t)
i + (t)
vd (t) = 0
i (t) = i +(t) = 0
vo (t)
210
EXAMPLE :
Op-amp circuit.
R2
vi (t)
R1
vo (t) = R2i(t) vc (t).
i(t) =
R1
vi (t)
vo (t)
dvo(t)
di(t) dvc (t)
= R2
dt
dt
dt
R2 dvi (t) i(t)
=
R1 dt
C
R2 dvi (t)
1
=
vi (t)
R1 dt
R1 C
.
DC Generator.
e f (t)
Ra
Lf
Field
circuit
L a i a (t)
eg (t)
Rotor
circuit
ea (t)
Zl
Load
circuit
211
e f (t) = R f i f (t) + L f
eg (t) = K
di f (t)
dt
d(t)
dt
= K g i f (t).
eg (t) = Ra i a (t) + L a
di a (t)
+ ea (t).
dt
ea (t) = Z l i a (t).
e f (t)
Field
circuit
eg (t)
Kg
Rotor
circuit
i a (t)
Zl
ea (t)
La
eb (t)
Armature
b
(t), (t)
Load
212
= K i a (t) b (t)
Assume (FOR NOW ONLY) electrical response is faster than
mechanical. L a 0.
..
.
ea (t) eb (t)
J (t) = K
b (t)
Ra
..
J (t) + b +
K Ke .
K
ea (t)
(t) =
Ra
Ra
N1
e1 i 2
=
=
N2
e2 i 1
r1
2 1
=
=
r2
1 2
r1
r2
213
x = f (x, u) ;
x = vector, u = input.
x = A x + Bu;
EXAMPLE :
x1(t)
x2(t)
(t)
.
(t)
214
x 2(t) +
b
k
(t)
x 2(t) + x1(t) =
J
J
J
.
x 1(t)
.
x 2(t)
x 1(t)
x2(t)
0
1
k/J b/J
0
1/J
(t).
x 1(t)
x2(t)
(t)
.
(t)
x 2(t)
0
+ 1 (t).
= g
sin(x 1(t))
l
ml 2
Not linear because we cannot make a constant A matrix.
x 1(t)
.
x 2(t)
x0 = operating state
u 0 = nominal control value.
x = f (x, u).
Taylor-series expansion:
.
.
.
x = x 0 + x f (x 0, u 0 ) + Ax + Bu
215
216
..
Ra
Ra
..
.
Generator
(L a L f )ea (t) + (L f (Ra + Rl ) + L a R f )ea (t)+
R f (Ra + Rl ) = (k g Rl )e f (t)
These are all of the form
..
.
..
.
a2 x(t) + a1 x(t) + a0 x(t) = b2u(t) + b1u(t) + b0u(t)
which is called a second-order form.
Therefore, we have seen very specic examples of a very general
class of system. If we learn how to control the general class, we can
apply this knowledge to specic systems.
31
DYNAMIC RESPONSE
We can now model dynamic systems with differential equations.
What do these equations mean?
How does this system respond to certain inputs?
If we add dynamics (a controller) how will the system respond?
How SHOULD the system respond? (specications)
1, t 0;
0, otherwise.
1(t)
t
r (t)
t, t 0;
0, otherwise.
0, otherwise.
t
p(t)
32
DYNAMIC RESPONSE
sin(t)
(t) dt = 1.
unit area.
(t)
Symbol
Sifting property
x( )(t ) d = x(t).
x( )(t ) d ]
(sifting)
x( ) [(t )] d.
(linear)
33
DYNAMIC RESPONSE
x( )h(t, ) d
h(t, ) = h(t )
x( )h(t ) d
(time invariant)
= x(t) h(t).
The output of an LTI system is equal to the convolution of its impulse
response with the input.
This makes life EASY (TRUST me!)
EXAMPLE :
y (t) = Asest
Asest + k Aest = 0
s+k = 0
s = k.
We have solved for snow solve for A.
0+
y (t) dt + k
+
y(t)|0
0
0+
y(t) dt =
0+
0
(t) dt
1
y(0+) y(0) = 1
+
Aek0 0 = 1
A = 1.
34
DYNAMIC RESPONSE
h( )u(t ) d
ek 1( )u(t ) d
ek u(t ) d.
Transfer Function
Response to impulse = impulse response h(t).
Response to general input = messy convolution: h(t) u(t).
h( )u(t ) d
h( )es(t ) d
h( )est es d
35
DYNAMIC RESPONSE
=e
st
h( )es d
= est H (s).
An input of the form est decouples the convolution into two
independent parts: a part depending on est and a part depending on
h(t). [Complex exponentials are eigenfunctions of all LTI systems.]
EXAMPLE :
y (t) = s H (s)est ,
u(t)=e j t
u(t)=e j t
u(t)=A cos(t)
Now,
(I never integrated!)
y(t)=H ( j)e j t
y(t)=H ( j)e j t
A
H ( j)e j t + H ( j)e j t
y(t)=
2
H ( j) = Me j
H ( j) = Me j (can be shown for h(t) real)
AM j (t+)
y(t) =
+ e j (t+)
e
2
= AM cos(t + ).
36
DYNAMIC RESPONSE
EXAMPLE :
= H ( j) = tan1
k
A
y(t) =
cos t tan1
.
2 + k2
k
h(t)est dt.
h(t)est dt.
37
DYNAMIC RESPONSE
Unit impulse
(t)
Unit step
1(t)
Unit ramp
t 1(t)
t n 1(t)
Sine
sin(bt)1(t)
Cosine
cos(bt)1(t)
Damped sine
eat sin(bt)1(t)
Damped cosine
eat cos(bt)1(t)
Diverging sine
t sin(bt)1(t)
Diverging cosine
t cos(bt)1(t)
1
1
s
1
s2
n!
s n+1
b
s 2 + b2
s
s 2 + b2
b
(s + a)2 + b2
s+a
(s + a)2 + b2
2bs
(s 2 + b2)2
s 2 b2
(s 2 + b2)2
Superposition:
{ f (t )} = es F(s).
1
s
Time Scaling: { f (at)} =
F
.
Time delay:
|a|
a
(useful if original equations are expressed poorly in time scale. e.g.,
measuring disk-drive seek speed in hours).
Differentiation:
..
38
DYNAMIC RESPONSE
1
= F(s).
s
0
Convolution: Recall that y(t) = h(t) u(t)
Integration:
f ( ) d
t
=0
h( )u(t ) d
t=0
=0
=0
t=
=t
h( )u(t ) d est dt
h( )u(t ) est dt d.
Multiply by es es
Y (s) =
Region of
integration
=0
Let t = t :
Y (s) =
h( )e
=0
h( )e
t=
u(t )es(t ) dt d.
t =0
u(t )est dt
39
DYNAMIC RESPONSE
(zeros)
(poles)
c1
c2
cn
=
+
+ +
if { pi } distinct.
s p1 s p2
s pn
c2(s p1)
cn (s p1 )
so, (s p1 )F(s) = c1 +
+ +
s p2
s pn
let s = p1 :
c1 = (s p1)F(s)|s= p1
=k
ci = (s pi )F(s)|s= pi
n
f (t) =
ci e pi t 1(t)
i =1
EXAMPLE :
1
.
sk
5
5
=
.
s 2 + 3s + 2 (s + 1)(s + 2)
5
c1 = (s + 1)F(s)
=
=5
s=1
s + 2 s=1
5
c2 = (s + 2)F(s)
=
= 5
s=2
s + 1 s=2
F(s) =
s= p1
310
DYNAMIC RESPONSE
c1,2 =
c1,1
cx,ki
EXAMPLE :
d
(s p1 )3 F(s)
ds
s= p1
1 d2
(s p1)3 F(s)
=
2
2 ds
1 di
(s pi )k F(s)
=
i! ds i
Find ILT of
s= p1
.
s= pi
s +3
.
(s + 1)(s + 2)2
5
.
s 2 + 3s + 2
Example 1.
Example 2.
[r,p,k] = residue(Fnum,Fden);
[r,p,k] = residue(Fnum,Fden);
r = -5
5
p = -2
-1
k = []
r = -2
-1
2
p = -2
-2
-1
k = []
When you use residue and get repeated roots, BE SURE to type
help residue to correctly interpret the result.
311
DYNAMIC RESPONSE
..
y(0) = , y (0) = .
s 2Y (s) s + Y (s) = 0
y (t) + y(t) = 0,
Y (s)(s 2 + 1) = s +
s +
Y (s) = 2
s +1
s
= 2
+ 2
.
s +1 s +1
From tables, y(t) = [ cos(t) + sin(t)]1(t).
If initial conditions are zero, things are very simple.
EXAMPLE :
..
.
2
1
From tables, y(t) = e2t + et + e4t 1(t).
3
3
Time Response vs. Pole Locations: 1st-Order Pole(s) (stable)
Pole = root of denominator of H (s) = b(s)/a(s).
Poles qualitatively determine the behavior of the system.
312
DYNAMIC RESPONSE
EXAMPLE :
H (s) =
0.8
0.8
0.6
0.4
y(t) K
h(t)
1
e
0.2
0
0
K (1 et/ )
System response. K = dc gain
0.6
0.4
0.2
t =
Time (sec )
0
0
t =
Time (sec )
(standard form).
= damping ratio.
n = natural frequency or undamped frequency.
n
h(t) =
e t (sin(d t)) 1(t),
1 2
where,
= n ,
d = n 1 2 = damped frequency.
313
DYNAMIC RESPONSE
(s)
= sin ( )
45
(s)
30
17.5
(s)
(s)
(s)
(s)
(s)
= 0.707
Impulse Response
(s)
= 0.5
= 0.3
h(t)
0.5
e t
e t
0.5
1
0
10
15
20
25
30
Time (sec)
Impulse Responses of 2nd-Order Systems
1
=0
=0
0.2
0.5
0.2
1.5
0.4
0.4
y(t)
y(t)
0.6
0
=1
0.8
0.5
0.6
0.8
0.5
1.0
1
0
n t
10
12
0
0
n t
10
12
314
DYNAMIC RESPONSE
(s)
(s)
(s)
Impulse responses vs. pole locations
(s)
Step responses vs. pole locations
tp
1
0.9
0.1
tr
t
ts
315
DYNAMIC RESPONSE
Rise Time
All step responses rise in roughly the same amount of time (see
pg. 3313.) Take = 0.5 to be average.
time from 0.1 to 0.9 is approx n tr = 1.8:
1.8
tr
.
n
We could make this more accurate, but note:
Only valid for 2nd-order systems with no zeros.
Use this as approximate design rule of thumb and iterate design
until spec. is met.
y(t) = 1 e t cos(d t) +
sin(d t) ,
d
d = n 1 2,
= n .
y (t) = e t cos(d t) +
sin(d t) e t (d sin(d t) + cos(d t))
d
=e
2
sin(d t) + d sin(d t) = 0.
d
316
DYNAMIC RESPONSE
100
So,
80
70
M p, %
d t p = ,
tp =
=
.
2
d
n 1
/ 1 2
Mp = e
100.
90
60
50
40
30
20
10
0
0
0.2
0.4
0.6
0.8
Settling Time
Determined mostly by decaying exponential
en ts =
...
= 0.01, 0.02, or 0.05
EXAMPLE :
= 0.01
en ts = 0.01
n ts = 4.6
4.6
4.6
ts =
=
n
ts
0.01 ts = 4.6/
0.02 ts = 3.9/
0.05 ts = 3.0/
Design Synthesis
Specications on tr , ts , M p determine pole locations.
n 1.8/tr .
fn(M p ).
4.6/ts .
1.0
317
DYNAMIC RESPONSE
(s)
(s)
(s)
sin1
(s)
EXAMPLE :
(s)
(s)
(s)
(s)
(s)
1
0
1
2
3
5
EXAMPLE :
(s)
318
DYNAMIC RESPONSE
M p = 0, = 1.
From transfer fn: 2 = 2 n
2
n = 12 = 0.5K a ,
n = 1.
K a = 2.0
Note: ts = 4.6 seconds. We will need a better controller than this for a
pen plotter!
Time Response vs. Pole Locations: Higher Order Systems
We have looked at rst-order and second-order systems without
zeros, and with unity gain.
Non-unity gain
If we multiply by K , the dc gain is K . tr , ts , M p , t p are not affected.
2
H1(s) =
(s + 1)(s + 2)
2
2
=
s+1 s +2
(s/ n ) + 1
.
(s/n )2 + 2 s/n + 1
319
DYNAMIC RESPONSE
Zero at s = .
Poles at
(s) = .
1.5
1.5
=1
2
4
100
0.5
0
0
Mp
Step Response
= 0.3
0.5
0.7
0.5
n t
10
0
0
10
320
DYNAMIC RESPONSE
1.5
H (s)
1.5
Ho (s)
Ho (s)
y(t)
y(t)
0.5
1
H (s)
0.5
0.5
0
Hd (s)
0.5
0
Hd (s)
Time (sec)
10
1.5
0
Time (sec)
10
1
.
(s/ n + 1)[(s/n )2 + 2 s/n + 1]
1.2
8
7
= 1.0
0.7
0.5
6
0.8
100
5
2
=1
0.6
0.4
0.2
0
0
n tr
Step Response
1.4
n t
5
4
3
2
1
0
10
321
DYNAMIC RESPONSE
Dominant
Unstable
region
(s)
MATLAB step and impulse commands can plot higher order system
responses.
Since a model is an approximation of a true system, it may be all right
to reduce the order of the system to a rst or second order system. If
higher order poles and zeros are a factor of 5 or 10 time farther from
the imaginary axis.
Analysis and design much easier.
Numerical accuracy of simulations better for low-order models.
1st- and 2nd-order models provide us with great intuition into how
the system works.
May be just as accurate as high-order model, since high-order
model itself may be inaccurate.
Changing Dynamic Response
Topic of the rest of the course.
322
DYNAMIC RESPONSE
U (s)
H (s)
Y (s)
H2 (s)
Y (s)
Y (s)
H1 (s)
H1 (s)
U (s)
H2 (s)
U1 (s) = R(s) Y2 (s)
R(s)
U1 (s)
Y2 (s) = H2(s)H1(s)U1(s)
H1 (s)
Y (s)
Y2 (s)
H2 (s)
U2 (s)
Alternate representation
R(s)
1 + H2(s)H1(s)
H1(s)
R(s)
1 + H2(s)H1(s)
323
DYNAMIC RESPONSE
H (s)
U (s)
H1(s)
U (s)
Y (s)
H2(s)
Y (s)
H1(s)
Y (s)
U (s)
H2(s)
H1(s)
R(s)
Y (s)
H2(s)
EXAMPLE :
e f (t)
Field
circuit
Ra
Lf
Field
circuit
i f (t)
Kg
L a i a (t)
eg (t)
eg (t)
ea (t)
Rotor
circuit
Rotor
circuit
Zl
Load
circuit
i a (t)
Zl
I f (s)
1
=
.
E f (s)
Rf + L fs
eg (t) = K g i f (t)
E g (s) = K g I f (s)
E g (s)
= Kg.
I f (s)
ea (t)
324
DYNAMIC RESPONSE
d
i a (t) + ea (t)
dt
E g (s) = Ra Ia (s) + L a s Ia (s) + E a (s)
eg (t) = Ra i a (t) + L a
ea (t) = i a (t)Z l
E a (s) = Z l Ia (s)
E a (s)
= Zl .
Ia (s)
= (Ra + L a s + Z l ) Ia (s)
Ia (s)
1
.
=
E g (s)
L a s + Ra + Z l
K g Zl
.
L f s + R f (L a s + Ra + Z l )
H (s)
Y1 (s)
U (s)
Y1 (s)
H (s)
1
H (s)
Y2 (s)
U1 (s)
Y (s)
U1 (s)
U2 (s)
R(s)
H1(s)
Y (s)
R(s)
H2(s)
H (s)
U2 (s)
H (s)
Y2 (s)
H (s)
1
H2 (s)
Unity Feedback
Y (s)
H2(s)
H1(s)
Y (s)
325
DYNAMIC RESPONSE
EXAMPLE :
Simplify:
H6 (s)
H1 (s)
R(s)
H2 (s)
Y (s)
H5 (s)
H3 (s)
H4 (s)
H6 (s)
H1(s)
1 H1 (s)H3(s)
R(s)
H2 (s)
Y (s)
H5 (s)
H4 (s)
H6(s)
H2(s)
H1(s)
1 H1 (s)H3(s)
R(s)
H2 (s)
H5 (s)
Y (s)
H4 (s)
H1 (s)H2(s)
1H1 (s)H3 (s)
H (s)H2 (s)H4 (s)
1+ 1
1H1 (s)H3(s)
R(s)
H (s)
H5(s)+ H6(s)
H1 (s)H2(s)H5(s) + H1 (s)H6(s)
1 H1 (s)H3(s) + H1(s)H2(s)H4(s)
Y (s)
326
DYNAMIC RESPONSE
Masons Rule
If you dont care to simplify a block diagram using block diagram
manipulation, you can use Masons Rule.
Node = Common input to several blocks, or output of summing
junction.
H1 (s)
U (s)
Y (s)
H2(s)
G1
G2
G3
G4
H1
2 Loops: ,
G5
H2
Nontouching.
327
DYNAMIC RESPONSE
Masons Rule
p
1
T =
Mk
M1
+ M2
+ + Mp
k=1
= Value of
forward path.
Key to using rule = organization!
Above example:
Find the loop- and the forward path-gains.
Loops:
L 1 : ; Gain=H1 G 2.
L 2 : ; Gain=H2 G 4.
Forward Paths:
M1 : ; Gain=G 1 G 2 G 3 G 4 G 5
M2 : ; Gain=G 6 G 4 G 5.
= 1 (L 1 + L 2) + L 1 L 2 = 1 + H1 G 2 + H2 G 4 + H1 H2 G 2 G 4.
k
328
DYNAMIC RESPONSE
G6
Path 1 removed. No loops.
1 =10
H1
G1
H2
G2
G3
H1
T =
M1
H2
1
+ M2
G 1 G 2 G 3 G 4 G 5 + G 6 G 4 G 5(1 + H1 G 2)
.
1 + H1 G 2 + H2 G 4 + H1 H2 G 2 G 4
41
Disturbance
r (t)
y(t)
Plant
Ctrlr
CLOSED LOOP :
Disturbance
r (t)
y(t)
Plant
Ctrlr
Sensor
La
eb (t)
Armature
b
(t), (t)
Load
l , load
42
.
J + b = k i a + l let output y = ,
.
di a
disturbance w = l .
ke + L a
+ Ra i a = ea
dt
.
y + by = k i a + w
J
s J Y (s) + bY (s) = k Ia (s) + W (s)
di a
ke Y (s) + s L a Ia (s) + Ra Ia (s) = E a (s)
ke y + L a
+ Ra i a = ea
dt
..
A
B
E a (s) +
W (s).
(1s + 1)(2s + 1)
(1s + 1)(2s + 1)
So,
ea
w
, W (s) = , yss = Aea + Bw.
s
s
This is the response of the open-loop system (without a controller).
E a (s) =
43
B
A
Dist. w(t)
r (t)
Ctrlr
Motor
ea (t)
A
(1s + 1)(2s + 1)
y(t)
Dist. w(t)
r (t)
Ctrlr
ea (t)
A
(1s + 1)(2s + 1)
y(t)
1
Tachometer
Lets make a similar controller for the closed-loop system (with the
possibility of a different value of K .)
ea (t) = K cl (r(t) y(t))
The transfer function for the closed-loop system is:
AK cl
B
Y (s) =
W (s)
(R(s) Y (s)) +
(1s + 1)(2s + 1)
(1s + 1)(2s + 1)
AK cl
B
=
R(s) +
W (s)
(1s + 1)(2s + 1) + AK cl
(1s + 1)(2s + 1) + AK cl
AK cl
yss =
rss ,
assuming w = 0.
1 + AK cl
44
If AK cl
1, yss rss .
yss =
1.
1 + AK cl ).
Sensitivity
The steady-state gain of the open-loop system is: 1.0
How does this change if the motor constant A changes?
A A + A
G ol + G ol = K ol ( A + A)
1
= ( A + A)
A
A
= 1+
.
A
gain error
In relative terms:
G ol
A
A
=
= 1.0
.
G ol
A
A
sensitivity
45
AK cl
.
1 + AK cl
( A + A)K cl
G cl + G cl =
.
1 + ( A + A)K cl
S A cl
A
(1 + AK cl )K cl K cl ( AK cl )
AK cl /(1 + AK cl )
(1 + AK cl )2
1
=
.
1 + AK cl
G
S A cl =
ADVANTAGE OF FEEDBACK :
factor of 1 + AK cl )
Dynamic Tracking
Steady-state response of closed-loop better than open-loop: Better
disturbance rejection, better (lower) sensitivity.
What about transient response?
Open-loop system: Poles at roots of (1s + 1)(2s + 1)
s = 1/1, s = 1/2.
Closed-loop system: Poles at roots of (1s + 1)(2s + 1) + AK cl .
s=
(1 + 2)
(1 + 2)2 412(1 + AK cl )
.
212
46
y(t)
High K cl
1
0.5
0
0
Low K cl
2
10
Time (sec)
PID Control
General control setup:
R(s)
Disturbance
D(s)
G(s)
Y (s)
47
KI
.
s
Proportional Control
u(t) = K (r(t) y(t)) = K e(t)
...
D(s) = K .
May have steady state error, may not be able to completely reject a
constant disturbance.
EXAMPLE:
s2 = 1/2.
With feedback,
s1 , s 2 =
(1 + 2)
(1 + 2)2 412 (1 + AK )
.
212
48
(1 2 )2
K =
412 A
K =0
1
(s)
K =0
1
(s)
1 + 2
212
t
0
49
..
K
12 y (t) + (1 + 2) y (t) + y(t) = A
TI
(r( ) y( )) d + Bw(t).
Differentiate,
AK
.
(r(t) y(t)) + B w(t)
TI
...
..
.
AK
AK
.
y (t) + (1 + 2) y (t) + y (t) +
12
y(t) =
r(t) + B w(t).
TI
TI
...
..
no error.
Steady-state improves
(s)
K =0K =0
1
1
2
1
Possibly unstable.
Can be improved by adding proportional term to integral term.
t
u(t) = K e(t) +
0
K
e( ) d,
TI
D(s) = K 1 +
1
.
TI s
Poles are at
12s 3 + (1 + 2)s 2 + (1 + AK )s +
Two degrees of freedom.
u(t) = K TD e(t),
D(s) = K TD s.
AK
= 0.
TI
(s)
410
TD = Derivative time.
PURE DERIVATIVE CONTROL IMPRACTICAL SINCE DERIVATIVE
MAGNIFIES SENSOR NOISE!
Practical version = Lead control, which we will study later.
Stabilizes system.
.
TD
(s)
D(s) = K 1 +
411
PI
P
1.2
1.4
y(t) (rad/sec)
1.4
y(t) (rad/sec)
1
0.8
PID
0.6
0.4
0.2
0
0
1.2
1
0.8
PI
PID
0.6
0.4
0.2
0.01
0.02
0.03
0.04
0.05
0
0
0.01
Time (sec)
0.02
0.03
Time (sec)
0.04
0.05
412
Y (s)
Aed s
=
,
U (s) s + 1
(rst-order system plus delay)
d
Period
PI
0.25
K =
METHOD II :
Ad
0.9
A
d d
TI =
0.3
K =
PID
1.2
K =
Ad
TI = 2d
TD = 0.5d
Congure system as
r (t)
Ku
Plant
y(t)
413
Period, Pu
PI
K = 0.5K u
K = 0.45K u
1
TI =
Pu
1.2
PID
K = 0.6K u
TI = 0.5Pu
Pu
TD =
8
u(t)
K
TI s
Ka
u min
u max
414
Step Response
Control Effort
1.6
1
1.4
Without antiwindup
1.2
0.6
0.6
u(t)
y(t)
1
0.8
Without antiwindup
0.8
With antiwindup
0.4
0.2
0
0.4
0.2
0.2
0.4
0
0
10
0.6
0
With antiwindup
2
Time (sec)
Time (sec)
10
Steady-State Error
System error is any difference between r(t) and y(t).
Two sources:
1. Imprecise tracking of r(t).
2. Disturbance affecting the system output.
Steady-State Error (w.r.t. Reference Input)
We have already seen examples of CL systems that have some
tracking error (proportional ctrl) or not (integral ctrl) to a step input.
We will formalize this concept here.
Start with very general control structure:
r (t)
T (s)
y(t)
415
= R(s) T (s)R(s)
= [1 T (s)] R(s).
Assume conditions of nal value theorem are satised (i.e., T (s) is
stable)
ess = lim e(t) = lim s[1 T (s)]R(s).
t
s0
tk
We use test inputs of the type: r(t) = 1(t);
k!
t 1(t)
1(t)
R(s) =
t2
1(t)
2
1
s k+1
0,
type > K ;
1 T (s)
ess = lim
= constant, type = K ;
s0
sk
,
type < K .
If system type = 0, constant steady-state error for step input, innite
s.s. error for ramp or parabolic input.
If system type = 1, no steady-state error for step input, constant s.s.
error for ramp input, innite s.s. error for parabolic input.
If system type = 2, no steady-state error for step or ramp inputs,
constant s.s. error for parabolic inputs.
And so forth, for higher-order system types.
Ramp responses of different system types:
416
Type 0 System
Type 1 System
Type 2 System
DANGER : Higher order sounds better but they are harder to stabilize
and design. Transient response may be poor.
G ol (s)
y(t)
1 + G ol (s)
1 + G ol (s)
1
=
.
1 + G ol (s)
So,
E(s) =
1
R(s).
1 + G ol (s)
417
s k+1
ess = lim s E(s)
s0
1
s0 [1 + G ol (s)]s k
= lim
For type 0,
1
1
,
=
s0 1 + G ol (s)
1 + Kp
ess = lim
K p = lim G ol (s).
s0
For type 1,
1
1
1
1
,
= lim
=
s0 1 + G ol (s) s
s0 sG ol (s)
Kv
ess = lim
K v = lim sG ol (s).
s0
For type 2,
1
1
1
1
= lim 2
,
=
s0 1 + G ol (s) s 2
s0 s G ol (s)
Ka
ess = lim
K a = lim s 2 G ol (s).
s0
K v = lim sG ol (s).
K a = lim s 2 G ol (s).
s0
s0
Step Input
1
1 + Kp
Ramp Input
Parabola Input
Type 1
1
Kv
Type 2
1
Ka
418
EXAMPLES:
s+1
; System type?
(s + 2)(s + 3)
1
1
= .
23 6
1
6
Therefore, type= 0, ess to unit step=
= .
1 + 1/6 7
G ol (0) =
(s + 1)(s + 10)(s 5)
(2) Consider G ol (s) = 2
; System type?
(s + 3s)(s 4 + s 2 + 1)
1 10 (5)
=
Type > 0.
01
(s + 1)(s + 10)(s 5)
sG ol (s) =
(s + 3)(s 4 + s 2 + 1)
1 10 (5) 50
sG ol (s)|s=0 =
=
.
31
3
3
Therefore, type= 1, ess to unit ramp=
.
50
s 2 + 2s + 1
(3) Consider G ol (s) = 4
; System type?.
s + 3s 3 + 2s 2
1
G ol (0) = =
Type > 0
0
s 2 + 2s + 1
sG ol (s) = 3
s + 3s 2 + 2s
1
sG ol (s)|s=0 = =
Type > 1
0
s 2 + 2s + 1
2
s G ol (s) = 2
s + 3s + 2
1
s 2 G ol (s) s=0 =
Type = 2.
2
G ol (0) =
419
KEY POINT:
EXAMPLE:
Ctrlr
A
(1s + 1)(2s + 1)
y(t)
Controller: D(s) = K .
D(s)G(s) =
KA
,
(1s + 1)(2s + 1)
lim D(s)G(s) = K A.
s0
1
. (This
1+KA
Controller: D(s) = K 1 +
1
.
TI s
D(s)G(s) =
KA+
KA
TI s
(1s + 1)(2s + 1)
lim D(s)G(s) =
s0
lim s D(s)G(s) =
s0
KA
.
TI
TI
.
KA
420
Controller: D(s) = K 1 +
1
1
.
+
TI s TI s 2
D(s)G(s) =
KA+
KA
TI s
KA
TI s 2
(1s + 1)(2s + 1)
KA
lim s 2 D(s)G(s) =
.
s0
TI
System is type 2, with s.s. error to parabolic input of
TI
.
KA
We do not wish the output to have ANY disturbance term in it, so the
output error due to the disturbance is equal to the output due to the
disturbance.
ess = yss = lim sTw (s)W (s).
s0
Tw (s)
.
s0
s
Tw (s)
Type 2 system (w.r.t. disturbance) has constant lim 2 .
s0 s
Type 1 system (w.r.t. disturbance) has constant lim
51
STABILITY ANALYSIS
Many classications of stability in system analysis.
For LTI systems, all are basically the same BIBO.
Stable
Neutral
Unstable
h( )u(t ) d
h( )u(t ) d
52
STABILITY ANALYSIS
K1
So if a system is BIBO stable,
u(t)
|h( )| |u(t )| d
|h( )| d.
|h( )| d < .
Note: (h(t) = 1(t)).
Stable?
y(t)
m
1 (s
zi )
n
1 (s pi )
m n.
h(t) =
ki e pi t
i =1
|h( )| d <
iff
( pi ) < 0 i.
|h( )| d <
iff
( pi ) < 0;
Same condition.)
Laplace-domain condition for stability: All poles in the transfer
function must be in the open left hand plane. (i.e., none on j axis.)
53
STABILITY ANALYSIS
EXAMPLE :
T (s) =
2
. Is T (s) stable?
s 2 + 3s + 2
2
T (s) =
,
(s + 1)(s + 2)
Roots at s = 1, s = 2. Stable!
10s + 24
EXAMPLE : T (s) =
. Is T (s) stable?
s 3 + 2s 2 11s 12
10(s + 2.4)
T (s) =
,
(s + 1)(s 3)(s + 4)
Roots at s = 1, s = +3, s = 4. Unstable!
s
EXAMPLE: T (s) =
. Is T (s) stable?
s2 + 1
s
T (s) =
,
(s j)(s + j)
Roots at s = j. MARGINALLY stable.
Use input = sin(t).
s
1
s
= 2
s 2 + 1 s 2 + 1 (s + 1)2
y(t) = t sin(t) . . . unbounded.
Y (s) =
STABILITY ANALYSIS
Case 0
Consider the denominator a(s).
2nd order:
a(s) = s 2 + a1s + a0 = (s p1 )(s p2) = s 2 ( p1 + p2)s + p1 p2.
3rd order:
a(s) = s 3 + a2s 2 + a1s + a0
= (s p1 )(s p2)(s p3 )
= s 2 ( p1 + p2)s + p1 p2 s p3
= s 3 ( p1 + p2 + p3 )s 2 + ( p1 p2 + p1 p3 + p2 p3)s p1 p2 p3 .
TREND :
54
STABILITY ANALYSIS
EXAMPLE :
a(s) = s 2 + 0s + 1.
a(s) = s 3 + s 2 + 2s + 8.
1
j 15
Roots at s = 2, s =
. Unstable, but how do we nd out
2
2
without factoring?
55
56
STABILITY ANALYSIS
Case 1
Once we have determined that ai 0 i, we need to run the Routh
test.
Very mechanical, not intuitive. Proof difcult.
a(s) = s n + an1s n1 + + a1s + a0.
Form Routh Array.
s n1
s n2
s n3
.
.
.
s1
s0
TEST :
b2 =
j1
k1
1
an an4
an1 an1 an5
c1 =
an an2 an4
an1 an3 an5
b1
b2
c1
c2
1
an an2
an1 an1 an3
1 an1 an3
b1
b1
b2
c2 =
sn
b1 =
1 an1 an5
b1
b1
b3
EXAMPLE :
a(s) = s 3 + s 2 + 2s + 8.
s3 1 2
s2 1 8
s 1 6
s0 8
b1 =
c1 =
1 1 2
1 1 8
1 1 8
6 6 0
= (8 2) = 6
=
1
(0 + 68) = 8
6
57
STABILITY ANALYSIS
EXAMPLE :
s 2 1 a0
s 1 a1
s 0 a0
b1 =
1 1 a0
a1 a1 0
1
(0 a0 a1) = a0
a1
s3
s2
s
s0
a0
a1
a2
a0
a1
a0
b1 =
1 1 a1
a2 a2 a0
1
(a0 a1 a2)
a2
= a1
c1 =
1 a2 a0
b1 b1 0
a0
a2
1
(a0b1 ) = a0.
b1
a0
.
a2
Case 2
0
Sometimes nd an element in rst column = 0 (!)
0
Replace with as 0.
58
STABILITY ANALYSIS
EXAMPLE :
1
(4 4) = 0
2
1 1 11
2 2 10
1
(10 22) = 6
2
1 2 4
6
1 2 10
0
b1 =
b2 =
s5
s4
s3
new s 3
s2
s1
s0
If
If
1
2
0
12
2 11
4 10
6
6
c1 =
c2 =
10
6
10
d1 =
12
1
e1 =
6
12
12
6
10
10
12
(12 4 )
12
(0 10 ) = 10
(10 +
72
)6
1
(0 60) = 10
6
Case 3
Sometimes an entire row in Routh array = 0.
This means that polynomial factors such that one factor has
conjugate-MIRROR-roots.
(s)
(s)
(s)
(s)
(s)
(s)
59
STABILITY ANALYSIS
s4
s3
s2
s1
new s 1
s0
1
1
1
0
2
2
a(s) = s 4 + s 3 + 3s 2 + 2s + 2.
3
2
2
2
0
Roots of a1(s) at s = j 2.
Marginally stable.
b1 =
1 1 3
1 1 2
= 1
b2 =
1 1 2
1 1 0
= 2
1 1 2
c1 =
1 1 2
= 0
1 1 2
2 2 0
= 2
d1 =
a1(s) = s 2 + 2
da1(s)
= 2s
ds
510
STABILITY ANALYSIS
EXAMPLE :
s4
s3
new s 3
s2
new s 2
s1
s0
a(s) = s 4 + 4 (Hard).
1
0
4
0
16
0
0
0
4
4
da1(s)
= 4s 3.
ds
a1 (s) = s 4 + 4;
b1 =
1 1 0
4 4 0
= 0
b2 =
1 1 4
4 4 0
= 4
c1 =
1 4 0
4
d1 =
16
16
4
0
16
= 4
Design Tool
Consider the system:
r (t)
s+1
s(s 1)(s + 6)
s+1
K s(s1)(s+6)
Y (s)
T (s) =
=
s+1
R(s) 1 + K s(s1)(s+6)
K (s + 1)
s(s 1)(s + 6) + K (s + 1)
y(t)
511
STABILITY ANALYSIS
= s 3 + 5s 2 + (K 6)s + K .
s3
s2
s
s0
1
K 6
5
K
4K 30
5
K
b1 =
1 1 K 6
5 5
K
1
(K 5(K 6))
5
= (4K 30)/5.
c1 =
1 5 K
b1 b1 0
1
(b1 K ) = K
b1
K =25
K =13
K =7.5
Amplitude
2
1.5
1
0.5
0
0.5
0
10
12
Time (sec.)
EXAMPLE :
r (t)
K 1+
1
TI s
1
(s + 1)(s + 2)
y(t)
512
STABILITY ANALYSIS
K TI s+K
Y (s)
s(s+1)(s+2)
T (s) =
=
K TI s+K
R(s) 1 + s(s+1)(s+2)
=
K TI s + K
.
s(s + 1)(s + 2) + K TI s + K
a(s) = s 3 + 3s 2 + (2 + K TI )s + K .
s3
s2
s1
s
1
2 + K TI
3
K
6 + 3K TI K
3
K
b1 =
1 1 2 + K TI
3 3
K
1
(K 3(2 + K TI ))
3
1 3 K
b1 b1 0
1
(b1 K ) = K
b1
c1 =
6
1
for TI < or
1 3TI
3
1.2
Amplitude
K = 3, TI = 0.5
0.8
K = 1, TI = 0.25
0.6
K = 1, TI =
0.4
0.2
0
0
Time (sec.)
10
12
61
ROOT-LOCUS ANALYSIS
Recall step response: we have seen that pole locations in the system
transfer function determine performance characteristics; such as rise
time, overshoot, settling time.
We have also seen that feedback can change pole locations in the
system transfer function and therefore performance is changed.
Suppose that we have one variable parameter in our control system.
Then, we make a parametric plot of pole locations as that parameter
changes. The poles are the roots of the denominator of the transfer
function (a.k.a. the characteristic equation.) This plot is a plot of the
locus of the roots or the ROOT LOCUS PLOT (First suggested by
Evans.)
VERY IMPORTANT NOTE :
roots of an equation
1+ K
b(s)
= 0.
a(s)
G(s)
y(t)
62
ROOT-LOCUS ANALYSIS
K G(s)
.
1 + K G(s)
nm
(b(s) is monic.)
(a(s) is monic.)
EXAMPLE :
G(s) =
63
ROOT-LOCUS ANALYSIS
2 4 4K
s1,2 =
2
= 1 1 K .
Roots are real and negative for 0 < K < 1.
Roots are complex conjugates for K > 1.
(s)
K =1
s1 , K = 0
s2 , K = 0
(s)
2
2
s + 2 n s + n = 0
K =2
s 2 + 2s + K = 0
or we can locate the point on the root locus where
| {poles}| = | {poles}|.
| 1| = | 1 K |
2 = K.
(or, K = 0, not an appropriate solution).
How to Plot a Root Locus
A value s = s1 is on the (180) root locus iff 1 + K G(s1) = 0 for some
real value of K , 0 K .
64
ROOT-LOCUS ANALYSIS
1
.
K
(6.1)
(6.2)
EXAMPLE:
G(s) =
(due to zeros)
(s z 1)
.
(s p1)(s p2 )
(due to poles).
65
ROOT-LOCUS ANALYSIS
(s)
p2
z1
p1
(s)
G(s1) = z1 p1 p2 .
Test point
s1
(s)
p1
z1
Test point
s1
(s)
G(s) = z 1 p1 p2 p2
= 0 0 p2 p2
= 0.
p2
OBSERVATION :
If the test point is to the left of ONE pole or zero, the angle will be
180 or +180 (= 180) so that point is on the locus.
66
ROOT-LOCUS ANALYSIS
EXAMPLE:
G(s) =
1
.
s(s + 4 + 4 j)(s + 4 4 j)
(s)
(s)
EXAMPLE :
G(s) =
s+8
.
s+1
(s)
(s)
67
ROOT-LOCUS ANALYSIS
What happens at K = 0, ?
(s z 1)(s z 2 ) (s z m )
=0
(s p1)(s p2) (s pn )
(s p1)(s p2 ) (s pn ) + K (s z 1)(s z 2) (s z m ) = 0.
1 + K G(s) = 1 + K
68
ROOT-LOCUS ANALYSIS
180 + 360(l 1)
l =
,
nm
l = 1, 2, . . . , n m.
So, if
n m = 1;
= +180.
n m = 2;
= 90.
n m = 3;
= 60, 180.
(etc)
b(s)
1
a(s) (s )nm
b(s)
1
and match the top
and
a(s)
(s )nm
two coefcients of s, the dominant ones.
69
ROOT-LOCUS ANALYSIS
pi .
zi =
pi zi
.
(n m)
GENERAL RULE #2
All poles go from their open-loop locations at K = 0 to:
The zeros of G(s), or
To C .
Those going to C go along asymptotes
180 + 360(l 1)
l =
nm
centered at
=
pi zi
.
nm
pi
610
ROOT-LOCUS ANALYSIS
EXAMPLES :
Additional Techniques
The two general rules given, plus some experience are enough to
sketch root loci. Some additional rules help when there is ambiguity.
(As in examples , )
611
ROOT-LOCUS ANALYSIS
(s)
(s)
(s)
G(s) =
1
.
s(s + 4 + 4 j)(s + 4 4 j)
(s)
p1
2
p2
p1
(s)
l = 0, 1, . . .
612
ROOT-LOCUS ANALYSIS
where
(zeros)
(zeros)
(poles)
Note: The idea of adding 360l is to add enough angle to get the
result within 180. Also, if there is multiplicity, then l counts off the
different angles.
613
ROOT-LOCUS ANALYSIS
614
ROOT-LOCUS ANALYSIS
Some similar loci for which nding saddle points helps clarify
ambiguity ...
(s)
(s)
(s)
(s)
(s)
(s)
(s)
(s)
1
.
K
615
ROOT-LOCUS ANALYSIS
b(s)
= 0,
a(s)
K 0
phase of
b(s)
= 180 .
a(s)
They are
STEP 1: On the s-plane, mark poles (roots of a(s)) by an and zeros (roots of a(s)) with an .
There will be a branch of the locus departing from every pole and a branch arriving at every zero.
STEP 2: Draw the locus on the real axis to the left of an odd number of real poles plus zeros.
STEP 3: Draw the asymptotes, centered at and leaving at angles , where
n m = number of asymptotes.
n = order of a(s)
m = order of b(s)
=
l =
pi z i
a1 + b1
=
nm
nm
180 + (l 1)360
,
nm
l = 1, 2, . . . n m.
For n m > 0, there will be a branch of the locus approaching each asymptote and departing to
innity. For n m < 0, there will be a branch of the locus arriving from innity along each
asymptote.
STEP 4: Compare locus departure angles from the poles and arrival angles at the zeros where
qdep =
i 180 l360
qarr =
i + 180 l360,
where q is the order of the pole or zero and l takes on q integer values so that the angles are
between 180 . i is the angle of the line going from the i th zero to the pole or zero whose
angle of departure or arrival is being computed. Similarly, i is the angle of the line from the i th
pole.
j 0 and
compute the point(s) where the locus crosses the imaginary axis for positive K .
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90.
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
616
ROOT-LOCUS ANALYSIS
STEP 7 Complete the locus, using the facts developed in the previous steps and making
reference to the illustrative loci for guidance. The loci branches start at poles and end at zeros or
innity.
STEP 8 Select the desired point on the locus that meets the specications (s0), then use the
magnitude condition to nd that the value of K associated with that point is
1
K =
.
|b (s0 ) /a (s0 )|
EXAMPLE :
r (t)
(s + 1)(s + 2)
s(s + 4)
y(t)
(s)
(s)
EXAMPLE :
r (t)
s+2
s 10
y(t)
s+3
s+1
Recall that the root-locus rules plot the locus of roots of the equation
b(s)
1+ K
= 0.
a(s)
617
ROOT-LOCUS ANALYSIS
K (s + 2)(s + 1)
(s + 1)(s 10) + K (s + 2)(s + 3)
or
1+K
(s + 2)(s + 3)
= 0.
(s + 1)(s 10)
(s)
(s)
618
ROOT-LOCUS ANALYSIS
Routh Array
s2 K + 1
6K 10
s 1 5K 9
s 0 6K 10
K > 1
9
K > = 1.8
5
10
K >
= 1.66
6
stability criterion
...
s = j
2
.
7
(s)
(s)
6) Breakaway points
(s + 1)(s 10)
K (s) =
(s + 2)(s + 3)
(s 2 9s 10)
=
s 2 + 5s + 6
d
(s + 1)(s 10)(2s + 5) (2s + 9)(s + 2)(s + 3)
=0
K (s) =
ds
(den)2
= 2s 3 + 18s 2 + 20s 5s 2 + 45s + 50
2s 3 10s 2 12s + 9s 2 + 45s + 54 = 0
619
ROOT-LOCUS ANALYSIS
(s)
(s)
EXAMPLE :
r (t)
1
s+a
s+1
s2
y(t)
2) Real axis.
620
ROOT-LOCUS ANALYSIS
3) Asymptotes:
nm = 2
pi zi
0 + 0 + (a) (1) 1 a
=
=
2
2
2
= {0.5, 24.5, 4}
180 + 360(l 1)
l =
= 90.
2
4) Departure angles for two poles at s = 0.
=
2dep =
(zeros)
= 0 0 180 360l
360
dep = 90
l = 90.
2
5) Will always be stable for K > 0.
6) Breakaway points:
s 2(s + a)
K (s) =
s+1
d
(s + 1)(3s 2 + 2as) s 2(s + a)(1)
K (s) =
ds
(s + 1)2
=0
= s 2s 2 + (a + 3)s + 2a = 0
breakaway at 0,
a + 3
(a + 3)2 4(2)(2a)
2(2)
621
ROOT-LOCUS ANALYSIS
a=2
(s)
a=9
(s)
a = 50
(s)
(s)
(s)
(s)
622
ROOT-LOCUS ANALYSIS
6
4
Imag Axis
TAKE ME TO YOUR
LEADER!
0
2
4
6
6
2
1
Real Axis
180, if K positive;
0 ,
if K negative.
b(s)
= 0,
a(s)
K 0
phase of
b(s)
= 0 .
a(s)
They are
STEP 1: On the s-plane, mark poles (roots of a(s)) by an and zeros (roots of a(s)) with an .
There will be a branch of the locus departing from every pole and a branch arriving at every zero.
STEP 2:
Draw the locus on the real axis to the left of an even number of real poles plus zeros.
623
ROOT-LOCUS ANALYSIS
STEP 3:
l =
pi z i
a1 + b1
=
nm
nm
(l 1)360
,
nm
l = 1, 2, . . . n m.
For n m > 0, there will be a branch of the locus approaching each asymptote and departing to
innity. For n m < 0, there will be a branch of the locus arriving from innity along each
asymptote.
STEP 4:
Compare locus departure angles from the poles and arrival angles at the zeros where
qdep =
i l360
qarr =
i l360,
where q is the order of the pole or zero and l takes on q integer values so that the angles are
between 180 . i is the angle of the line going from the i th zero to the pole or zero whose
angle of departure or arrival is being computed. Similarly, i is the angle of the line from the i th
pole.
j 0 and
compute the point(s) where the locus crosses the imaginary axis for positive K .
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90.
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
STEP 7: Complete the locus, using the facts developed in the previous steps and making
reference to the illustrative loci for guidance. The loci branches start at poles and end at zeros or
innity.
STEP 8: Select the desired point on the locus that meets the specications (s0), then use the
magnitude condition to nd that the value of K associated with that point is
1
K =
.
|b (s0 ) /a (s0 )|
624
ROOT-LOCUS ANALYSIS
1:
Approximate ed s by
b0 s + b1
, a polynomial.
a0 s + 1
Pad approximation.
1 (d s/2)
ed s
1 + (d s/2)
1 d s/2 + (d s)2/12
1 + d s/2 + (d s)2/12
1
1 + d s
First-order approximation
Second-order approximation.
Very crude.
2:
71
ROOT-LOCUS DESIGN
We have seen how to draw a root locus for a given plant dynamics.
We include a variable gain K proportional control.
What if desired pole locations are not on this locus?
We need to modify the locus itself by adding extra
dynamicscompensator:
r (t)
D(s)
G(s)
y(t)
We redraw the locus and pick K in order to put the poles where we
want them. HOW?
K D(s)G(s)
T (s) =
let G (s) = D(s)G(s)
1 + K D(s)G(s)
K G (s)
=
We know how to draw this locus!
1 + K G (s)
Adding a compensator effectively adds dynamics to the plant.
What types of (1) compensation should we use, and (2) how do we
gure out where to put the additional dynamics?
Types of Compensator Dynamics
There are 3 classical types of controllers with some important
variations.
72
ROOT-LOCUS DESIGN
1) Proportional Feedback
D(s) = 1.
u(t) = K e(t)
K G(s)
.
1 + K G(s)
Same as what we have already looked at. Controller only consists of
a gain knob. We have to take the locus as given since we have no
extra dynamics to modify it.
T (s) =
2) Integral Feedback
1
D(s) =
TI s
T (s) =
K
u(t) =
TI
e( ) d
K G(s)
TI s
.
K
+ TI G(s)
s
Steady-State Response
We apply a step (ramp, parabola) input. How well does our (closed
loop) system track this?
Ultimately, we would like zero error. e(t) = 0. (Maybe 1%2% in
reality)
Recall: For a unity-feedback control system as drawn above, the
steady-state error to a unit-step input is:
1
ess =
.
1 + K D(0)G(0)
73
ROOT-LOCUS DESIGN
If we make D(s) =
1
, then as s 0, D(s)
TI s
1
ess
= 0.
1+
So by adding the integrator into the compensator, the error has been
1
reduced from
to zero for systems that do not have any free
1 + Kp
integrators.
1
EXAMPLE : G(s) =
,
a > b > 0.
(s + a)(s + b)
1
1
Proportional feedback, D(s) = 1, G(0) = , ess =
.
K
ab
1 + ab
(s)
(s)
1
, ess = 0.
TI s
(s)
(s)
74
ROOT-LOCUS DESIGN
(s)
Combination of proportional
and integral (PI) solves many
of the problems with just (I)
integral.
Phase-Lag Design
The integrator in PI control can cause some practical problems.
Integrator windup due to actuator saturation.
PI control is often approximated by lag control.
(s z 0)
D(s) =
,
| p0| < |z 0|.
(s p0 )
That is, the pole is closer to the origin than the zero.
Because |z 0| > | p0 |, the phase added to the open-loop transfer
function is negative. . . phase lag
Pole often placed very close to zero. e.g., p0 0.01.
Zero is placed near pole. e.g., z 0 0.1.
75
ROOT-LOCUS DESIGN
(s)
(s)
3) Derivative Feedback
D(s) = TD s,
u(t) = K TD e(t).
G(s) =
1
,
(s + a)(s + b)
D(s) = TD s.
(s)
(s)
76
ROOT-LOCUS DESIGN
(s)
No more zero at s = 0.
Therefore better steady-state
response.
(s)
Phase-Lead Control
Derivative magnies sensor noise.
Instead of D-control or PD-control use lead control.
(s z 0)
D(s) =
,
|z 0| < | p0 |.
(s p0 )
That is, the zero is closer to the origin than the pole.
Lag control does not change locus much since p0 z 0 0.
Lag control improves steady-state error.
Lead control DOES change locus. Pole and zero locations chosen so
that locus will pass through some desired point s = s1.
Design may be done analytically: Let
a1 s + a0
D(s) =
.
b1 s + 1
Choose a0 to get specied dc gain. (open-loop gain=K p , K v , . . .)
a1 s + a 0
G(s)
= dc gain.
b1 s + 1
s=0
|a0||G(0)| = dc gain.
a0 =
Desired dc gain
.
|G(0)|
77
ROOT-LOCUS DESIGN
a 1 s1 + a 0
+ G(s1) = 180.
b 1 s1 + 1
(math happens)
a1 =
s1 = |s1|e j
|s1||G(s1)| sin()
sin( + ) + a0|G(s1)| sin() G(s1) = |G(s1)|e j .
b1 =
|s1| sin()
EXAMPLE : G(s) =
. s1 = 2 2e j 135 = 2 + 2 j .
s2
The point s1 is chosen to achieve = 0.707 and = 0.5 sec.
a0: We cannot compute a0 since
a0 = 2.
1
s2
G(s1) = 2
= e j 270 .
s s=22e j 135 8
)
2
(2 2)(1/8) sin(270
2/4
b1 :
16
(2 2) sin(270)
2 2
78
ROOT-LOCUS DESIGN
(5/2)s + 2
.
(3/16)s + 1
Imag Axis
2
1
0
1
2
3
4
6
Real Axis
79
ROOT-LOCUS DESIGN
(s)
(s)
K
s
1
K
V1
V2
(s)
(s)
1
K
K s
V1
V2
(s)
1
K
z 1
(s)
K (s + z 1 )
V1
V2
1/(K z 1)
K
p1
(s)
p1
(s)
K
s + p1
V1
V2
(s)
p1
(s)
K s
s + p1
V1
1/K
K
p1
1
V2
ROOT-LOCUS DESIGN
(s)
(s)
s + z1
K
s + p1
any p1 and z 1
or
710
K
p1
1
z1
1/K
V1
V2
1
(s)
(s)
or
s + z1
s + p1
K1
K =
K2
any p1 and z 1
(s)
(s)
s + z1
s + p1
z 1 > p1
(s)
(s)
(s)
(s)
s + z1
s + p1
z 1 > p1
1
K 1z1
K1
V1
K2
V2
1
K 2 p1
V1
1
1
p1
V2
1
z 1 p1
V1
1
z 1 p1
s + z1
s + p1
p1 > z 1
V2
1
1
p1
V1
K =
p1
z1
1
p1
LAG
LAG
V2
p1 z 1
z1
LEAD
711
ROOT-LOCUS DESIGN
(s)
(s)
s + z1
s + p1
p1 > z 1
K =
p1
z1
(s)
K (s + z 1 )
z 1
(s)
1
K =
z1
V1
p1 z 1
p1
V2
1
1
p1
V1
1
z1
LEAD
V2
1
LEAD
81
FREQUENCY-RESPONSE ANALYSIS
Advantages and disadvantages to root-locus design approach:
ADVANTAGES :
82
FREQUENCY-RESPONSE ANALYSIS
Consider system
Y (s)
= G(s).
U (s)
u(t) = u 0 sin(t)
u 0
U (s) = 2
.
s + 2
With zero initial conditions,
u 0
Y (s) = G(s) 2
.
s + 2
Do a partial-fraction expansion (assume distinct roots)
0
1
2
n
0
Y (s) =
+
+ +
+
+
s a1 s a2
s an s + j s j
y(t) = 1ea1t + 2ea2t + + n ean t +2|0| sin(t + )
If stable, these decay to zero.
yss(t) = 2|0| sin(t + ),
= tan1
(0)
(0)
= u 0 A sin(t + ).
Important LTI-system fact: If the input to an LTI system is a sinusoid,
the steady-state output is a sinusoid of the same frequency but
different amplitude and phase.
Amplitude gain: A; Phase shift: .
A and may be found from 0, which is found using partial-fraction
expansion techniques.
A = |G(s)|s= j = |G( j)|
(G( j))2 + (G( j))2;
=
= G(s)|s= j = G( j)
83
FREQUENCY-RESPONSE ANALYSIS
(G( j))
.
(G( j))
= tan1
FORESHADOWING :
R
U (s)
G(s) =
Y (s)
1
1 + RCs
Frequency response
1
(let RC = 1)
1 + j RC
1
=
1 + j
1
=
tan1().
1 + 2
G( j) =
(den)2
FREQUENCY-RESPONSE ANALYSIS
84
0
0.5
1.0
1.5
2.0
3.0
5.0
10.0
G( j)
1.000 0.0
0.894 26.6
0.707 45.0
0.555 56.3
0.447 63.4
0.316 71.6
0.196 78.7
0.100 84.3
0.000 90.0
85
FREQUENCY-RESPONSE ANALYSIS
0
10
0.8
G( j)
|G( j)|
20
0.6
0.4
30
40
50
60
70
0.2
80
0
0
Frequency, (rads/sec.)
90
0
Frequency, (rads/sec.)
The above plots are in a natural scale, but usually a log-log plot is
made This is called a Bode plot or Bode diagram.
Bode Diagrams
Simplest way to display the frequency response of a
rational-polynomial transfer function is to use a Bode Plot.
Logarithmic versus logarithmic |G( j)|, and logarithmic versus
G( j).
REASON :
log10
ab
cd
86
FREQUENCY-RESPONSE ANALYSIS
|G( j)| =
| j + 1|
| j/10 + 1|
1+
log10
2
1+
.
10
Consider:
log10
For
1+
n
1+
n
1+
n
log10
KEY POINT:
n ,
log10
For
log10(1) = 0.
n ,
log10
.
n
Approximation
Exact
0.1n
10n
87
FREQUENCY-RESPONSE ANALYSIS
Bode-Magnitude Diagrams
dB = 20 log10 |K |.
|K | > 1
0.1
10
1
|K | < 1
20 dB per
decade
0.1
10
= 20 log10 | j| dB.
20 dB
20 dB
20 dB per
decade
0.1
10
20 dB
88
FREQUENCY-RESPONSE ANALYSIS
s
+1 .
n
Draw the gain term (n ) separately from the zero term (s/n + 1).
In general, a LHP or RHP zero has standard Bode form
s
G(s) =
1
n
G( j) = 1 + j
20 log10 |G( j)| = 20 log10
1+
n
89
FREQUENCY-RESPONSE ANALYSIS
For
For
1+
n
20 log10 1 = 0.
20 log10
n ,
20 log10
n ,
1+
n
20 log10
.
n
s
1
n
1+
n
0.1n
10n
20 dB per
decade
20 dB
20 dB
20 dB per
decade
0.1n
1n
10n
s
n
+ 1,
810
FREQUENCY-RESPONSE ANALYSIS
2
which we have seen before as a standard form, the dc-gain is n .
2
Convert forms by factoring out n
s 2 n s +
2
2
n
s
n
2
n
s
n
+1 .
s
n
s
n
+1
n , magnitude 0 dB.
For
40 dB
20 dB
= 0.9
0.7
0.5
0 dB
0.3
0.2
0.1
0.05
0 dB
20 dB
0.1n
20 dB
10n
40 dB
0.1n
10n
811
FREQUENCY-RESPONSE ANALYSIS
...
|G( j)| = 1.
20 log10 1 = 0 dB.
Does not change magnitude response.
EXAMPLE :
20000.5 s
+1
2000(s + 0.5)
G(s) =
= 1050 0.5 s
s
s(s + 10)(s + 50) s 10 + 1 50 + 1
G( j) =
j
j
10
j
0.5
+1
+1
j
50
+1
Components:
DC gain of 20 log10 2 6 dB;
Pole at origin;
One real zero not at origin, and
Two real poles not at origin.
80
60
40
20
0
20
40
60 2
10
10
10
10
10
10
812
FREQUENCY-RESPONSE ANALYSIS
Bode-Phase Diagrams
Bode diagrams consist of the magnitude plots we have seen so far,
BUT, also phase plots. These are just as easy to draw.
BUT, they differ depending on whether the dynamics are RHP or LHP.
p2
( p2 )
p1
( p1 )
813
FREQUENCY-RESPONSE ANALYSIS
K 0;
0 ,
.
180 , K < 0.
j +1
G( j) =
i
90
Zero: G(s) =
= tan1
45 per
decade
.
0.1i
Pole: G(s) =
s
i
G(s) = (1)
= tan1
+1
10i
,
45 per
decade
j +1
i
10i
0.1i
90
814
FREQUENCY-RESPONSE ANALYSIS
j 1
i
Zero: G(s) =
G( j) =
180
45 per
decade
= 180 + tan1
= 180 tan1
90
Pole: G(s) =
1
s
i
G(s) = (1)
0.1i
1
i
= 180 + tan1
10i
0.1i
i
i
10i
90
45 per
decade
180
= 180 + tan1
.
i
Bode-Phase: Complex LHP Zero Pair or Pole Pair
40
140
20
160
0.1n
180
10n
0.1n
= 0.9
0.7
0.5
0.3
0.2
0.1
0.05
n
10n
815
FREQUENCY-RESPONSE ANALYSIS
350
300
50
250
100
200
150
150
200
100
250
300
50
350
0.1n
10n
0.1n
0.1i
10i
G(s) = e ,
G( j) = e j = 1
G( j) = in radians.
= 56.3 in degrees.
Note: Linecurve in log scale.
EXAMPLE :
G( j) =
2 j 0.5 + 1
j j 10 + 1
j 50 + 1
10n
816
FREQUENCY-RESPONSE ANALYSIS
90
90
180
2
10
10
10
EXAMPLE :
G(s) =
10
10
10
s
6 1+ 3
s
s 1 + 12
s
1 + 50
30
20
10
0
10
20 1
10
10
10
10
10
90
45
0
45
90
135
180 1
10
10
10
10
10
817
FREQUENCY-RESPONSE ANALYSIS
Nonminimum-Phase Systems
A system is called a nonminimum-phase if it has pole(s) or zero(s) in
the RHP.
Consider
G 1(s) = 10
s+1
s + 10
zero at 1
pole at 10
minimum
phase
G 2(s) = 10
s1
s + 10
zero at + 1
pole at 10
nonminimum
phase
2 + 1
| j + 1|
|G 1( j)| = 10
= 10
| j + 10|
2 + 100
| j 1|
2 + 1
|G 2( j)| = 10
= 10
| j + 10|
2 + 100
which are the same!
The phase responses are very different:
(G 1( j)), (G 2( j))
|G 1 ( j)|, |G 2 ( j)|
Bode-Magnitude Plot
20
15
10
0
2
10
10
10
10
10
Frequency, (rads/sec.)
10
Bode-Phase Plot
180
150
Non-minimum
Phase, G 2
120
90
60
Minimum
Phase, G 1
30
0
2
10
10
10
10
10
Frequency, (rads/sec.)
10
818
FREQUENCY-RESPONSE ANALYSIS
Note:
819
FREQUENCY-RESPONSE ANALYSIS
Kv
.
s
Kv
. Slope of 20 dB/decade.
Ka
.
s2
Ka
. Slope of 40 dB/decade.
2
Again, use approximation to extend low-frequency asymptote to
= 1. The asymptote evaluated at = 1 is K a .
1
ess =
for parabolic input.
Ka
At low frequency, |G( j)|
Example 1
60
50
Magnitude
Magnitude
10
0
10
20
30
40
2
10
Example 2
40
30
20
10
10
10
Frequency, (rads/sec.)
10
0
2
10
10
10
Frequency, (rads/sec.)
10
820
FREQUENCY-RESPONSE ANALYSIS
EXAMPLE
1:
2:
A Simple Example
Consider, for now, that we know the transfer-function of the system,
and can plot the root-locus.
EXAMPLE :
(s)
r (t)
1
s(s + 1)2
K =2
y(t)
(s)
821
FREQUENCY-RESPONSE ANALYSIS
40
20
0
20
40
60
K = 0.1
K =2
K = 10
80 2
10
10
10
10
90
120
150
180
210
240
270 2
10
10
10
10
KEY POINT:
Nyquist Stability
Poles of closed-loop transfer function in RHPthe system is unstable.
Nyquist found way to count closed-loop poles in RHP.
If count is greater than zero, system is unstable.
Idea:
822
FREQUENCY-RESPONSE ANALYSIS
F (s)
s
s0
mapping
(F )
F(s0)
F (s)
(F )
823
FREQUENCY-RESPONSE ANALYSIS
EXAMPLE:
1
C
EXAMPLE:
(s)
(s)
1
j
(s)
j F(D)
1
j
s
.
s +2
F( A)
F (B)1
(s)
j F(C)
FORESHADOWING :
(zeros)
(poles).
824
FREQUENCY-RESPONSE ANALYSIS
EXAMPLE :
F(c1)
(s)
c1
(s)
In this example, there are no zeros or poles inside the contour. The
phase increases and decreases, but never undergoes a net change
of 360 (does not encircle the origin).
EXAMPLE :
(s)
F(c2)
c2
(s)
One pole inside contour. Resulting map undergoes 360 net phase
change. (Encircles the origin).
EXAMPLE :
(s)
F(c3)
c3
(s)
825
FREQUENCY-RESPONSE ANALYSIS
In this example, there are two poles inside the contour, and the map
encircles the origin twice.
These examples give heuristic evidence of the general rule: Cauchys
theorem
Let F(s) be the ratio of two polynomials in s. Let the closed
curve C in the s-plane be mapped into the complex plane
through the mapping F(s). If the curve C does not pass through
any zeros or poles of F(s) as it is traversed in the CW direction,
the corresponding map in the F(s)-plane encircles the origin
N = Z P times in the CW direction, where
Z = # of zeros of F(s)in C,
P = # of poles of F(s) in C.
Consider the following feedback system:
r (t)
D(s)
G(s)
y(t)
T (s) =
H (s)
D(s)G(s)
.
1 + D(s)G(s)H (s)
(s)
R
(s)
826
FREQUENCY-RESPONSE ANALYSIS
N = # of encirclements of origin.
N = # of encirclements of 1.
Cauchy
(s)
Nyquist
(s)
(s)
Simple? YES!!!
Think of Nyquist path as four parts:
(s)
III
II
(s)
I
IV
FREQUENCY-RESPONSE ANALYSIS
THE TEST:
ENHANCED TEST:
827
828
FREQUENCY-RESPONSE ANALYSIS
D(s) = H (s) = 1.
5
G(s) =
(s + 1)2
5
or, G( j) =
( j + 1)2
EXAMPLE :
(G( j))
(G( j))
0.0000
5.0000
0.0000
0.0019
4.9999
-0.0186
0.0040
4.9998
-0.0404
I: At s = 0, G(s) = 5.
0.0088
4.9988
-0.0879
5
.
(1 + j)2
III: At |s| = , G(s) = 0.
0.0191
4.9945
-0.1908
0.0415
4.9742
-0.4135
0.0902
4.8797
-0.8872
IV: At s =
5
.
(1 j)2
0.1959
4.4590
-1.8172
0.4258
2.9333
-3.0513
0.9253
0.2086
-2.6856
2.0108
-0.5983
-0.7906
4.3697
-0.2241
-0.1082
9.4957
-0.0536
-0.0114
20.6351
-0.0117
-0.0011
44.8420
-0.0025
-0.0001
97.4460
-0.0005
-0.0000
500.0000
-0.0000
-0.0000
II: At s = j, G( j) =
j,
G(s)
(s)
(s)
No encirclements of 1, N = 0.
No open-loop unstable poles P = 0.
Z = N + P = 0. Closed-loop system is stable.
No encirclements of 1/K for any K > 0.
So, system is stable for any K > 0.
Conrm by checking Routh array.
829
FREQUENCY-RESPONSE ANALYSIS
-0.8008
4.4492
-1.8624
2.4428
-3.2725
1.2
-0.5621
-2.0241
2.9
-0.4764
-0.1933
7.1
-0.0737
0.0262
17.7
-0.0046
0.0064
43.7
-0.0002
0.0006
100.0
4.9053
0.5
IV: G( j) = G( j) .
0.2
5.0000
0.1
G(s) =
(G( j))
50
.
(s + 1)2(s + 10)
I: G(0) = 50/10 = 5.
50
II: G( j) =
.
( j + 1)2( j + 10)
III: G() = 0.
EXAMPLE :
(G( j))
-0.0000
0.0000
(s)
Zoom
(s)
EXAMPLE :
1
.
s( s + 1)
830
FREQUENCY-RESPONSE ANALYSIS
(s)
III
II
(s)
Zoom
(s)
IV
The bump at the origin makes a detour around the offending pole.
Bump dened by curve: s = lim e j ,
0
0 90.
From above,
G(s)|s=e j =
1
,
e j (e j + 1)
0 90
Consider magnitude as 0
lim |G(s)|s=e j =
1
1
.
|e j + 1|
Consider phase as 0
lim G(s)|s=e j = (e j + 1).
0
831
FREQUENCY-RESPONSE ANALYSIS
So,
1
+
0
G(s) =
1
s 2(s + 1)
1
.
2e j 2 (1 + e j )
1
1
2.
2|1 + e j |
1
2 +
0 2
0 90.
832
FREQUENCY-RESPONSE ANALYSIS
1
s 3 + s 2 + 0s + 0
num=[0 0 0 1];
den=[1 1 0 0];
nyquist1(num,den);
axis([xmin xmax ymin ymax]);
nyquist1.m is available on http://mocha-java.uccs.edu
under the ECE4510 home page.
It repairs the standard Matlab nyquist.m program, which doesnt
work when poles are on imaginary axis.
nyquist2.m is also available. It draws contours around poles on the
imaginary axis in the oposite way to nyquist1.m. Counting is
different.
Stability Margins
A large fraction of systems to be controlled are stable for small gain
but become unstable if gain is increased beyond a certain point.
833
FREQUENCY-RESPONSE ANALYSIS
value.
Gain margin measures How much can we increase the gain of the
loop transfer function L(s) = D(s)G(s)H (s) and still have a stable
system?
Many Nyquist plots are like this one.
Increasing loop gain magnies the
plot.
GM =1/(distance between origin and
place where Nyquist map crosses
real axis).
1
GM
PM
stability value.
Phase margin measures How much delay can we add to the loop
transfer function and still have a stable system?
PM = Angle to rotate Nyquist plot to achieve neutral stability =
intersection of Nyquist with circle of radius 1.
834
FREQUENCY-RESPONSE ANALYSIS
GM = ( Bode gain at
phase-crossover
frequency) [dB] if Bode
gain measured in dB.
PM = Bode phase at
gain-crossover (180).
Magnitude
20
10
0
10
20
30 2
10
10
10
10
10
Frequency, (rads/sec.)
90
120
Phase
GM = 1/(Bode gain at
phase-crossover
frequency) if Bode gain is
measured in linear units.
150
180
210
240
270
2
10
10
10
10
10
Frequency, (rads/sec.)
835
FREQUENCY-RESPONSE ANALYSIS
PM = tan1
2
1 + 4 4 2 2
PM
.
100
For this system we can also infer M p from PM.
For PM 60,
0.9
M p , overshoot
Damping ratio
0.8
0.6
0.4
0.2
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
10
20
30
40
50
60
Phase margin
70
80
0
0
10
20
30
40
50
Phase margin
60
70
80
836
FREQUENCY-RESPONSE ANALYSIS
dM
slope n of log-mag curve at = o
du
W (u) = weighting function = ln(coth |u|/2)
So, if G( j) 90 if n = 1.
3.5
W (u)
3
2.5
2
1.5
1
0.5
0
6
Normalized freq. u
So, if G( j) 180 if n = 2.
Want crossover |G( j)| = 1 at a slope of about 1 for good
PM. We will soon see how to do this (design!).
KEY POINT:
837
FREQUENCY-RESPONSE ANALYSIS
for
c
c
K D( j)G( j)
1 + K D( j)G( j)
Note: c bw 2c .
1,
|K D( j)G( j)|,
c ;
c .
91
FREQUENCY-RESPONSE DESIGN
The frequency-response methods we have seen so far largely tell us
about stability and stability margins of a closed-loop system based on
open-loop response.
Now, we look at frequency-response based design methods which
primarily aim at improving stability margins.
Also, given the relationship between PM and performance, we have
some idea of transient response as well.
Start thinking of Bode-magnitude and Bode-phase plots as LEGO to
make the frequency response we want.
PD Compensation
Compensator D(s) = K (1 + TD s).
We have seen from root-locus that this has a stabilizing effect.
Magnitude and phase effect:
90
10K
K 0.1
TD
1
TD
10
TD
0.1
TD
1
TD
10
TD
92
FREQUENCY-RESPONSE DESIGN
Ts + 1
,
T s + 1
< 1.
1
.
T
max
K
1
T
max
0.1
T
1
T
1
T
max
1
T
1
1+
at max =
1
.
T
10
T
93
FREQUENCY-RESPONSE DESIGN
1
1
We can show that max occurs mid-way between and
on a log
T
T
scale
1
1
= log
T
log(max) = log
T
=
1
1
log
2
T
+ log
1
T
1
+ log
T
.
90
80
70
60
max
50
40
30
20
10
0 0
10
10
10
1/
94
FREQUENCY-RESPONSE DESIGN
Plant G(s) =
1
s(s + 1)
= lim
s0
1
R(s)
1 + D(s)G(s)
1
1
s + D(s) (s+1)
1
D(0)
Ts + 1
so D(0) = K .
T s + 1
1
1
So,
=
= 0.1 . . . K = 10. This gives max = 3 rads/sec.
D(0)
K
Overshoot spec. M p < 25% gives PM > 45.
D(s) = K
95
FREQUENCY-RESPONSE DESIGN
2s/3 + 1
.
2s/12 + 1
60
1.5
1
40
Imag Axis
Magnitude
50
30
20
10
0
10
20
0.5
0
0.5
1
30
40 2
10
10
10
10
10
1.5
2
1.5
(rad/sec)
0.5
100
Imag Axis
110
Phase
Real Axis
90
120
130
140
150
160
2
0
2
4
170
180
2
10
0.5
10
10
(rad/sec)
10
10
6
7
Real Axis
96
FREQUENCY-RESPONSE DESIGN
Step Response
Ramp Response
3
2.5
Amplitude
Amplitude
1.2
0.8
0.6
0.4
1.5
1
0.5
0.2
0
0
0.5
1.5
2.5
0
0
0.5
Time (sec.)
1.5
2.5
Time (sec.)
K G = |G( jc )|,
G = G( jc ).
1 sin(max)
.
1 + sin(max)
97
FREQUENCY-RESPONSE DESIGN
Compute T
1
T =
.
c
Compensation is
D(s) = K
Ts + 1
T s + 1
+1
+1
1
+1
= K
+1
K
= .
|D( jc )| = K
K =
.
KG
Our design is now complete.
EXAMPLE :
FREQUENCY-RESPONSE DESIGN
1
T =
= 0.3105.
10
KD =
= 32.36.
KG
Matlab code to automate this procedure:
% [K,T,alpha]=bod_lead(np,dp,wc,PM) computes the lead compensation of the plant np/dp to have
% phase margin PM at crossover frequency wc. e.g., [K,T,alpha]=bod_lead([1],[1 1 0],5,60);
function [K,T,alpha]=bod_lead(np,dp,wc,PM)
% rst compute the plant response at wc.
[magc,phc]=bode(np,dp,wc);
% now, compute the needed phase lead at wc and convert to radians for use with "sine"
phir=(-180+PM-phc)*pi/180;
if abs(phir)>pi/2,
disp(A simple phase lead/lag cannot change the phase by more than +/- 90 degrees.);
error(Aborting.);
end;
% the required alpha is
alpha=(1-sin(phir))/(1+sin(phir));
% compute the needed gain change K and the time constant T.
T=1/(wc*sqrt(alpha)); K=sqrt(alpha)/magc;
% compute the new open-loop system by convolving the plant polynomials with the compensator.
nol=conv(np,K*[T 1]); dol=conv(dp,[alpha*T 1]);
% check the solution by plotting the Bode plot for the new open-loop polynomials. Include the frequency w=1
% to get the full resonance response to show the gain margin. Also, plot the uncompensated Bode response.
w=logspace(-2,1)*wc; w(34)=wc; clf;
[mag1,ph1]=bode(np,dp,w); [mag2,ph2]=bode(nol,dol,w);
subplot(211);
semilogx(w/wc,20*log10(mag1),); hold on; semilogx(w/wc,20*log10(mag2)); grid; plot(w/wc,0*w+1,g-);
ylabel(Magnitude (dB)); title(Phase-lead design (uncompensated=dashed; compensated=solid));
subplot(212);
semilogx(w/wc,ph1,); hold on; semilogx(w/wc,ph2); grid; plot(w/wc,0*w-180+PM,g-);
ylabel(Phase); xlabel(Frequency/wc (i.e., "1"=wc));
Matlab results:
98
99
FREQUENCY-RESPONSE DESIGN
Magnitude (dB)
0.1
10
Phase
90
120
150
180
0.01
0.1
1
Frequency/wc (i.e., "1"=wc)
10
PI Compensation
In many problems it is important to keep bandwidth low, and also
reduce steady-state error.
PI compensation used here.
D(s) = K 1 +
1
.
TI s
0.1TI
10K
90
TI
10TI
TI
10TI
910
FREQUENCY-RESPONSE DESIGN
90
1
T
1
T
911
FREQUENCY-RESPONSE DESIGN
Typical process
Assumption is that we need to modify (increase) the dc-gain of the
loop transfer function.
If we apply only a gain, then c typically increases and the phase
margin decreases. NOT GOOD.
Instead, use lag compensation to lower high-frequency gain.
Assume plant has gain K (adjustable), or that we insert a gain K into
the system. Adjust the open-loop gain K to meet phase margin
requirements (plus about 5 slop factor) at crossover without
additional compensation.
Draw Bode diagram of system using the gain K from above. Evaluate
low-frequency gain.
Determine to meet low-frequency gain requirements.
1
Choose one corner frequency = (the zero) to be about one
T
decade below crossover frequency. (This way, the phase added by
the lag compensator will minimally affect PM. The phase added at
crossover will be about 5, hence our previous slop factor).
1
The other corner frequency is at =
.
T
Iterate design to meet spec.
EXAMPLE :
G(s) =
K
1
s + 1 (s + 1)
0.5
1
s
2
+1
912
FREQUENCY-RESPONSE DESIGN
To: Y(1)
Amplitude
1.2
0.8
0.6
0.4
0.2
0
0
10
15
20
25
Time (sec.)
2
10
Imag Axis
Magnitude
20
0
10
20
30
40 2
10
10
10
10
2
3.5
10
2.5
(rad/sec)
1.5
0.5
0.5
0.5
Real Axis
2
Imag Axis
30
Phase
60
90
120
150
180
210
240
270
2
10
10
10
(rad/sec)
10
10
2
3.5
2.5
1.5
0.5
Real Axis
913
FREQUENCY-RESPONSE DESIGN
Magnitude
0
20
40
60
80
100 1
10
10
10
10
Frequency
914
Steady-state
Error Boundary
Magnitude of D(s)G(s)
FREQUENCY-RESPONSE DESIGN
Sensitivity Functions
Consider
w(t)
r (t)
D(s)
G(s)
y(t)
v(t)
915
FREQUENCY-RESPONSE DESIGN
and
G T
1 + D(s)G(s) D(s)G(s) G(s)[1 + D(s)G(s)]
=
2
[1 + D(s)G(s)]
G(s)
1
=
= S(s)
1 + D(s)G(s)
So S(s) is equal to the sensitivity of the transfer function to plant
perturbations.
Recall that T (s) + S(s) = 1
Regardless of D(s)
Regardless of G(s)
We would like T (s) = 1. Then S(s) = 0; Disturbance is cancelled,
design is insensitive to plant perturbation, steady-state error 0.
BUT, for physical plants, G(s) 0 for high frequencies. Furthermore,
the transfer function between V (s) and E(s) is T (s). To reduce high
916
FREQUENCY-RESPONSE DESIGN
Stability Spec.
|T ( j)|
Performance Spec.
|S( j)|
(s)
1 + D( j)G( j)
(s)
917
FREQUENCY-RESPONSE DESIGN
Note: E( j) = S( j)R( j)
|E( j)| = |S( j)R( j)| |S( j)||R( j)|
put a frequency-based error bound
|E( j)| |S( j)||R( j)| eb
Let W1() = R( j)/eb . Then,
|S( j)|
1
.
W1()
EXAMPLE :
Magnitude
200
150
100
50
0
0
500
1000
1500
2000
Frequency (rads/sec.)
918
FREQUENCY-RESPONSE DESIGN
Robustness
Typically there is some uncertainty in the plant transfer function. We
want our design to be robustly stable, and to robustly give good
performance (often called H design).
Uncertainty often expressed as multiplicative
G( j) = G n ( j)[1 + W2( j) ( j)]
W2() is a function of frequency expressing uncertainty, or size of
possible error in transfer function as a function of frequency.
W2() is almost always small at low frequencies.
W2() increases at high frequencies as unmodeled structural
exibility is common.
Typical W2
700
Magnitude
600
500
400
300
200
100
0
0
500
1000
1500
2000
Frequency (rads/sec.)
Design
Assume design for nominal plant G n (s) is stable. Thus,
1 + D( j)G n ( j) = 0 .
919
FREQUENCY-RESPONSE DESIGN
1 + D( j)G( j) = 0
1 + D( j)G n ( j)[1 + W2() ( j)] = 0
1 + D( j)G n ( j)
D( j)G n ( j)
W2() ( j) = 0
+
1 + D( j)G n ( j) 1 + D( j)G n ( j)
=0
by assumption
D( j)G n ( j)
,
1 + D( j)G n ( j)
[1 + T ( j)W2() ( j)] = 0
so, |T ( j)W2() ( j)| < 1
or, |T ( j)|W2() < 1.
recall, T ( j) =
920
FREQUENCY-RESPONSE DESIGN
8
Magnitude
7
6
5
4
3
2
1
0
0
2000
4000
6000
8000
10000
Frequency (rads/sec.)
Log Magnitude
80
60
40
20
0
20
40
60
80
0
2000
4000
6000
8000
10000
Frequency (rads/sec.)
101
STATE-SPACE MODELS
1. What are they?
2. Why use them?
3. How do we formulate them?
4. How are they related to the transfer functions we have used already?
What are They?
Representation of the dynamics of an N th-order system as a
rst-order differential equation in an N -vector called the STATE. N
rst-order equations.
Classic example: 2nd-order E.O.M.
k
f (t)
m
b
y(t)
..
y(t)
.
y (t)
STATE-SPACE MODELS
y (t)
..
y (t)
then, x(t) =
102
y (t)
.
= k
b .
1
y(t) y (t) + f (t)
m
m
m
.
We can write this in the form x(t) = A x(t) + B f (t), where A and B are
constant matrices.
A=
B=
D=
103
STATE-SPACE MODELS
..
1
Y (s)
=
s 3 + a1 s 2 + a2 s + a3
U (s)
.
x(t) = y (t) = 1
0
0 y (t) + 0 u(t)
.
y (t)
0
1
0
y(t)
0
y(t) =
0 0 1 x(t) + 0 u(t).
104
STATE-SPACE MODELS
V (s)
contains all of the
U (s)
Y (s)
. Then, Y (s) = [b1s 2 + b2s + b3]V (s). Or,
U (s)
..
.
y(t) = b1v(t) + b2v(t) + b3v(t).
But, V (s)[s 3 + a1s 2 + a2s + a3] = U (s), or,
...
..
.
v(t) + a1v(t) + a2v(t) + a3v(t) = u(t). The representation for this is
poles of
..
the same as in Case [1]. Let x(t) = v(t) v(t) v(t) . Then
...
..
v(t)
v(t)
1
a1 a2 a3
.
..
.
x(t) = v(t) = 1
0
0 v(t) + 0 u(t)
.
v(t)
0
1
0
v(t)
0
represents the dynamics of v(t). All that remains is to couple in the
zeros of the system.
Y (s) = [b1s 2 + b2s + b3]V (s)
y(t) =
b1 b2 b3 x(t) + 0 u(t)
105
STATE-SPACE MODELS
X n (s)
rn
=
U (s)
s pn
Or,
0
p1
p2
A=
...
0
C=
r1
r2
B= .
.
.
rn
pn
1 1 1 ,
D=
106
STATE-SPACE MODELS
Convenient for keeping track of system poles. . . they are right on the
diagonal!
Good representation to use. . . numerical robustness.
State-Space to Transfer Function
Start with the state equations
.
x(t) = Ax(t) + Bu(t)
y(t) = C x(t) + Du(t)
Laplace transform
or
and
Y (s) =
[C(s I A)1 B + D]
U (s) +
Y (s)
= C(s I A)1 B + D,
U (s)
but
(s I A)1 =
adjoint(s I A)
.
det(s I A)
adjoint(s I A) = [i, j ]T
where i, j = (1)i + j det(Mi, j )
107
STATE-SPACE MODELS
where Mi, j = matrix (s I A) with ith row and jth col. removed.
Slightly easier to compute (for SISO systems)
Y (s)
= C(s I A)1 B + D
U (s)
sI A B
C D
det
=
EXAMPLE :
det[s I A]
a1 a2 a3
A= 1
0
0
0
1
0
1
B=0
0
C=
b1 b2 b3
s + a1 a2 a3 1
1
s
0 0
det
0
1 s 0
b1 b2 b3 0
G(s) =
s + a1 a2 a3
det 1
s 0
0
1 s
b3 + b2 s + b1 s 2
=
det[s I A]
b1 s 2 + b2 s + b3
= 3
s + a1 s 2 + a2 s + a3
Example makes clear that the characteristic equation for the system
(Denominator of transfer function=0) is det[s I A] = 0. (eigenvalues).
108
STATE-SPACE MODELS
109
STATE-SPACE MODELS
= C T T 1(s I A)1 T T 1 B + D
= (C T )[T 1(s I A)T ]1(T 1 B) + D
b1 s 2 + b2 s + b3
H (s) = 3
s + a1 s 2 + a2 s + a3
x(t) = ax(t),
x(0).
x(t) = Ax(t),
x(0).
1010
STATE-SPACE MODELS
I
A2
A
= + 2 + 3 +
s s
s
so,
A2 t 2 A3t 3
[(s I A) ] = I + At +
+
+
2!
3!
1
= e At
matrix exponential
x(t) = e At x(0).
e At : Transition matrix or state-transition matrix.
Matrix exponential
e(A+B)t = e At e Bt
expm.m
A B = B A.
iff
Will say more about this form (e At ) when we discuss the structure of
A.
Computation of e At = 1[(s I A)1] straightforward for 2 2.
EXAMPLE :
x = Ax,
A=
(s I A)1 =
s 1
2 s+3
s+3 1
2 s
0 1
2 3
1
(s + 2)(s + 1)
STATE-SPACE MODELS
1
1
1
2
s+1 s+2 s+1 s+2
= 2
2
2
1
+
+
s+1 s+2 s+1 s+2
e
At
2et e2t
et e2t
2et + 2e2t et + 2e2t
1(t)
x(t) = e x(0) +
at
x(0)
ea(t )bu( ) d
convolution
Where did this come from?
.
3.
0
d at
[e x(t)] = eat bu(t).
dt
d a
[e x( )] d = eat x(t) x(0) =
dt
ea bu( ) d.
n1
m1
x(t) = e x(0) +
At
e A(t ) Bu( ) d
y(t) = Ce x(0) +
At
initial resp.
Ce A(t ) Bu( ) d +
convolution
Du(t)
feedthrough
1011
1012
STATE-SPACE MODELS
1 t
0
e2 t
...
en t
Eigenvalues/eigenvectors.
Eigenvalues and Eigenvectors
is an eigenvalue of A if det(I A) = 0 which is true iff there exists
a nonzero vector v so that
(I A)v = 0 Av = v
v = eigenvector.
Repeat to nd all eigenvectors. Assume that v1, v2, . . . vn are linearly
independent.
Avi = i vi
i = 1, 2, . . . , n
0
1
...
A v1 v 2 . . . v n = v 1 v 2 . . . v n
1013
STATE-SPACE MODELS
AT = T
T 1 AT =
0 1
0 0
det(I A) = 2
0 1
0 0
=0
va
0
= 0.
Dynamic Interpretation
Write T 1 AT =
1
as T A = T 1 with
T 1
T
w1
T
w2
= .
.
.
T
wn
i.e., rows of T 1.
v1 v2 . . . v n
1 t
0
e2 t
...
en t
T
w1
T
w2
.
.
.
wn T
ei t vi wiT
=
i =1
1014
STATE-SPACE MODELS
Recall,
x(t) = Ax(t)
x(t) = e At x(0)
= T e t T 1 x(0)
n
ei t vi (wiT x(0)).
=
i =1
with x(t)
, y(t)
1015
STATE-SPACE MODELS
Impulse Response
2
1.5
Amplitude
1
0.5
0
0.5
1
1.5
2
50
100
150
200
250
300
Time (sec.)
x(t).
1016
STATE-SPACE MODELS
1
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
50
100
150
200
250
0.5
0
0.5
1
0.5
0
0.5
0.5
0
0.5
1
0
1
1
0.5
0
0.5
1017
STATE-SPACE MODELS
1/s
x1
1/s
xn
Can write
x(t) = e At x(0)
= T e t T 1 x(0)
n
ei t vi (wiT x(0)).
=
i =1
Interpretation.
Left eigenvectors decompose initial state x(0) into modal components
wiT x(0).
ei t term propagates ith mode forward t seconds.
Reconstruct state as linear combination of right eigenvectors.
ZerosSISO System
Seen eigenvalues of A are the poles. Zeros of transfer function?
What is a zero?
Put in u(t) = u 0e zi t and you get a zero output at frequency e zi t .
1018
STATE-SPACE MODELS
x(0)
zi I A B . . = 0
u0
y(t) = C x(t) + Du(t) C x(0)e zi t + Du 0e zi t=0
x(0)
C D .. = 0
u0
Put the two together
zi I A B
C
D
x(0)
u0
=0
zi I A B
C
D
=0
Recall
det
s I A B
C D
det(s I A)
EXAMPLES :
1019
STATE-SPACE MODELS
y1out
y1out
1
du/dt
s+1
Constant
y2out
s
Transfer Fcn
(with initial states)
s+1
y2out
1
1
1
0.9
Amplitude
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0.5
1.5
2.5
3.5
4.5
Time (sec.)
y1out
y1out
1
s+1
s+1
s+10
Transfer Fcn
(with initial states)
Transfer Fcn
0
Constant
y2out
y2out
1
0.9
Amplitude
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0.5
1.5
2.5
Time (sec.)
3.5
4.5
1020
STATE-SPACE MODELS
Feedback Control
System dynamics
u(t)
A, B, C
y(t)
1021
STATE-SPACE MODELS
EXAMPLE :
x(t) =
1 1
1 2
1
0
x(t) +
u(t).
det(s I A) = (s 1)(s 2) 1 = s 2 3s + 1.
(Note. The original system is unstable).
Let
u(t) = k1 k2 x(t) = K x(t)
ACL = A B K =
=
1 1
1 2
1
0
1 k1 1 k2
1
2
k1 k2
.
K = [14 57].
k1 3 = 11,
1 2k1 + k2 = 30,
or, k1 = 14
or, k2 = 57.
1022
STATE-SPACE MODELS
x(t) =
1 1
0 2
1
0
x(t) +
u(t)
u(t) = K x(t).
1 k1 1 k2
0
2
ACL = A B K =
1 0
0 2
1 1
0 1
V =
V 1 =
1 1
0 1
1
0
1
0
1 1
0 1
1023
STATE-SPACE MODELS
z (t) =
1 0
0 2
z(t) +
1
0
u(t).
Decoupled
Control input does not inuence second mode directly or indirectly.
System is NOT controllable.
Easier ways to test controllability. Is the (controllability) matrix
Mc =
B AB A2 B . . . An1 B
nn
full rank?
EXAMPLE :
Mc =
1 1
0 1
Rank =?
Mc =
1 1
0 0
Rank =?
EXAMPLE :
a1 a2 a3
1
A= 1
B=0
0
0 ,
0
1
0
0
C=
b1 b2 b3
1024
STATE-SPACE MODELS
Note, K =
k1 k2 k3 , so
k1 k2 k3
BK = 0 0 0 .
0 0 0
Useful because characteristic equation obvious.
a1 k1 a2 k2 a3 k3
ACL = A B K =
1
0
0
0
1
0
CL = det(s I ACL ) = s 3 + (a1 + k1)s 2 + (a2 + k2)s + (a3 + k3) = 0.
Compare CL with desired CL , and compute K .
Summary of Design Procedure
1. Transform arbitrary ( A, B) representation to control-canonical form
( Ac , Bc ): x(t) = T z(t).
2. Solve for gains K c (by inspection).
3. Convert K c to K (for A, B) with K = K c T 1.
Ackermanns formula does this entire process in one step.
1
K = [0 0 . . . 1]Mc d ( A)
where
Mc = [B AB A2 B . . . An1 B]
d ( A) = An + 1 An1 + + n I
where d (s) = s n + 1s n1 + . . . + n = 0
That is, d (s) is the characteristic equation of desired pole locations.
1025
STATE-SPACE MODELS
1 1
0 1
K =
0 1
1 1
0 1
0 1
1 3
3 5
0 1
42 14
14 57
14 57 .
1 1
1 2
+
1 1
1 2
+ 11
1 1
1 2
+ 30
1 0
0 1
41 11
11 52
same as before.
1026
STATE-SPACE MODELS
A=
Let C =
1 1
1 2
1 0 . Then
K =
14 57
Y (s)
= C(s I A + B K )1 B.
R(s)
Y (s)
=
R(s)
=
1
0
B=
s + 13 56
1 s 2
1 0
1
0
s2
.
s 2 + 11s + 30
2
=1!
30
x = Ax+Bu
y = Cx+Du
Step
Sum
K
K=[14 57]
Step Response
0.06
Amplitude
0.04
0.02
0.02
0.04
0.06
0.08
Time (sec.)
yout
yout
C=[1 0]
StateSpace
Kx(t)
y(t)
10
1027
STATE-SPACE MODELS
Modication: Need steady-state values for x(t) and u(t) that are
nonzero. . . Then, regulate around them.
(u(t) u ss ) = K (x(t) x ss )
u ss and x ss related to rss .
u ss = Nu rss
11
x ss = N x rss .
n1
x(t) = 0 = Ax ss + Bu ss
y(t) = rss = C xss + Du ss .
Two equations and two unknowns.
A B
C D
Nx
Nu
0
1
= K x(t) + N r(t)
1028
STATE-SPACE MODELS
In our example
Nx
Nu
1
1
= 2
1
Nu + K N x = 15.
New equations:
.
x(t) = Ax(t) + B(Nu + K N x )r(t) B K x(t)
= ( A B K )x(t) + B Nr(t)
y(t) = C x(t)
Therefore,
Y (s)
=
R(s) new
Y (s)
N
R(s) old
15(s 2)
= 2
s + 11s + 30
15s + 30
= 2
s + 11s + 30
which has zero steady-state error to a unit-step.
1029
STATE-SPACE MODELS
r (t)
u(t)
Nu
A, B, C
y(t)
x
K
Nx
u(t)
r (t)
A, B, C
y(t)
K
Partial statespace model:
A=[1 1; 1 2], B=[1; 0],
C=[1 0; 0 1], D=[0; 0].
15
Gain
Sum
y(t)
yout
yout
C=[1 0]
StateSpace
Kx(t)
K
K=[14 57]
Step Response
1
0.8
0.6
Amplitude
Step
x(t)
x = Ax+Bu
y = Cx+Du
0.4
0.2
0
0.2
0.4
0.6
0.8
Time (sec.)
10
1030
STATE-SPACE MODELS
Pole Placement
Classical question: Where do we place the closed-loop poles?
Dominant second-order behavior, just as before.
Assume dominant behavior given by roots of
2
s 2 + 2 n s + n
s = n jn 1 2
Put other poles so that the time response is much faster than this
dominant behavior.
Place them so that they are sufciently damped.
Real part < 4 n .
Keep frequency same as open loop.
Be very careful about moving poles too far. Takes a lot of control
effort.
Can also choose closed-loop poles to mimic a system that has
performance that you like. Set closed-loop poles equal to this
prototype system.
Scaled to give settling time of 1 sec. or bandwidth of = 1 rad/sec.
0.8
Amplitude
Amplitude
0.6
0.4
0.4
0.2
0.2
0
0
0.6
10
Time (sec.)
12
14
16
0
0
0.5
1.5
Time (sec.)
2.5
1031
STATE-SPACE MODELS
0.8
0.8
Amplitude
Amplitude
0.6
0.4
0.2
0
0
0.6
0.4
0.2
10
12
14
16
0
0
0.5
Time (sec.)
1.5
Time (sec.)
4.6200
2:
4.6598 4.6598 j
3:
4.3503 8.9178 j
5.9126
4:
4.2358 12.6174 j
6.2537 4.139 j
5:
3.9484 13.5531 j
6.0401 5.6006 j
9.3938
6:
2.9905 12.1918 j
5.6018 7.5540 j
7.0889 2.7724 j
4.6200
2:
4.0530 2.3400 j
3:
3.9668 3.7845 j
5.0093
4:
4.0156 5.0723 j
5.5281 1.6553 j
5:
4.1104 6.3142 j
5.9268 3.0813 j
6.4480
6:
4.2169 7.5300 j
6.2613 4.4018 j
7.1205 1.4540 j
2.5
1032
STATE-SPACE MODELS
1.0000
2:
0.7071 0.7071 j
3:
0.5210 1.0680 j
0.7081
4:
0.4240 1.2630 j
0.6260 0.4141 j
5:
0.3764 1.2920 j
0.5758 0.5339 j
0.8955
6:
0.3099 0.9617 j
0.5805 0.7828 j
0.7346 0.2873 j
0.8660 0.5000 j
3:
0.7455 0.7112 j
0.9420
4:
0.6573 0.8302 j
0.9047 0.2711 j
5:
0.5906 0.9072 j
0.8516 0.4427 j
0.9264
6:
PROCEDURE :
1.0000
0.5385 0.9617 j
0.7998 0.5622 j
0.9093 0.1856 j
1033
STATE-SPACE MODELS
EXAMPLE :
1
s(s + 1)(s + 4)
5 4 0
A = 1 0 0 ,
0 1 0
G(s) =
1
B=0
0
ITAE: , Bessel,
Magnitude
20
40
60
80
100
120
140
1
10
10
, (rads/sec.)
10
111
Second-order system:
..
.
2
2
y (t) + 2 n y (t) + n y(t) = n u(t).
112
dy(t)
.
dt
..
d 2 y(t)
y (t) =
.
dt 2
The Laplace Transform is a tool to help analyze dynamic systems.
Y (s) = H (s)U (s), where
y (t) =
Second-order system:
2
2
s 2Y (s) + 2 n sY (s) + n Y (s) = n U (s)
2
n
Y (s) = 2
U (s).
2
s + 2 n s + n
113
% in Matlab
k (t)
k 1(t)
kt 1(t)
kt 2/2 1(t)
...
...
...
...
U (s)
U (s)
U (s)
U (s)
k
impulse
k/s
step
k/s 2
ramp
k/s 3
parabola
k
u(t) = k sin(t) 1(t) . . . U (s) = 2
sinusoid
s + 2
Matlabs impulse, step, and lsim commands can be used to
nd output time histories.
u(t)
u(t)
u(t)
u(t)
=
=
=
=
The Final Value Theorem states that if a system is stable and has a
nal, constant value,
lim x(t) = lim s X (s).
t
s0
H (s)
Y (s)
114
U (s)
Y (s)
H2 (s)
Y (s)
H1 (s)
H1 (s)
U (s)
H2 (s)
R(s)
U1 (s)
H1 (s)
Y (s)
Y (s) =
Y2 (s)
H2 (s)
H1 (s)
R(s)
1 + H2(s)H1(s)
U2 (s)
H (s)
Y1 (s)
U (s)
H (s)
Y1 (s)
1
H (s)
Y2 (s)
U1 (s)
H (s)
Y (s)
U2 (s)
R(s)
H1 (s)
Y (s)
R(s)
H2 (s)
Y (s)
H (s)
U2 (s)
U1 (s)
Y2 (s)
H (s)
1
H2 (s)
Unity Feedback
H2 (s)
H1 (s)
Y (s)
115
0.8
0.8
0.6
0.4
y(t) K
h(t)
1
e
0.2
0
0
K (1 et/ )
System response. K = DC gain
0.6
0.4
0.2
t =
Time (sec )
0
0
t =
Time (sec )
116
(s)
= sin ( )
(s)
=0
=0
0.2
0.5
0.2
1.5
0.4
0.4
y(t)
y(t)
0.6
0
=1
0.8
0.5
0.6
0.8
0.5
1.0
1
0
n t
10
12
0
0
n t
10
12
(s)
(s)
Impulse responses vs. pole locations
(s)
Step responses vs. pole locations
117
tp
1
0.9
0.1
tr
t
ts
100
90
80
M p, %
70
50
40
30
20
tr 1.8/n
ts 4.6/
/ 1 2
Mp e
60
10
0
0
...
...
...
0.2
0.4
0.6
n 1.8/tr
4.6/ts
f n(M p )
0.8
1.0
118
D(s)
G(s)
y(t)
Y (s)
D(s)G(s)
=
= T (s).
R(s) 1 + D(s)G(s)
s0
K v = lim s D(s)G(s).
K a = lim s 2 D(s)G(s).
s0
s0
s0
1 + Kp
1
Type 1
0
Kv
1
Type 2
0
0
Ka
119
Types of Controllers
Proportional ctrlr: u(t) = K e(t).
D(s) = K .
K t
K
Integral ctrlr
u(t) =
e(t) dt.
D(s) =
TI
TI s
.
Derivative ctrlr.
u(t) = K TD e(t)
D(s) = K TD s
1
Combinations:
PI: D(s) = K (1 +
);
TI s
PD: D(s) = K (1 + TD s) ;
1
PID: D(s) = K 1 +
+ TD s .
TI s
Ts + 1
Lead:
D(s) = K
,
< 1 (approx PD)
T s + 1
Ts + 1
Lag:
D(s) = K
,
> 1 (approx PI;
T s + 1
often, K = )
(T1s + 1)(T2s + 1)
Lead/Lag:
D(s) = K
, 1 < 1, 2 > 1.
(1 T1 s + 1)(2 T2 s + 1)
.
.
.
Root Locus
A root locus plot shows (parametrically) the possible locations of the
roots of the equation
b(s)
1+ K
= 0.
a(s)
For a unity-gain feedback system,
D(s)G(s)
T (s) =
.
1 + D(s)G(s)
The poles of the closed-loop system T (s) depend on the open-loop
transfer functions D(s)G(s). Suppose D(s) = K D0(s).
closed-loop poles at 1 + K (D0(s)G(s)) = 0
1110
STEP 2: Draw the locus on the real axis to the left of an odd number of real poles plus zeros.
STEP 3: Draw the asymptotes, centered at and leaving at angles , where
n m = number of asymptotes.
n = order of a(s)
m = order of b(s)
=
l =
pi z i
a1 + b1
=
nm
nm
180 + (l 1)360
,
nm
l = 1, 2, . . . n m
For n m > 0, there will be a branch of the locus approaching each asymptote and departing to
innity. For n m < 0, there will be a branch of the locus arriving from innity along each
asymptote.
STEP 4: Compare locus departure angles from the poles and arrival angles at the zeros where
qdep =
i 180 l360
qarr =
i + 180 + l360
where q is the order of the pole or zero and l takes on q integer values so that the angles are
between 180 . i is the angle of the line going from the i th zero to the pole or zero whose
angle of departure or arrival is being computed. Similarly, i is the angle of the line from the i th
pole.
1111
j 0 and
compute the point(s) where the locus crosses the imaginary axis for positive K .
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90.
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
STEP 7 Complete the locus, using the facts developed in the previous steps and making
reference to the illustrative loci for guidance. The loci branches start at poles and end at zeros or
innity.
STEP 8 Select the desired point on the locus that meets the specications (s0), then use the
magnitude condition to nd that the value of K associated with that point is
1
K =
.
|b (s0 ) /a (s0 )|
(l 1)360
,
nm
l = 1, 2, . . . n m.
i l360
qarr =
i + l360 .
Frequency Response
The frequency response of a system directly tells us the relative
magnitude and phase of a systems output sinusoid if the system
input is a sinusoid. [What about output frequency?]
If the plants transfer function is G (s), the open-loop frequency
response is G ( j).
1112
0.1
10
0.1
10
|K | > 1
0.1
10
|K | < 1
0.1
dB
0.1
10
dB
0.1
10
10
1113
0.1
0.1
10
10
90
Zero on real axis; magnitude & mp-phase & nmp-phase
dB
180
90
90
0.1i
0.1i
10i
1i
10i
1i
0.1i
1i
10i
0.1i
1i
1i
10i
10i
1i
10i
0.1i
90
90
180
40
360
270
20
90
180
90
20
0
0.1n
n
10n
0.1n
Complex poles; magnitude & mp-phase & nmp-phase
10n
90
90
180
20
270
0.1n
10n
10n
10n
40
0.1n
20
0.1n
180
0.1n
10n 360
1114
( j 1 + 1)( j 2 + 1...)
( j a + 1)( j b + 1...)
STEP 2: Determine the value of n for the K o ( j )n term. Plot the low-frequency magnitude
asymptote through the point K o at = 1 rad/sec with the slope of n (or n 20 dB per decade).
STEP 3: Determine the break points where =1/i . Complete the composite magnitude
asymptotes by extending the low frequency asymptote until the rst frequency break point, then
stepping the slope by 1 or2, depending on whether the break point is from a rst or second
order term in the numerator or denominator, and continuing through all break points in
ascending order.
STEP 4: Sketch in the approximate magnitude curve by increasing from the asymptote by a
factor of 1.4 (+3dB) at rst order numerator breaks and decreasing it by a factor of 0.707 (-3dB)
at rst order denominator breaks. At second order break points, sketch in the resonant peak (or
valley) using the relation that |G( j )| = 1/(2 ) at the break.
over two decades by 90 or 180 at each break point in ascending order. For rst order terms
in the numerator, the gradual change of phase is +90 ; in the denominator, the change is 180 .
STEP 7: Locate the asymptotes for each individual phase curve so that their phase change
corresponds to the steps in the phase from the approximate curve indicated by Step 6. Sketch in
each individual phase.
STEP 8 Graphically add each phase curve. Use dividers if an accuracy of about 5 is desired.
If lessor accuracy is acceptable, the composite curve can be done by eye, keeping in mind that
the curve will start at the lowest frequency asymptote and end on the highest frequency
asymptote, and will approach the intermediate asymptotes to an extent that is determined by the
proximity of the break points to each other.
1115
Nyquist Plots
Nyquist plot is a mapping of loop transfer function D(s)G(s) along the
Nyquist path to a polar plot.
Think of Nyquist path as four parts:
(s)
III
II
(s)
IV
1116
0.9
M p , overshoot
Damping ratio
0.8
0.6
0.4
0.2
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
10
20
30
40
50
60
Phase margin
70
80
0
0
10
20
30
40
50
60
70
80
Phase margin