Beruflich Dokumente
Kultur Dokumente
11
FEEDBACK CONTROL
Control is a very common concept.
e.g., Independent machine: Room temperature control. Furnace in winter, air conditioner in summer. Both controlled (turned on/off) by thermostat.
AUTOMATIC CONTROL.
DEFINITION:
Control is the process of causing a system variable to conform to some desired value, called a reference value. (e.g., variable=temperature)
DEFINITION:
Feedback is the process of measuring the controlled variable (e.g., temperature) and using that information to inuence the value of the controlled variable.
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. ... (see next page for a synopsis).
12
13
Rube Goldberg showed that a knowledge of feedback control was even useful to budding cartoonists!
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.
Block Diagram of furnace-controlled room temperature controller. Identies major components and omits details. Shows information/ energy ow.
Central component = PROCESS or PLANT, one of whose variables we want to control. e.g., Plant = ; Variable = .
14
DISTURBANCE = some system input out of our direct control. e.g., Disturbance = . ACTUATOR = device that inuences controlled variable. e.g., Actuator = . REFERENCE SENSOR measures desired system output. OUTPUT SENSOR measures actual system output. * COMPENSATOR/ CONTROLLER = device that computes the control effort to apply the the actuator, based on sensor readings. e.g., combines the last three functions. A More Abstract Block Diagram:
Disturbance error Ref. Value Reference Sensor Compensator Actuator Plant Output
Negative Feedback
Output Sensor
Plant
Output
15
The Control Problem: Reject disturbance. Acceptable steady state errors. Acceptable transient response. Minimize sensitivity to parameter changes in the plant. Solution Reached By: 1. Choosing output sensors. 2. Choosing actuators. *3. Developing plant, actuator, sensor equations (models). *4. Designing compensator based on the models and design criteria. *5. Evaluating design analytically, with simulation and prototype. *6. Iteration!! A First Analysis: Auto Cruise Control Want to control speed of automobile. 1. Output sensor = speedometer. 2. Actuator = throttle and engine.
16
Block diagram:
Road Grade Desired Speed Control Variable Compensator Throttle Actual Speed
Actuator Engine
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:
w(t) r (t)reference speed, MPH. u(t)throttle posn., %. y(t)actual speed, MPH. 0.5 r (t) Compen- u(t) sator w(t)road grade, %.
10
y(t)
17
10
= r(t) 5w(t). 5. Evaluate design. r(t) = 55, w(t) = 0% yol(t) = 55. r(t) = 55, w(t) = 1% yol(t) = 50. r(t) = 55, w(t) = 2% yol(t) = 45. No Error. . . Good. 10% Error. . . Not Good. 20% Error. . . Not Good.
Suppose you load the trunk with all your ECE4510 notes and the car becomes more sluggish.
18
10
Multiply your output error by 100; FEEDBACK GAIN = 100 ycl(t) = 10u(t) 5w(t) u(t) = 100(r(t) ycl(t)) so, ycl(t) = 1000r(t) 1000ycl(t) 5w(t) 1001ycl(t) = 1000r(t) 5w(t) ycl(t) = 0.999r(t) 0.005w(t) 5. Evaluate design. r(t) = 55, w(t) = 0% ycl(t) = 54.945 r(t) = 55, w(t) = 1% ycl(t) = 54.94 r(t) = 55, w(t) = 2% ycl(t) = 54.935 r(t) = 55, w(t) = 10% ycl(t) = 54.895 ... 0.2% Error! Feedback system rejects disturbances. Feedback system has steady state error. r(t) = 55, w(t) = 0%, plant=9, not 10 ycl(t) = 54.939 Feedback system less sensitive to system parameter values. NOTE! High feedback gain = good performance here. Not always true! e.g., Public address amplier.
Lecture notes prepared by Dr. Gregory L. Plett
19
0.5 ycl(t)
10
ycl(t) = 10 (r(t) ycl(t)) 5w(t) = 10r(t) 10ycl(t) 5w(t) 10r(t) 5w(t) ycl(t) = 1 + 10 = 10 5 r(t) w(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) A Brief History of Control
Supply Float
2nd century B.C.: Fluid level/Flow rate control. Still used to ush toilets!
110
Damper
1787: Thomas Meads y-ball governor. 1788: James Watts y-ball governor.
Pivot Sleeve To engine inlet Ball Butterfly valve Steam
Rotation
Both control a rotating shaft. 1840: Airys telescope controller. and the machine (if I may so express myself) became perfectly wild. Discovery of instability in a feedback control system. Analysis of system with differential equations. Beginnings of feedback control theory.
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...?
112
1624
Drebble, Incubator
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.) Lecture notes prepared by Dr. Gregory L. Plett
21
22
LINEAR :
a.k.a. superposition.
TIME INVARIANT :
(Translation: If we input a specic signal x(t) and record the output y(t), then input a shifted version of the signal x(t), the output will be a shifted version of y(t), with the same shift.)
KEY POINT:
If a system is LTI, then it has an impulse response. This entirely characterizes the systems dynamics. The Laplace transform of the impulse response is the transfer function. Working with the transfer function eliminates the need to mess around with trying to solve complicated differential equations.
Ohms Law (model) says: v(t) = i(t) R. Is the resistor LTI? Is the model of the resistor LTI?
EXAMPLE :
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 u(t) b x(t) = m x(t) b . u(t) .. x(t) + x(t) = m m
. .. . b x(t) m x(t) u(t)
or,
24
If the variable of interest is speed (v(t) = x(t)), not position, u(t) b . v(t) + v(t) = m m Notice that the differential equation has output variables on the left of =, and input variables on the right.
IMPORTANT POINT:
All of our models of dynamical systems will be differential equations involving the input (e.g., u(t)) and its derivatives and the output (e.g., y(t)) and its derivatives. No other signals (intermediate variables) are allowed in our solutions. Car suspension.
EXAMPLE :
Each wheel in a car suspension system has a tire, shock absorber and spring. Write the one-dimensional (vertical) equations of motion for the car body and wheel.
m2 ks b m1 kw r (t) Road Surface Inertial Reference y(t)
Quarter-car model
x(t)
Free-body diagram:
ks (y(t) x(t))
. . b( y (t) x(t)) m2
m1
kw (x(t) r (t))
Lecture notes prepared by Dr. Gregory L. Plett
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 b y (t) x(t) + ks (y(t) x(t)) kw (x(t) r(t)) = m 1 x(t) ks (y(t) x(t)) b y (t) x(t) = m 2 y (t) Re-arrange: 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 . . .. . . ..
m
x1 (t)
3. Damper
x2 (t)
Vector sum of moments = moment of inertia times angular acceleration. (moment=torque). Satellite control. Satellites require attitude control so that sensors, antennas, etc., are properly pointed. Lets consider one axis of rotation.
Lecture notes prepared by Dr. Gregory L. Plett
EXAMPLE :
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 J b , k: Springiness of suspension wire. b: Viscous friction. ..
..
J
1 (t)
3. Damper
2 (t)
27
EXAMPLE :
..
(t), (t) mg
If motion is small, sin ((t)) (t). .. g (t) (t) + (t) = l ml 2 This is a preview of linearization.
Linear.
Summary of Developing Models for Rigid Bodies: 1. Assign variables such as x(t) and (t) that are both necessary and sufcient to describe and arbitrary position of the object. 2. Draw a free-body diagram of each component, and indicate all forces acting on each body and the accelerations of the center of mass with respect to an inertial reference. 3. Apply Newtons laws: F = ma, M = J .
4. Combine the equations to eliminate internal forces. 5. The nal form must be in terms of ONLY the input to the system and its derivatives, and the output of the system and its derivatives.
Dynamics of Electrical Circuits Kirchhoffs Laws: Current Law (KCL): The algebraic sum of currents entering a node equals the algebraic sum of currents leaving the node. Voltage Law (KVL): The algebraic sum of all voltages taken around a closed path in a circuit is zero.
Lecture notes prepared by Dr. Gregory L. Plett
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.
vi (t) R1 C1
C2
R2
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 v(t) v(t) + R2C 2(v (t) v (t)) = 0 v(t) + R2C 2(v (t) v (t)) = v(t) v(t) v (t) + R2C 2(v (t) v (t)) R1 v(t) + R2C 2(v (t) v (t)) v (t) R2 C1 v (t) + R2C 2(v (t) v (t)) = 0 R2 v (t) v(t) + R2C 2(v (t) v (t)) R1 v (t) + R2C 2(v (t) v (t)) v (t)
Lecture notes prepared by Dr. Gregory L. Plett
. .
. .
.. .
..
29
..
..
..
..
Important components for electrical systems: 1. Resistor v(t) i(t) v(t) = Ri(t)
2. Capacitor
v(t)
i(t)
i(t) = C
d v(t) dt d i(t) dt
3. Inductor
v(t)
i(t)
v(t) = L
4. Voltage source
v(t)
vs
v(t) = vs
5. Current source
is
i(t)
6. Operational Amplier
vo (t)
210
EXAMPLE :
Op-amp circuit.
R2 R1 C
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 R1C v o (t) = R2C v i (t) vi (t) (as C , we get an inverting amplier.) Dynamics of Electro-Mechanical Systems These are systems that convert energy from electrical to mechanical, or vice versa.
EXAMPLE :
DC Generator.
Assume generator is driven at constant speed. Generator has eld windings (input), and rotor/armature windings (output).
i f (t) R f Ra Lf eg (t) L a i a (t) ea (t) e f (t) Zl
Field circuit
Lecture notes prepared by Dr. Gregory L. Plett
Rotor circuit
Load circuit
211
di f (t) dt
e f (t) is input, i f (t) is output. K depends on generator structure. d(t)/dt = angular velocity = cst. = ux, proportional to i f (t).
d(t) dt
di a (t) + ea (t). dt
eg (t)
Kg
Rotor circuit
i a (t)
Zl
ea (t)
This is a preview of a block diagram used to simplify our understanding of the system dynamics. EXAMPLE : DC Motor (servo-motor). Directly generates rotational motion. Indirectly generates translational motion.
i a (t) Ra ea (t) La eb (t) Armature (t), (t) b J
Load
Mechanical resistance of load is translated into an electrical resistance called the back e.m.f. d(t) eb (t) = K e K e = K , as with generator. dt di a (t) ea (t) = Ra i a (t) + L a + eb (t) dt (t) = K i a (t) K = K 1
Lecture notes prepared by Dr. Gregory L. Plett
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
back emf indistinguishable from friction! Dynamics of Heat Flow/ Dynamics of Fluid Flow These two subjects will not be covered here. Refer to texts on thermodynamics or uid-dynamics. Transformers and Gears Ideally, both of these devices simply scale their input value. Transformer : Gears : N1 e1 i 2 = = N2 e2 i 1 r1 2 1 = = r2 1 2
r1 r2
System Identication (SYS ID) When we generate models of system dynamics, we are performing system identications.
Lecture notes prepared by Dr. Gregory L. Plett
213
When we use known properties from physics and knowledge of the systems structure (as we have done here) we are performing white box system ID. If the system is very complex, or if the physics are not well understood, we need to use input/output data to generate a system model: black-box system ID. A topic for the whole course! Linearization We will study how to control linear systems. Linear systems are rare. We can linearize a non-linear systemthe controller designed for linearized model will work on the true nonlinear system (but not as well as a controller designed directly for the non-linear system.)
KEY POINT:
We can convert any differential equation into a rst-order vector differential equation: x = f (x, u) ;
. .
x = vector, u = input.
Torsional pendulum (pg. 226) .. b. k (t) (t) + (t) + (t) = J J J let x1(t) x2(t) = (t) . (t)
214
x 2(t) +
0 1 k/J b/J
A
x 1(t) x2(t)
0 1/J
B
(t).
So, our model of the torsional pendulum is linear. EXAMPLE : Rotational pendulum (pg. 227) .. g (t) (t) + sin((t)) = l ml 2 let x 1(t) x2(t) x 1(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.
215
Subtract out equillibrium (nominal) solution; . x = Ax + Bu, which is linear. This is exactly how we linearized the rotational pendulum before, with 0 = 0; 0 = 0. 3 5 sin() = + 3! 5! .
216
Mechanical Translational m x(t) + b x(t) + kx(t) = u(t) .. . Mechanical Rotational J (t) + b (t) + k(t) = (t) .. Satellite J (t) = f (t) d .. k ke . k DC Motor (for L a = 0) (t) = J (t) + b + ea (t) 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)
Some Important Input Signals Several signals recur throughout this course. The unit step function: 1(t) = 1, t 0; 0, otherwise.
t r (t) 1(t)
t p(t)
32
The impulse function, (t): Very strange generalized function, only dened under an integral. (t) = 0, t = 0 zero duration
(t) dt = 1.
(t)
unit area.
Symbol
Sifting property
x( )(t ) d = x(t).
Response of Linear Time Invariant System Let y(t) be the output of an LTI system with input x(t). y(t) = [x(t)] = [ =
x( )(t ) d ]
(sifting) (linear)
x( ) [(t )] d.
33
x( )h(t, ) d
= 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 :
Consider a rst-order system, y (t) + ky(t) = u(t). Let y(0) = 0, u(t) = (t). For positive time we have y (t) + ky(t) = 0. Recall from your differential-equation math course: y(t) = Aest , solve for A, s. y (t) = Asest Asest + k Aest = 0 s+k = 0 s = k. We have solved for snow solve for A.
0+ . 0 0+ 0+ 0
y (t) dt + k
+
y(t) dt =
0
(t) dt
1
y(t)|0 0
34
Response to impulse: h(t) = ekt , t > 0. h(t) = ekt 1(t). Response of this system to general input: y(t) = = = Transfer Function Response to impulse = impulse response h(t). Response to general input = messy convolution: h(t) u(t).
0
35
=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 :
s H (s)est + k H (s)est = est 1 H (s) = s+k est y(t) = . s+k Response to Cosinusoid (revisited) Let s= j s= j u(t)=e j t u(t)=e j t u(t)=A cos(t) Now, 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 + ). The response of an LTI system to a sinusoid is a sinusoid! (of the same frequency).
Lecture notes prepared by Dr. Gregory L. Plett
36
EXAMPLE :
Frequency response of our rst order system: 1 H (s) = s+k 1 H ( j) = j + k 1 M = |H ( j)| = 2 + k 2 = H ( j) = tan1 k A y(t) = cos t tan1 . 2 + k2 k
Can we use these results to simplify convolution and get an easier way to understand dynamic response? The Laplace Transform We have seen that if a system has an impulse response h(t), we can compute a transfer function H (s), H (s) =
h(t)est dt.
Since we deal with causal systems (possibly with an impulse at t = 0), we can integrate from 0 instead of negative innity. H (s) =
0
h(t)est dt.
37
Laplace Transforms of Common Signals Name Unit impulse Unit step Unit ramp nth order ramp Sine Cosine Damped sine Damped cosine Diverging sine Diverging cosine Time function, f (t) (t) 1(t) t 1(t) t n 1(t) sin(bt)1(t) cos(bt)1(t) eat sin(bt)1(t) eat cos(bt)1(t) t sin(bt)1(t) t cos(bt)1(t) Laplace tx., F(s) 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
|a| a (useful if original equations are expressed poorly in time scale. e.g., measuring disk-drive seek speed in hours).
Differentiation:
38 t
Integration:
f ( ) d
=t
t=0 =0
=0 t=
Region of integration
=0
h( )e
t=
u(t )es(t ) dt d.
Y (s) =
=0
h( )e
t =0
u(t )est dt
Y (s) = H (s)U (s). The Laplace transform unwraps convolution for general input signals. Makes system easy to analyze. The Inverse Laplace Transform The inverse Laplace Transform converts F(s) f (t). Once we get an intuitive feel for F(s), we wont need to do this often.
39
The main tool for ILT is partial-fraction-expansion. b0s m + b1s m1 + + bm Assume : F(s) = n s + aa s n1 + + an (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 ci = (s pi )F(s)|s= pi
n
f (t) =
i =1
ci e pi t 1(t)
EXAMPLE :
F(s) =
f (t) = (5et 5e2t )1(t). If F(s) has repeated roots, we must modify the procedure. e.g., repeated three times: k F(s) = (s p1)3(s p2) c1,1 c1,2 c1,3 c2 = + + + + s p1 (s p1)2 (s p1)3 s p2 c1,3 = (s p1)3 F(s)
Lecture notes prepared by Dr. Gregory L. Plett
s= p1
=k
m i =1 (s z i ) n i =1 (s pi )
1 . sk
310
d (s p1 )3 F(s) ds
s= p1
s= p1
.
s= pi
Find ILT of
ans: f (t) = (2et 2e2t te2t )1(t). from repeated root. TEDIOUS. Use Matlab. e.g., F(s) =
Example 1. >> Fnum = [0 0 5]; >> Fden = [1 3 2]; [r,p,k] = residue(Fnum,Fden); r = -5 5 p = -2 -1 k = []
5 . s 2 + 3s + 2
Example 2. >> Fnum = [0 0 1 3]; >> Fden = conv([1 1],conv([1 2],[1 2])); [r,p,k] = residue(Fnum,Fden); 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.
Lecture notes prepared by Dr. Gregory L. Plett
311
Using the Laplace Transform to Solve Problems We can use the Laplace transform to solve both homogeneous and forced differential equations.
EXAMPLE :
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 : .. .
y(0 ) = 0, y (0) = 0, u(t) = 2e2t 1(t). 2 s 2Y (s) + 5sY (s) + 4Y (s) = s+2 2 Y (s) = (s + 2)(s + 1)(s + 4) 1 2/3 1/3 = + + . s+2 s+1 s+4
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.
Lecture notes prepared by Dr. Gregory L. Plett
312
1 h(t) = e t 1(t). s+ If > 0, pole is at s < 0, STABLE i.e., impulse response decays, and any bounded input produces bounded output. H (s) = If < 0, pole is at s > 0, UNSTABLE. is time constant factor: = 1/ .
impulse([0 1],[1 1]);
1 1
0.8
0.8
h(t)
0.6
y(t) K
0.6
0.4
1 e
0.4
0.2
0.2
0 0
t =
0 0
Time (sec )
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
= sin ( ) n
(s) 45
(s) 30
(s) 17.5
(s)
(s)
(s)
(s)
(s)
= 0.5
= 0.3
0.5
h(t)
0.5
e t
1 0
10
15
20
25
30
=0 0.2
0.5
1.5
0.4
y(t)
y(t)
0.6
=1
0.5
0.8
0.5
0.8 1.0
1 0
n t
10
12
0 0
n t
10
12
314
(s)
(s)
(s) Impulse responses vs. pole locations Step responses vs. pole locations
(s)
Time Domain Specications We have seen impulse and step responses for rst- and second-order systems. Our control problem may be to specify exactly what the response SHOULD be. Usually expressed in terms of the step response.
tp 1 0.9 Mp
0.1 tr ts
315
tr = Rise time = time to reach vicinity of new set point. ts = Settling time = time for transients to decay (to 5%, 2%, 1%). M p = Percent overshoot. t p = Time to peak.
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.
= n .
Peak occurs when y (t) = 0 . y (t) = e t cos(d t) + sin(d t) e t (d sin(d t) + cos(d t)) d =e
t
2 sin(d t) + d sin(d t) = 0. d
316
100 90 80 70
So,
d t p = , tp = = . 2 d n 1 / 1 2 Mp = e 100.
M p, %
60 50 40 30 20 10 0 0 0.2 0.4
0.6
0.8
1.0
Settling Time
Determined mostly by decaying exponential en ts = ... = 0.01, 0.02, or 0.05
EXAMPLE :
Specications on tr , ts , M p determine pole locations. n 1.8/tr . fn(M p ). 4.6/ts . (read off of versus M p graph on page 3316) (for examplesettling to 1%)
317
(s) (s)
(s)
(s)
(s)
(s)
EXAMPLE :
Specs: tr 0.6, M p 10%, ts 3 sec. at 1% n 1.8/tr = 3.0 rad/sec. From graph of M p versus , 0.6. 4.6/3 = 1.5 sec.
3 2 1
(s)
0 1 2 3 5
(s)
EXAMPLE :
Suppose a servo-motor system for a pen-plotter has transfer function 2 0.5K a n = 2 . 2 s 2 + 2s + 0.5K a s + 2 n s + n Only one adjustable parameter K a , so can choose only one spec: tr , ts or M p Allow NO overshoot.
Lecture notes prepared by Dr. Gregory L. Plett
318
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.
Same dc gain (at s = 0). Coefcient of (s + 1) pole GREATLY reduced. General conclusion: a zero near a pole tends to cancel the effect of that pole. How about transient response? H (s) =
Lecture notes prepared by Dr. Gregory L. Plett
319
Zero at s = . Poles at (s) = . Large , zero far from poles no effect. 1, large effect. Notice that the overshoot goes up as 0.
2nd-order system with zero
2
Step Response
1.5
Mp
6 8 10
0.5
=1 2 4 100
2 4
0.5
0 0
n t
0 0
10
A little more analysis; set n = 1 s/ + 1 H (s) = 2 s + 2 s + 1 1 1 s = 2 + s + 2 s + 1 s 2 + 2 s + 1 = Ho (s) + Hd (s). Ho (s) is the original response, without the zero. Hd (s) is the added term due to the zero. Notice that 1 Hd (s) = s Ho (s). The time response is a scaled version of the DERIVATIVE of the time response of Ho (s). If any of the zeros in RHP, system is NONMINIMUM PHASE.
Lecture notes prepared by Dr. Gregory L. Plett
320
y(t)
0 0.5
0.5
Hd (s)
2
1 1.5 0
0.5 0
Time (sec)
10
Time (sec)
10
Original poles at (s) = = n . New pole at s = n . Major effect is an increase in rise time.
2nd-order system with pole
1.4 9 8 7 6
Step Response
1.2 1
100 5 2 =1 n t
5 6 7 8
n tr
0.8
5 4 3 2 1 0 2 4
10
Summary of Higher-Order Approximations Extra zero in LHP will increase overshoot if the zero is within a factor of 4 from the real part of complex poles.
Lecture notes prepared by Dr. Gregory L. Plett
321
Extra zero in RHP depresses overshoot, and may cause step response to start in wrong direction. DELAY . Extra pole in LHP increases rise-time if extra pole is within a factor of 4 from the real part of complex poles.
(s) Insignicant 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.
Lecture notes prepared by Dr. Gregory L. Plett
322
Important tools: block diagram manipulation and Masons rule. Block Diagram Manipulation We have already seen block diagrams (see pg. 113). Shows information/energy ow in a system. When used with Laplace transforms, can simplify complex system dynamics. Four BASIC congurations:
U (s) H (s) Y (s) Y (s) = H (s)U (s)
U (s)
H1 (s)
H2 (s)
Y (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) so, U1 (s) = R(s) H2(s)H1(s)U1(s) = Y2 (s) H2 (s) U2 (s) R(s) 1 + H2(s)H1(s) H1(s) R(s) 1 + H2(s)H1(s) Y (s) Y (s) = [H1(s) + H2 (s)] U (s)
Alternate representation
323
Y (s) Y (s)
Y (s)
Y (s)
e f (t)
Field circuit
Kg
eg (t)
Zl
ea (t)
Compute the transfer functions of the four blocks. d if dt E f (s) = R f I f (s) + L f s I f (s) ef = Rfif + L f 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)
324
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 = (Ra + L a s + Z l ) Ia (s) Ia (s) 1 . = E g (s) L a s + Ra + Z l
Put everything together. E a (s) E a (s) Ia (s) E g (s) I f (s) = E f (s) Ia (s) E g (s) I f (s) E f (s) = Block Diagram Algebra
U (s) H (s) Y1 (s) Y2 (s) U (s) H (s) 1 H (s) U1 (s) U2 (s) H (s) H (s) Y1 (s) Y2 (s)
K g Zl . L f s + R f (L a s + Ra + Z l )
U1 (s) U2 (s)
H (s)
Y (s)
Y (s)
R(s)
H1(s) H2(s)
Y (s)
R(s)
1 H2 (s)
H2(s)
H1(s)
Y (s)
Unity Feedback
325
EXAMPLE :
Simplify:
H6 (s)
R(s)
H2 (s)
H5 (s)
Y (s)
H6 (s) H1(s) 1 H1 (s)H3(s) H4 (s) H6(s) H2(s) R(s) H1(s) 1 H1 (s)H3(s) H4 (s) H2 (s) H5 (s) Y (s) H2 (s) H5 (s) Y (s)
R(s)
H5(s)+ H6(s)
2
H (s)
R(s)
Y (s)
326
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.
U (s) H1 (s) H2(s) Y (s)
Path = Sequence of connected blocks, from one variable to another, in the direction of signal ow, without including any variable more than once. Forward Path = Path from input to output. Loop = Path from node back to itself. Path Gain = Product of all transfer functions in a path. Loop Gain = Product of all transfer functions in a loop. Nontouching = Two loops are nontouching if they have no nodes in common.
G6 G1 H1 G2 G3 H2 G4 G5
2 Loops: ,
Nontouching.
2 Forward paths: Touches both loops. Does not touch rst loop, but touches second loop.
327
Masons Rule p 1 T = Mk
k=1
M1
+ M2
+ + Mp
= 1 (sum of ALL (touching or not) individual loop gains) +(sum of the products of loop gains of all possible combinations of nontouching loops taken two at a time) (sum of the products of loop gains of all possible combinations of nontouching loops taken three at a time) + Mk = Path gain of kth forward path
k
= 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
G1
G2 H1
G3 H2
1
T =
M1
+ 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
Masons rule may be shorter that block-diagram manipulation. Use the method with which you are most comfortable.
41
Ctrlr
Plant
CLOSED LOOP :
Disturbance y(t)
r (t)
Ctrlr
Plant
Sensor
We will compare these systems in a number of ways: disturbance rejection, sensitivity, dynamic tracking, steady state error and stability. DC Motor Speed Control Recall equations of motion for a dc motor (pg. 2211) but add load torque.
i a (t) Ra ea (t) La eb (t) Armature (t), (t) b J l , load
Load
. 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
.. .
42
(J L a s s + bL a s + J Ra s + b Ra + k ke )Y (s) = k E a (s) + (Ra + L a s)W (s) This can be re-written as (magic happens) (1s + 1)(2s + 1)Y (s) = AE a (s) + BW (s) 1 Ra J/(k ke ) = mechanical time constant 2 L a /Ra = electrical time constant A = k /(b Ra + k ke ) B = Ra /(b Ra + k ke ) So, Y (s) = A B E a (s) + W (s). (1s + 1)(2s + 1) (1s + 1)(2s + 1)
If ea (t) = ea 1(t) (constant) and w(t) = w 1(t) (constant), What is steady state output? Recall Laplace-transform nal value theorem:
If a signal has a constant nal value, it may be found as yss = lim sY (s).
s0
ea w , W (s) = , yss = Aea + Bw. s s This is the response of the open-loop system (without a controller). E a (s) =
Lecture notes prepared by Dr. Gregory L. Plett
So,
43
B A
Ctrlr
Lets make a simple controller for the open-loop system. ea (t) = K ol r(t), (gain of K ol ) Choose K ol so that there is no steady-state error when w = 0. yss = AK ol rss + Bwss K ol = 1/A. Is closed-loop any better?
Dist. w(t) r (t) ea (t) B A A (1s + 1)(2s + 1) 1 Tachometer y(t)
Ctrlr
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
Lecture notes prepared by Dr. Gregory L. Plett
44
If AK cl
1, yss rss .
Open-loop with load: yss = AK ol rss + Bwss = rss + Bwss y = Bwss . Closed-loop with load: yss = AK cl B rss + wss 1 + AK cl 1 + AK cl B y wss . 1 + AK cl 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
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
FEEDBACK MOVES POLES System may have faster/slower response System may be more/less damped System may become unstable!!! Often a high gain K cl results in instability. We need design tools to help us design the dynamic response of the closed-loop system. For this dc motor example, we can get step responses of the following form:
1.5
High K cl y(t)
1
0.5
Low K cl
2 4 6 8 10
0 0
Time (sec)
G(s)
Need to design controller D(s). One option is PID (Proportional Integral Derivative) control design.
Lecture notes prepared by Dr. Gregory L. Plett
47
Extremely popular. 90+% of all controllers are PID. Doesnt mean that they are great, just popular. We just saw proportional control where u(t) = K e(t), or D(s) = K . Proportional control allows non-zero steady state error. Increases speed of response. Larger transient overshoot. Integral control eliminates steady state error. D(s) = Dynamic response gets worse. Derivative control damps dynamic response. D(s) = K D s. 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:
Determine behavior of closed loop poles for the dc motor. Y (s) AK = . R(s) (1s + 1)(2s + 1) + AK
Poles are roots of (1s + 1)(2s + 1) + AK . Without feedback, K 0. s1 = 1/1, With feedback, s1 , s 2 = (1 + 2) (1 + 2)2 412 (1 + AK ) . 212 s2 = 1/2.
48
(1 2 )2 K = 412 A K =0 1 2 K =0 1 1 1 + 2 212
(s)
(s)
(We will see many root-locus plots in this course!) (1 2)2 After a certain gain K = , the poles go straight up and down. 412 A Settling time remains the same, rise time decreases, damping decreases (more overshoot.) For larger systems increasing K leads to instability. How do we improve accuracy, but keep stability?
49 t 0
..
(r( ) y( )) d + Bw(t).
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 12 y (t) + (1 + 2) y (t) + y (t) = If r(t) = cst, w(t) = cst, w(t) = 0, AK AK yss = rss TI TI Steady-state improves Dynamic response degrades. Very oscillatory. Possibly unstable. Can be improved by adding proportional term to integral term. u(t) = K e(t) +
0 t
no error.
(s)
K =0K =0 1 1 2 1
(s)
K e( ) d, TI
D(s) = K 1 +
1 . TI s
D(s) = K TD 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. Does nothing to reduce constant error! If e(t) = 0, then u(t) = 0. Motor Control: Poles at roots of 12s 2 + (1 + 2 + AK TD )s + 1 = 0. TD enters term, can make damping better. PD = Proportional plus derivative control D(s) = K (1 + TD s) Root locus for dc motor, PD control.
(s) 1 2 1 TD 1 1 (s) .
411
(math happens). Solve for poles 12 TI s 3 + TI ((1 + 2) + AK TD )s 2 + TI (1 + AK )s + AK = 0 AK 1 + 2 + AK TD 2 1 + AK s + s+ s3 + = 0. 12 12 12 TI Three coefcients, three parameters. We can put poles anywhere! Complete control of dynamics in this case. Entire transfer functions are: Y (s) TI Bs = . W (s) TI 12s 3 + TI (1 + 2)s 2 + TI (1 + AK )s + AK Y (s) AK (TI s + 1) = . R(s) TI 12s 3 + TI (1 + 2)s 2 + TI (1 + AK )s + AK We can plot responses in MATLAB:
num = [TI*B 0]; den = [TI*TAU1*TAU2 TI*(TAU1+TAU2) TI*(1+A*K) A*K]; step(num, den) Step Reference Response
1.6 1.4
y(t) (rad/sec)
y(t) (rad/sec)
PI P
PID
PI PID
0.03
0.04
0.05
0 0
0.01
0.02
0.03
0.04
0.05
Time (sec)
Time (sec)
412
We can easily identify A, d , from this step response. Dont need complex model! Tuning criteria: Ripple in impulse response decays to 25% of its value in one period of ripple
1 0.25 Period
RESULTING TUNING RULES :
P K = Ad
PI 0.9 A d d TI = 0.3 K =
METHOD II :
Congure system as
r (t) Ku Plant y(t)
Turn up gain K u until system produces oscillations (on stability boundary) K u = ultimate gain.
Lecture notes prepared by Dr. Gregory L. Plett
413
Period, Pu
P K = 0.5K u
PI K = 0.45K u 1 TI = Pu 1.2
Practical Problem: Integrator Overload Integrator in PI or PID control can cause problems. For example, suppose there is saturation in the actuator. Error will not decrease. Integrator will integrate a constant error and its value will blow up. Solution = integrator anti-windup. Turn off integration when actuator saturates.
K e(t) K TI s u(t) u min u max Ka
Doing this is NECESSARY in any practical implementation. Omission leads to bad response, instability.
414
Step Response
1.6 1 1.4 1.2 1
Control Effort
0.8 0.6
Without antiwindup
y(t)
With antiwindup
With antiwindup
2
10
0.6 0
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)
The closed-loop transfer function for the whole system, Y (s) T (s) = . R(s) The error is E(s) = R(s) Y (s)
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
R(s) =
t2 1(t) 2
1 s k+1
As k increases, tracking is progressively harder. 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.
There are some important simplications: G ol (s) T (s) = 1 + G ol (s) 1 + G ol (s) G ol (s) 1 T (s) = 1 + G ol (s) 1 + G ol (s) 1 = . 1 + G ol (s) So, E(s) =
Lecture notes prepared by Dr. Gregory L. Plett
1 R(s). 1 + G ol (s)
417
1
s0
For type 0, ess = lim For type 1, ess = lim For type 2, ess = lim 1 1 1 1 = lim 2 , = s0 1 + G ol (s) s 2 s0 s G ol (s) Ka K a = lim s 2 G ol (s).
s0
1 1 , = s0 1 + G ol (s) 1 + Kp
K v = lim sG ol (s).
s0
These formulas only meaningful for unity-feedback! K p = lim G ol (s). position error constant
s0
K v = lim sG ol (s).
s0
K a = lim s 2 G ol (s).
s0
Steady-state tracking errors ess for unity-feedback case ONLY. Sys. Type Type 0 Type 1 Type 2 Step Input 1 1 + Kp 0 0 Ramp Input 1 Kv 0 Parabola Input 1 Ka
418
EXAMPLES:
1 1 = . 23 6 1 6 Therefore, type= 0, ess to unit step= = . 1 + 1/6 7 (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) =
Lecture notes prepared by Dr. Gregory L. Plett
419
EXAMPLE:
So system is type 0, with s.s. error to step input of agrees with prior results.)
EXAMPLE :
Controller: D(s) = K 1 +
s0
D(s)G(s) =
s0
lim s D(s)G(s) =
TI . KA
420
Controller: D(s) = K 1 +
1 1 . + TI s TI s 2 KA+
KA TI s
(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 Steady State Error (w.r.t. Disturbance) Recall, system error is any difference between r(t) and y(t). One source of system error is disturbance. Can nd system type with respect to disturbance. Y (s) = Tw (s) W (s) such that Y (s) = T (s)R(s) + Tw (s)W (s). TI . KA
D(s)G(s) =
KA TI s 2
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
Lecture notes prepared by Dr. Gregory L. Plett
51
STABILITY ANALYSIS
Many classications of stability in system analysis. For LTI systems, all are basically the same BIBO.
Stable
Neutral
Unstable
If input is bounded: |u(t)| < K 1, then output is also bounded |y(t)| < K 2. In the time domain, y(t) = |y(t)| =
h( )u(t ) d h( )u(t ) d
52
|h( )| |u(t )| d
Stable?
zi ) n 1 (s pi )
m 1 (s
m n.
h(t) =
i =1
ki e pi t iff ( pi ) < 0 i.
|h( )| d <
(If poles are not distinct, h(t) will have terms k t m1e pi t (m 1)! for an mth order root.
|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
EXAMPLE :
T (s) =
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). Y (s) = s 1 s = 2 s 2 + 1 s 2 + 1 (s + 1)2 y(t) = t sin(t) . . . unbounded.
MARGINALLY stable = unstable (bounded impulse response, but unbounded output for some inputs.) Routh Hurwitz Stability Criterion Factoring high-degree polynomials to nd roots is tedious and numerically not well conditioned. Want other stability tests, and also MARGINS of stability.
54
(1) Routh test Can you tell this is (2) Root locus an important topic? (3) Nyquist test (4) Bode stability margins In 1868, Maxwell found conditions on the coefcients of a transfer function polynomial of 2nd and 3rd order to guarantee stability. It became the subject of the 1877 Adams Prize to determine conditions for stability for higher-order polynomials. Routh won this prize, and the method is still useful.
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 :
55
an1 = (1) sum of all roots. an2 = sum of products of roots taken two at a time. an3 = (1) sum of products of roots taken three at a time. . . . a0 = (1)n product of all roots. Conclusions: 1. If any coefcient ai = 0, not all roots in LHP. 2. If any coefcient ai < 0, at least one root in RHP.
TEST:
EXAMPLE :
From conclusion (1), not all roots in LHP. Roots at s = j. Marginally stable.
EXAMPLE :
From conclusion (2), at least one root is in RHP. Roots at s = 1, s = 4, s = +3. Unstable.
EXAMPLE :
a(s) = s 3 + s 2 + 2s + 8.
We dont know yet if this system is stable or not. 1 j 15 Roots at s = 2, s = . Unstable, but how do we nd out 2 2 without factoring?
Lecture notes prepared by Dr. Gregory L. Plett
56
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. sn s n1 s n2 s n3 . . . s1 s0 an an2 an4 an1 an3 an5 b1 b2 c1 c2 j1 k1
b1 = 1 an an2 an1 an1 an3 1 an an4 an1 an1 an5 1 an1 an3 b1 b1 b2 1 an1 an5 b1 b1 b3
b2 =
c1 =
c2 =
TEST :
EXAMPLE :
s3 1 2 s2 1 8 s 1 6 s0 8
1 1 8 6 6 0
57
EXAMPLE :
s3 s2 s
1
s0
a0 a1 a2 a0
= a1 c1 = 1 a2 a0 b1 b1 0 =
1 (a0b1 ) = a0. b1
a0 . a2
Case 2
0 Sometimes nd an element in rst column = 0 (!) 0 Replace with as 0.
58
EXAMPLE :
1 (4 4) = 0 2 1 (10 22) = 6 2 1 12
b2 =
1 1 11 2 2 10 1 2 4 6
s5 s4 s3 new s 3 s2 s1 s0 If If
1 2 0 12 6 10
2 11 4 10 6 6 10
c1 =
(12 4 )
c2 =
1 2 10 0 6 10
(0 10 ) = 10
> 0, two sign changes. < 0, two sign changes. Two poles in RHP.
d1 =
12
12
12
(10 +
72
)6
1 e1 = 6
12 6
10 0
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
Complete Routh array by making polynomial a1(s) from last non-zero row in array. Poly has even orders of s only!! a1(s) is a factor of a(s). It is missing some orders of s, so IS NOT STABLE (by case 0.) We want to see if it has roots in the RHP or only on the j-axis. da1(s) Replace zero row with and continue. ds
EXAMPLE :
a(s) = s 4 + s 3 + 3s 2 + 2s + 2. 3 2 2 2 0
b1 = 1 1 3 1 1 2 1 1 2 1 1 0 = 1
s4 s3 s2 s1 new s 1 s0
1 1 1 0 2 2
b2 =
= 2
No sign changes in Routh array. So, no RHP roots. Roots of a1(s) at s = j 2. Marginally stable.
1 1 2 c1 = 1 1 2 1 1 2 2 2 0
= 0
a1(s) = s 2 + 2 da1(s) = 2s ds
d1 =
= 2
510
EXAMPLE :
a(s) = s 4 + 4 (Hard). 1 0 4 0 0 0 0 4 4 4
a1 (s) = s 4 + 4; 1 1 0 4 4 0 1 1 4 4 4 0 1 4 0 4 4 0 da1(s) = 4s 3. ds = 0
s4 s3 new s 3 s2 new s 2 s1 s0
b1 =
16 4
b2 =
= 4
Two sign changes. Therefore 2 RHP poles. Other two poles are mirrors in LHP.
c1 =
16
d1 =
16
16
= 4
K (s + 1) s(s 1)(s + 6) + K (s + 1)
511
= s 3 + 5s 2 + (K 6)s + K . s3 s2 s
1
s0
1 K 6 5 K 4K 30 5 K
b1 =
1 1 K 6 5 5 K
1 (K 5(K 6)) 5
c1 =
Amplitude
10
12
Time (sec.)
EXAMPLE :
r (t)
K 1+
1 TI s
1 (s + 1)(s + 2)
y(t)
512 K TI s+K
a(s) = s 3 + 3s 2 + (2 + K TI )s + K . s3 s2 s1 s
0
1 2 + K TI 3 K 6 + 3K TI K 3 K
b1 =
1 1 2 + K TI 3 3 K 1 3 K b1 b1 0
1 (K 3(2 + K TI )) 3 1 (b1 K ) = K b1
c1 =
For stability of the closed-loop system, 0 < K < 1 K > 0 for TI > . 3
1.2 1
K = 3, TI = 0.5 K = 1, TI = 0.25 K = 1, TI =
Amplitude
10
12
Time (sec.)
R( s )
+ _
Gp ( s )
K .Gp ( s ) Y( s ) R ( s ) 1 K .Gp ( s ) s Gp ( s )
m n
}
......
am bn
1 1
.s m
1
.s n
....... m n N( s ) D( s )
a0 N ( s ) b D( s )
0
N( s )
and
D( s )
Y( s ) R( s )
K. 1
The closed loop poles are the roots of the characteristic equation
( s ) D( s )
The location of the roots of
( s)
Root Locus
( s) 1
K.
N( s ) D( s ) D( s )
K .N( s ) 0
i =
open
loop poles
n m
open
loop zeros
The root loci may be found on portions of the real axis to the left of an odd number of open-loop poles and zeros. The root loci are asymptotic to straight lines, for large values of s, with angles given by
(1 + 2k ) n m
k = 0,1,..., n m 1 n = no. of finite open loop poles m = no. of finite open loop zeros
120
90
72
RD 1
RD 2
RD 3 x
RD 4
in the asymptote charts above
RD 5
Example
Plant
R( s )
+ _
Gp ( s )
Y( s )
Gp ( s )
s .( s K. 1
1 2 ) .( s
4) 4) 4)
s 0, 2, 4
Y( s ) R( s )
s .( s s .( s
1 2 ) .( s 1 2 ) .( s 1 s .( s
K.
}
4)
( s) 1
K.
2 ) .( s
j j
X X
-4 -2
X X
-4 -2
centroid
centroid RD 3
2 3
-4
X X
-2
Imag Axis
a. Locus must be symmetric about real axis b. Open loop zeros at infinity = 3 c. Locus starts at open loop poles and goes to the open loop zeros
-2
Note: Locus is symmetric about the real axis because complex poles always come in conjugate pairs
-4
-6 -6
-5
-4
-3
-2
-1
Real Axis
Example
Plant
R( s )
+ _
Gp ( s )
Y( s )
Gp ( s )
(s K. 1
1 ) .( s
s 2 3 3j) .( s
3j)
}
3j)
s=2 s = 3 j3
Y( s ) R( s )
(s (s
1 ) .( s 1 ) .( s
3 3
K.
3j)
( s) 1
K.
(s
1 ) .( s
3j)
X
|
X
|
centroid
oX
oX
-3 -2 -1
-3 -2 -1
X
5 2
Centroid
1 2
( 2)
oX
-3 -2 -1
RD 2
10 8 6
4 2 0 -2 -4 -6 -8
a. Locus must be symmetric about real axis b. Open loop zeros at infinity = 2 c. Locus starts at open loop poles and goes to the open loop zeros
-10 -4
-3
-2
-1
Real Axis
Example
R( s )
+ _
Gp ( s )
Y( s )
Gp ( s )
(s K.
1 1 ) .( s
3)
1, 3
Y( s ) R( s )
1 ( s 1 ) .( s 3 ) 1 K. ( s 1 ) .( s 3 ) 1 1 ) .( s
}
}
( s) 1
K.
(s
3)
j
centroid
X X
-3 -1
X X
-3 -1
Centroid
3 2
X X
-3 -1
2.5
RD 2
Imag Axis
2 1.5 1 0.5 0
Step 4. Draw the Root Locus a. Locus must be symmetric about real axis b. Open loop zeros at infinity = 2 c. Locus starts at open loop poles and goes to the open loop zeros
Real Axis
R( s ) (s 1 1 ) .( s Gp ( s ) 3)
Step Response
Y( s )
Gp ( s )
Let R(s) = Unit step
0.3
Y( s )
1 3 s
Amplitude
1 2 s 1 s
1 6 3
0.25
0.2 0.15
0.1
0.05
0 0 1 2 3 Time (sec.) 4 5 6
Y( s )
_
R( s )
Let R(s) = unit step
Gp ( s )
K 30 K 10 K 4 K 1
0.8 Amplitude
0.6
}
10
0.4
0.2
0 0 2 4 Time (sec.) 6 8
Note: Higher values of K speed up the closed-loop response when compared to the open-loop response
Example
R( s )
Gp ( s )
Y( s )
Gp ( s )
s .( s K.
3 ) .( s
1 j .7.4 ) .( s 1 j .7.4 ) .( s 3
j .7.4 )
}
3 3 j .7.4 ) j .7.4 )
Y( s ) R( s )
s .( s s .( s
3 ) .( s 3 ) .( s
K.
1 j .7.4 ) .( s 1 j .7.4 ) .( s
( s) 1
K.
s .( s
3 ) .( s
j .7.4 )
X X
-3 X
X
-3
X
centroid
Centroid
3 4
9 4
2.25
X X
-3
RD 4
Step 4. Draw the Root Locus a. Locus must be symmetric about real axis b. Open loop zeros at infinity = 4 c. Locus starts at open loop poles and goes to the open loop zeros
8 6 4
Imag Axis
2 0
-2 -4 -6 -8 -4
-3
-2
-1
Real Axis
R( s )
+ _
Y( s ) K Gp ( s )
( s) 1 ( s)
K .Gp ( s ) s clp
characteristic equation
=0
Magnitude Condition
( s) 1
K .Gp ( s ) K .Gp ( s )
s clp
=0
=>
K .Gp ( s )
= -1
s clp
s clp
} }
K . Gp ( s )
s clp
=1
Magnitude Condition
Angle Condition
K .Gp ( s )
= -1
}
=
s clp Angle( 1 )
Angle K .Gp ( s )
s clp
Angle Gp ( s )
= -180
s clp
Use -180 degrees as opposed to 180 degrees by convention (only here) (Note K is a real number)
Angle Gp ( s )
= -180
Angle Condition
s clp
Example
R( s ) Gp ( s ) (s s 2 1 ) .( s 4)
+ _
Y( s ) K Gp ( s )
Y( s ) R( s )
K. 1
(s (s
s 2 1 ) .( s s 2 1 ) .( s
4) 4)
K.
closed loop TF
1 0.8 0.6
Imag Axis
0.4 0.2 0
Magnitude Condition
K . Gp ( s )
K.
5
=
(s
s 2 1 ) .( s
4) 1
=1
s
=>
5 K 4 3
K.
3 .( 1 ) ( 4)
Angle Condition
Angle Gp ( s )
=
Angle( s
2)
Angle( s
4)
Angle( s
1)
= - 180
Angle( 3 )
( Angle( 1 ) )
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
62
Closed-loop transfer function T (s) = Poles = roots of 1 + K G(s) = 0. Assume plant transfer function G(s) is rational polynomial: b(s) G(s) = , such that a(s) b(s) = (s z 1)(s z 2) (s z m ) a(s) = (s p1)(s p2 ) (s pn ) (b(s) is monic.) (a(s) is monic.) K G(s) . 1 + K G(s)
nm
[a(s) may be assumed monic without loss of generality. If b(s) is not monic, then its gain is just absorbed as part of K in 1 + K G(s) = 0] zi are zeros of G(s), the OPEN-LOOP transfer function. pi are poles of G(s), the OPEN-LOOP transfer function. CLOSED-LOOP poles are roots of equation 1 + K G(s) = 0 a(s) + K b(s) = 0, which clearly move as a function of K . Zeros are unaffected by feedback.
EXAMPLE :
1 . Find the root locus. s(s + 2) a(s) = s(s + 2); b(s) = 1. G(s) = Locus of roots: (aside, stable for all K > 0 .) s(s + 2) + K = 0 s 2 + 2s + K = 0.
63
For this simple system we can easily nd the roots. 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)
Suppose we want damping ratio=0.707. We can recall that 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 .
Lecture notes prepared by Dr. Gregory L. Plett
64
[A value of s = s1 is on the (0) complementary root locus iff 1 + K G(s1) = 0 for some REAL value of K , < K < 0.] 1 So, K = G(s) Note, G(s) is complex, so this is really two equations! 1 |K | = G(s) G(s) = 1 . K
(6.1) (6.2)
Since K is real and positive, K = 0. Therefore, G(s) = 180 l360, l = 0, 1, 2, . . . So once we know a point on the root locus, we can use the magnitude equation 6.1 to nd the gain K that produced it. We will use the angle equation 6.2 to plot the locus. i.e., the locus of the roots = all points on s-plane where G(s) = 180 l360.
NOTES :
1. We will derive techniques so that we dont need to test every point on the s-plane! 2. The angle criteria explains why the root locus is sometimes called the 180 root locus. 3. Similarly, the complementary root locus is also called the 0 root locus.
KEY TOOL :
For any point on the s-plane G(s) = (due to zeros) (due to poles). (s z 1) . (s p1)(s p2 )
EXAMPLE:
G(s) =
65
(s) z1 p2 p1 (s)
G(s1) = z1 p1 p2 .
Test point s1
Locus on the Real Axis Consider a test point s1 on the real axis. If the point is right of all poles and zeros of G(s), then G(s) = 0. NOT ON THE LOCUS.
p2 (s)
z1
p1
G(s) = z 1 p1 p2 p2 = 0 0 p2 p2 = 0.
p2
OBSERVATION :
If the test point is on the real axis, complex-conjugate roots have equal and oposite angles which cancel and may be ignored.
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.
Lecture notes prepared by Dr. Gregory L. Plett
66
If the test point s1 is to the left of 1 pole and 1 zero: G(s1) = 180 (180) = 360 = 0. 2 poles: G(s1) = 180 180 = 360 = 0. 2 zeros: G(s1) = 180 + 180 = 360 = 0. NOT ON THE LOCUS.
GENERAL RULE #1 All points on the real axis to the left of an odd number of poles and zeros are part of the root locus.
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
Because we assume that system models are rational-polynomial with real coefcients, all poles must be either real or complex conjugate pairs. Therefore, THE ROOT LOCUS IS SYMMETRICAL WITH RESPECT TO THE REAL AXIS. (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
What happens at K = 0, ?
At K = 0 the closed loop poles equal the open-loop poles. As K approaches (s p1)(s p2 ) (s pn ) + (s z 1 )(s z 2) (s z m ) = 0; K the n poles approach the zeros of the open-loop transfer function, INCLUDING THE n m ZEROS AT C . Plug s = into G(s) and notice that it equals zero if m < n. The idea of in the complex plane is a number with innite magnitude and some angle. To nd where the n m remaining poles go as K , consider that the m nite zeros have canceled m of the poles. Looking back at the remaining n m poles (standing at C ), we have approximately 1 1+K , (s )nm or n m poles clustered/centered at . We need to determine , the center of the locus, and the directions that the poles take.
Lecture notes prepared by Dr. Gregory L. Plett
68
Assume s1 = Re j is on the locus, R large and xed, variable. We use geometry to see what must be for s1 to be on the locus. Since all of the open-loop poles are at approximately the same place , the angle of 1 + K G(s1) is 180 if the n m angles from to s1 sum to 180. (n m)l = 180 + l360, l = 0, 1, . . . , n m 1 or 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) There is one pole going to C along the negative real axis. There are two poles going to C vertically. One goes left and the other two go at plus and minus 60.
To nd the center, , reconsider our approximation as |s| . Divide (by long division) An easier way...
Lecture notes prepared by Dr. Gregory L. Plett
b(s) 1 and match the top and a(s) (s )nm two coefcients of s, the dominant ones.
69
Note that roots of denominator of G(s) satisfy: s n + a1s n1 + a2s n2 + + an = (s p1)(s p2) (s pn ) a1 = pi . Note that the roots of the denominator of T (s) are s n + a1s n1 + a2s n2 + + an + K (s m + b1s m1 + + bm ) = 0. If n m > 1 then the (n 1)st coefcient of the closed loop system is such that a1 = ri where ri are the closed-loop poles. We know that m poles go to the zeros of G(s), and assume the 1 other n m are clustered at . Therefore, the asymptotic (s )nm sum of roots is (n m) zi . Putting this all together, ri = (n m) + or = zi = pi
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
610
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
(s)
(s)
G(s) =
1 . s(s + 4 + 4 j)(s + 4 4 j)
p1 (s)
2 p2 1 (s)
p1
Take a test point s0 very close to p1 . Compute G(s0). If on locus 90 1 135 = 180 + 360l l = 0, 1, . . .
612
where
1 = Angle from p1 to s0 90. 1 = Angle from p1 to s0. 2 = Angle from p2 to s0 135. 1 = 45.
Can now draw departure of poles on locus. Single-pole departure rule: dep = qdep = qarr = (zeros) (zeros) (poles) (remaining poles) 180 360l. (remaining poles) 180 360l. (remaining zeros) + 180 360l. Multiple-pole departure rule: (multiplicity q 1) Multiple-pole arrival rule: (multiplicity q 1) 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
As two poles approach each other gain is increasing. When they meet, they break away from the real axis and so K increases only for complex parts of the plane. Therefore gain K along a branch of the locus is maximum at breakaway point. Gain K is minimum along a branch of the locus for arrival points. Both are saddle points in the s-plane. So, dK = 0, ds where 1 + K G(s) = 0 1 K = G(s) 1 d or, = 0 multiple root at s0. ds G(s) s=s0 [must verify that s0 is on the root locus. May be an extraneous result.]
Lecture notes prepared by Dr. Gregory L. Plett
614
Some similar loci for which nding saddle points helps clarify ambiguity ...
(s) (s)
(s)
(s)
(s)
(s)
(s)
(s)
Finding K for a Specic Locus Point Recall that the root locus is dened by the equation 1 + K G(s) = 0, which can be broken up into a magnitude-equation and a phase-equation (Eqs: 6.1 and 6.2). 1 |K | = G(s) G(s) = 1 . K
615
The magnitude equation may be used to nd the value of K to get a specic set of closed-loop poles. 1 That is, K = is the gain to put a pole at s0, if s0 is on the locus. G(s0) Summary: Root-Locus Drawing Rules180 Locus The steps in drawing a 180 root locus follow from the basic phase denition. This is the locus of
1+K 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 = qarr = i i i 180 l360 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
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90.
Lecture notes prepared by Dr. Gregory L. Plett
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
616
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)
(s) (s)
y(t)
EXAMPLE :
y(t)
Recall that the root-locus rules plot the locus of roots of the equation b(s) 1+ K = 0. a(s)
617
Compute T (s) to determine the characteristic equation as a function of K . s+2 K s10 T (s) = (s+2)(s+3) 1 + K (s+1)(s10) = Poles of T (s) at or 1+K K (s + 2)(s + 1) (s + 1)(s 10) + K (s + 2)(s + 3)
(s) (s)
1) Open loop poles and zeros: 2) Real axis 3) Asymptotes 4) Departure angles 5) Stability boundary: Note, characteristic equation = (s + 1)(s 10) + K (s + 2)(s + 3) = s 2 9s 10 + K s 2 + 5K s + 6K = (K + 1)s 2 + (5K 9)s + 6K 10
618
Routh Array s2 K + 1 6K 10 s 1 5K 9 s 0 6K 10
stability criterion
When K = 9/5, the s 1 row of the Routh array is zerotop row becomes a factor of the characteristic equation. Imag.-axis crossings where 9 9 + 1 s 2 + 6 10 = 0 5 5 14s 2 + 4 = 0
(s) (s)
...
s = j
2 . 7
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
Lecture notes prepared by Dr. Gregory L. Plett
619
= (2 + 2)s 3 + (18 5 + 10 9)s 2 + (20 + 45 + 12 45)s + (50 54) = 0 322 4(14)(4) 32 1248 s= = 28 28 roots at {0.118, 2.40}. Now we can complete the locus: 32
(s) (s)
= 14s 2 + 32s 4 = 0
EXAMPLE :
r (t)
1 s+a
s+1 s2
y(t)
Two design parameters: K , pole location a. s+1 G(s) = 2 . s (s + a) Test a = 2, a = 50, a = 9. 1) Poles and zeros of G(s).
(s) (s)
2) Real axis.
Lecture notes prepared by Dr. Gregory L. Plett
620
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) (remaining poles) 180 360l = 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 = s 2s 2 + (a + 3)s + 2a = 0 breakaway at 0, a + 3 (a + 3)2 4(2)(2a) 2(2)
=0
621
a=2
(s)
a=9
(s)
(s)
(s)
a = 50
(s)
(s)
Matlab and Root Loci b(s) b0s m + b1s m1 + + bm If G(s) = . = a(s) a0s n + a1s n1 + + an
b = [b0 b1 b2 . . . bm]; a = [a0 a1 a2 . . . an]; rlocus(b,a); % plots the root locus
Also, k=rlocfind(b,a); returns the value of K for a specic point on the root locus (graphical, with a mouse). Matlab is also able to draw space aliens!
z=[-5+5j -5-5j -4.8+2j -4.8-2j 0.35+0.2j 0.35-0.2j ... 2j -2j 2j -2j 0.7 0.7 1.0+1.5j 1.0-1.5j 1.0+1.5j 1.0-1.5j 2.2]; p=[-4.5+3.2j -4.5-3.2j -0.15+0.8j -0.15-0.8j 0.3j -0.3j 0.4+0.3j ... 0.4-0.3j 0.45+0.6j 0.45-0.6j 1+1.3j 1-1.3j 1+1.3j 1-1.3j 2+0.15j ... 2-0.15j 2]; num=poly(z); den=poly(p); rlocus(num,den);
622
6 4 2 Imag Axis 0 2 4 6 6
2 1 Real Axis
Summary: Root-Locus Drawing Rules0 Locus We have assumed that 0 K < , and that G(s) has monic b(s) and a(s). If K < 0 or a(s)/b(s) has a negative sign preceding it, we must change our root-locus plotting rules. Recall that we plot 1 + K G(s) = 0 1 G(s) = K G(s) = 180, if K positive; 0 , if K negative.
In the following summary of drawing a 0 root locus, the steps which have changed are highlighted. The steps in drawing a 0 root locus follow from the basic phase denition. This is the locus of
1+K 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.
STEP 3:
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 = qarr = i i i l360 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
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90. STEP 7: Complete the locus, using the facts developed in the previous steps and making
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
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 )|
Extensions to Root Locus MethodTime Delay A system with a time delay has the form G(s) = ed s G (s) where d is the delay and G (s) is the non-delayed system.
Lecture notes prepared by Dr. Gregory L. Plett
624
This is not in rational-polynomial form. We cannot use root locus techniques directly.
METHOD
2:
Directly plot locus using phase condition. i.e., G(s) = (d ) + G (s) if s = + j. i.e., look for places where G (s) = 180 + d + 360l. Fix , search horizontally for locus.
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) K 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.
Lecture notes prepared by Dr. Gregory L. Plett
72
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. Usually a very limited approach, but a good place to start.
2) Integral Feedback
1 D(s) = TI s T (s) = 1
K G(s) TI s . K + TI G(s) s
K u(t) = TI
t 0
e( ) d
Usually used to reduce/eliminate steady-state error. i.e., if e(t) constant, u(t) will become very large and hopefully correct the error. Penalty: Steady-state response improves, but often transient response degrades.
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)
Lecture notes prepared by Dr. Gregory L. Plett
73
If we make D(s) =
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)
We can make ess small by making K very large, but this often leads to poorly-damped behavior and often requires excessively large actuators.
1 , ess = 0. TI s Increasing K to increase the speed of response pushes the pole toward the imaginary axis oscillatory.
(s)
74
Proportional-Integral (PI) Control s + (1/TI ) 1 Now, D(s) = 1 + = . Both a pole and a zero. TI s s
(s)
(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
(s)
(s)
Good steady-state error without overow problems. Very similar to proportional control.
u(t) = K TD e(t).
Does not do much (anything?) to help the steady-state error. Derivative control provides feedback that is proportional to the rate-of-change of e(t) control response ANTICIPATES future errors. Very benecial. Used a lot!
EXAMPLE :
G(s) =
1 , (s + a)(s + b)
(s)
D(s) = TD s.
(s)
76
(s)
(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 = dc gain. G(s) b1 s + 1 s=0 |a0||G(0)| = dc gain. a0 =
Lecture notes prepared by Dr. Gregory L. Plett
77
a1 and b1 are chosen to make locus go through s = s1, a1 s1 + a 0 G(s1) = 1 b 1 s1 + 1 for that point to be on the root locus. a 1 s1 + a 0 |G(s1)| = 1 Magnitude b 1 s1 + 1 Phase a 1 s1 + a 0 + G(s1) = 180. b 1 s1 + 1
(math happens) sin() + a0|G(s1)| sin( ) a1 = s1 = |s1|e j |s1||G(s1)| sin() sin( + ) + a0|G(s1)| sin() G(s1) = |G(s1)|e j . b1 = |s1| sin() 1 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 . So, arbitrarily choose
s=0
a1: Note, = 135, = 270 because 1 1 G(s1) = 2 = e j 270 . s s=22e j 135 8 sin(135) + 2(1/8) sin(45) (1/ 2)(1 + 1/4) 5 a1 = = = . ) 2 (2 2)(1/8) sin(270 2/4 b1 : sin(135 ) + 2(1/8) sin(135 ) (1/ 2)(1 1/4) 3 b1 = = = . 16 (2 2) sin(270) 2 2
78
(5/2)s + 2 . (3/16)s + 1
Imag Axis
1 0 1 2 3 4 6 5 4 3 2 1 0 1
Real Axis
79
(s) (s) K s V1 1 K
1 V2
(s) (s) K s V1
1 K
1 V2
1 V2
(s) (s) K s + p1 1
K p1 1/K V2
p1
V1
(s) (s) K s s + p1 V1 K
K p1
1 V2
p1
K p1 1 z1 V1 1 K K1 1 K 1z1 1/K V2
710
K1 K = K2 any p1 and z 1
1 K 2 p1
V2
V1 1 1 p1 1 z 1 p1
V2
LAG
V1 1 z 1 p1 1 1 p1
V2
LAG
(s) (s)
s + z1 s + p1 p1 z1
V1 1 1 p1 p1 z 1 z1
V2
p1 > z 1 K =
LEAD
711
(s) (s)
s + z1 s + p1 p1 z1
V1 p1 z 1 p1 1 1 p1
V2
p1 > z 1 K =
LEAD
(s) K (s + z 1 ) z 1 (s) 1 K = z1
V1 1 z1
V2 1 LEAD
R( s )
-
Gc ( s )
1 s .( s 1)
Y( s )
Find Let
Gc ( s )
3 j3
Gc ( s ) K 1)
Imag Axis
cl ( s ) 1
K.
1 s .( s
-1
}
-3 -2.5 -2 -1.5 -1 -0.5 0 0.5 1
3 j3
-2
-3 -3.5
Real A xis
If
Gc ( s ) K . K. b
(s (s (s (s
a) b)
b> a> 0
cl ( s ) 1
a) . 1 b ) s .( s 1 ) 1 a
Imag Axis
-3+j3 0 -3-j3
Centroid RD 2
0 2
3 j3
-b
-c
-a
Real Axis
Note: a closed loop pole at "-c" has been injected By moving "a" and "b" around we can change the centroid and hence bend the root locus to go through 3 j 3 Note:
3 j3
How do we find the values for a, b and K which ensure that are the closed-loop poles ?
3 j3
73
Y( s ) R( s )
K( s a ) s .( s b ) .( s 1 ) s a 1 K. ( s b ) .s .( s 1 )
( s) 1
K.
( s a) .( s b ) .( s s
=0
1)
j3
Angle K .
s .( s
( s a) b ) .( s
1)
j .3
= -180
} }
Angle Conditions
Angle
(s (s
a) . 1 .( s 1 ) b) s
3
=
j .3 180
= - 180
Let
a 3
Angle ( s
b)
1
s 3
j .3
Angle s .
(s (s
1) 3)
j .3
Note :
b A Angle B Angle (
tan
11.3 deg
=>
Angle ( A) j ) tan
1
Angle ( B )
Selection of "a" 1) "a" is not unique 2) If "a" is picked too big, "b" will not exist (i.e., b may become negative) 3) If "a" is picked too small, the system might not exhibit the right dominant behavior (i.e., closed loop pole at -c might dominate the behavior)
74
K.
(s
s 3 18 ) .( s ) .( s
1)
j .3 1
K.
15
j .3 j .3 . 3 j .3 . 2
j .3
K.
K 79 ( approximately)
answer
Gc ( s ) 79 .
75
R( s )
-
Gc ( s )
Gp ( s )
Y( s )
Find
Gc ( s ) 1 s .( s
3 j3
Gp ( s )
1)
Gc ( s ) K .
s s
a b
K .( s a ) Y( s ) s .( s b ) .( s 1 ) R( s ) ( s a) s .( s 1 K. ( s b ) .s .( s 1 ) cl ( s ) s .( s 1 ) .( s
K .( s a ) 1 ) .( s b ) K .( s
a)
closed loop TF
Note: There are three closed loop poles given by the characteristic equation
b)
K .( s
a)
j
Imag Axis
-3+j3 0 -3-j3
-b
-c
-a
Real Axis
cl ( s ) s
(b
1 ) .s
(b
K) .s 3
a .K j .3 )
} }
c ) .( s c) . s (6
2
j .3 ) .( s 18 ( 18
6 .s
2
}
6 c) s 18 c
simplification
c) s
76
dcl ( s ) cl ( s ) 6 18 c b 1 K
6c b
aK 18 c
}
18 K K 78
a 3
K 6c 5 c b b 6c c 13
}
}
1 0 1
0 1 1
6 1 6
K . b c
0 5 18
b 18
Note we have discovered the third closed loop pole in the process (i.e., s = - 13)
c b
b 6c
18
18 . c a
eliminate K and b
c 6 .c
18
18 . c a
18 a
13
simplified expression
From root locus, "c" must be a positive number for the problem to make sense so if
c> 0
then
18 a
5> 0
therefore
a<
18 5
Any other selection of "a" forces "b" to be negative, and hence, the compensator would have an unstable pole.
77
Find the Structure of the Time Response For the Previous Problem Quickly
Y( s ) R( s ) ( s y( t ) A
78 .( s 13 ) . ( s B .e
13 t
3) 3) C .e
2 3 t.
R( s ) ( 3)
2
1 s
where
r( t)
is a step input
cos ( 3 t )
D .e
3 t.
sin ( 3 t )
A, B,C, D can be found with the PFE tool How can we find A ?
lim sY ( s ) s 0 lim t y( t )
78 .( 3 ) 1 ( 13 ) .( 18 )
so
lim t A 1
y( t )
A 1
78
Example
r( t)
+ -
y( t ) P( s )
H( s )
H( s )
s 1 ( s 4 ) .( s 2 ) Y( s ) P( s ) R ( s ) 1 P ( s ) .H ( s ) K
P( s )
s 3 s 0.1
cl ( s ) 1
K .P ( s ) .H( s ) 1
K.
s 3 . s 0.1 ( s
s 1 2 ) .( s
4)
j .a c
Imag Axis
0.5
-0.5
-1
j .a
-4 -2 0 2 4
-1.5 -6
Use coefficient matching to find the value of K which places closed loop poles at
Real Axis
j.a
3 ) .( s 4s 4 .K .s ( 0.8 3 3 .K 3 .K) 1)
cl ( s ) ( s cl ( s ) ( s cl ( s ) s cl ( s ) s
3 3
2 ) .( s 6s 8.6 s
4) 8 0.8 ( 8.6
K .( s K. s Ks
2 2
K) s
4 .K) .s
Simplification
79
cl ( s ) s
( 6.1 c) . s cs
2
K) s
2 2
( 8.6
4 .K) .s
( 0.8
3 .K)
actual denominator
dcl ( s ) ( s dcl ( s ) s
3
2 2
}
a c
a s
simplified
K c
2 4 .K a
3 .K a c
2
3 equations 3 unknowns
After multiplying equation 1) by equation 2), and equating the result to equation 3), we obtain one equation for K
( 6.1 4K 4K
2
4 K) 0.8 24.4 ) .K
3K a c 3K
52.46 0.8
51.66 0
} }
simplified
(K
1.94 ) .( K
or
6.657 ) 0 K 6.657
factored
K 1.94
K 1.94
For
Imag Axis
0.5
-0.5
-1
-1.5 -6
-4
-2
Real Axis
80
Gc ( s )
4 s .( s 2)
Y( s )
Design
Gc ( s )
s s
2 2
j .2 3 j .2 3
Gc ( s ) K .
s s (s (s
a b
Lead Compensator
Y( s ) R( s )
K. 1
a) . 4 b ) s .( s 2 ) ( s a) . 4 K. ( s b ) s .( s 2 )
cl ( s ) 1
K.
s s
a . 4 .( s 2 ) b s
Imag Axis
j2 3
-b
-c
-a
j2 3
Real Axis
81
a 2.9 s 2.9 . s b (s
Angle
4 2 ) .( s )
180
j .2 . 3 4 .( s 2.9 ) s .( s 2 )
Angle ( s
b) s 2
j .2 3
180
Angle
j .2 3
tan
2 3 b 2
45
=>
b 5.46
Magnitude Condition
K.
s 2.9 . 4 s 5.46 s .( s 2 )
=>
K 4.68
j2 3
Y( s ) R( s )
(s (s
4 K (s b ) .( s 2 )
a) ( Ks
Ka ) 4
cl ( s ) s dcl ( s )
b ) .s
(2 b 2
4 K) .s
4 Ka
}
c)
2 (4
j .2 3 . s c) s
2
j .2 3 .( s 4 .c ) .s 16 .c
dcl ( s ) s
( 16
simplified
82
4 2 .b
c 2
b 4 .c
4 .K 16
16 .c 4 .K .a
Let
}
}
2 16 0
3 equations 4 unknowns
1 4 16 c b K
3 equations 3 unknowns
Imag Axis
j2 3
-b
-c
-a
j2 3
Real Axis
83
81
FREQUENCY-RESPONSE ANALYSIS
Advantages and disadvantages to root-locus design approach:
ADVANTAGES :
Good indicator of transient response. Explicitly shows location of closed-loop poles. Tradeoffs are clear.
DISADVANTAGES :
Requires transfer function of plant be known. Difcult to infer all performance values. Hard to extract steady-state response (sinusoidal inputs). Frequency-response methods can be used to supplement root locus: Can infer performance and stability from same plot. Can use measured data when no model is available. Design process is independent of system order (# poles). Time delays handled correctly (es ). Graphical techniques (analysis/synthesis) are quite simple. Frequency Response We want to know how a linear system responds to sinusoidal input, in steady state.
Lecture notes prepared by Dr. Gregory L. Plett
82
Consider system
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 + ), = 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)
Lecture notes prepared by Dr. Gregory L. Plett
= tan1
(0) (0)
83
= tan1
FORESHADOWING :
Transfer function along j-axis tells us response to a sinusoid...but also tells us about stability since j-axis is stability boundary! Plotting a Frequency Response There are two common ways to plot a frequency response the magnitude and phase for all frequencies.
EXAMPLE:
R U (s) C Y (s)
G(s) =
1 1 + RCs
We will need to separate magnitude and phase information from rational polynomials in j. Magnitude = magnitude of numerator / magnitude of denominator (num)2 + (num)2 (den)2
Lecture notes prepared by Dr. Gregory L. Plett
(den)2
84
Phase = phase of numerator phase of denominator (num) (den) tan1 tan1 . (num) (den) Plot Method #1: Polar Plot in s -plane. Evaluate G( j) at each frequency for 0 < . Result will be a complex number at each frequency: a + jb or Ae j . Plot each point on the complex plane at (a + jb) or Ae j for each frequency-response value. Result = polar plot. We will later call this a Nyquist plot. 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
The polar plot is parametric in , so it is hard to read the frequency-response for a specic frequency from the plot. We will see later that the polar plot will help us determine stability properties of the plant and closed-loop system.
Lecture notes prepared by Dr. Gregory L. Plett
85
|G( j)|
G( j)
1 2 3 4 5 6
30 40 50 60 70 80
0.6
0.4
0.2
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
The polynomial factors that contribute to the transfer function can be split up and evaluated separately. (s + 1) G(s) = (s/10 + 1) ( j + 1) G( j) = ( j/10 + 1)
Lecture notes prepared by Dr. Gregory L. Plett
86
|G( j)| =
| j + 1| | j/10 + 1| 1+ 2 log10
2
log10 |G( j)| = log10 Consider: log10 For n , log10 For n , log10
KEY POINT:
2 1+ . 10
1+ n
2
1+ n 1+ n
log10(1) = 0.
log10
. n
Exact 0.1n n
Approximation 10n
A transfer function is made up of rst-order zeros and poles, complex zeros and poles, constant gains and delays. We will see how to make straight-line (magnitude- and phase-plot) approximations for all these, and combine them to form the appropriate Bode diagram.
Lecture notes prepared by Dr. Gregory L. Plett
87
Bode-Magnitude Diagrams
0.1
1 |K | < 1
10
For a zero at the origin, G(s) = s dB = 20 log10 |G( j)| = 20 log10 | j| dB.
20 dB
For a pole at the origin, 1 G(s) = s dB = 20 log10 |G( j)| = 20 log10 | j| dB.
20 dB
Both are straight lines, slope = 20 dB per decade of frequency. Line intersects -axis at = 1.
88
For an nth-order pole or zero at the origin, dB = 20 log10 |( j)n | = 20 log10 n = 20n log10 . Still straight lines. Still intersect -axis at = 1. But, slope = 20n dB per decade.
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
Lecture notes prepared by Dr. Gregory L. Plett
n 1+ n
2
89
For For
n , n ,
20 log10 20 log10
1+ n 1+ n
20 log10 1 = 0. 20 log10 . n
Two straight lines on a log scale which intersect at = n . For a pole on the real axis, (LHP or RHP) standard Bode form is G(s) = s 1 n
1
20 log10 |G( j)| = 20 log10 This is the same except for a minus sign.
0.1n 20 dB 20 dB per decade 0.1n 1n 10n 20 dB
1+ n
1n
10n
20 dB per decade
s n
+ 1,
810
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
2 n
s n
s n
+1 .
For = 1, there will be overshoot or undershoot at n . At = n , magnitude value = 20 log10 2 dB. We write complex poles (LHP or RHP) as G(s) = s n
2 1
s n
+1
20 dB
0 dB
0 dB
20 dB
20 dB
Bode Mag: Complex poles = 0.05 0.1 0.2 0.3 0.5 0.7 = 0.9
n 10n
0.1n
40 dB
0.1n
811
G( j) = j Components:
2
j 10
j 0.5
+1
j 50
+1
+1
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
1 0 1 2 3
10
10
10
10
10
b) d ) .( s e)
a ,b ,c ,d ,e
are
ab . H( s ) K . ecd
j 1 . b j 1 . d
1 j 1 . e 1
Bode Form
Magnitude Plot 1) Curve breaks { up / down } by 20 dB/dec at { a,b / c,d,e} Angle Plot 2) Curve breaks { up / down } by 45 degrees one decade before { a,b / c,d,e } and breaks { down / up } by 45 degrees one decade after { a,b / c,d,e } Initial Magnitude Plot Case 1: n=0 Calculate
H( j )
20 .log( H( j ) )
20 .n
intercept
dB / dec dB / dec
Kab cde
1 n
95
Initial and Final Phase Plot 1) Plot a pole / zero plot for the original transfer function 2) Calculate the angle from the picture at
Illustrative Example
Angle
s s
a c ( Angle ( j a) Angle ( j c) ) 0
= 0 degrees
Initial Angle =
Final Angle =
( Angle ( j
a)
Angle ( j
c) )
= 90 - 90 = 0 degrees
1 0.8 0.6
Imag Axis
0.4 0.2 0
Real Axis
96
s 1 H( s ) s 10
Magnitude Plot 1) Initial Magnitude => n = 0 =>
H( j )
1 . j 10 1 j 10
=
}
1 1 10
Bode Form
H( j ) 20 dB
Initial Magnitude =
20 .log
1 10
dB Conversion
2) Plot the negative of the poles and the zeros on the j axis zero at -1 3) pole at -10
Use an "up" arrow to denote a slope of +20 dB/dec and a "down" arrow to denote a slope of -20 dB/dec
RD 0 H( j )
101 100 101 102
Final Slope = 0 dB / dec
dB
-20 -40 Initial Magnitude Decade
4) Start at the initial magnitude and use arrows to draw the asymptotic plot
H( j ) dB
-20
101
100
101
102
+ 20 dB/dec -40
97
Phase Plot
for
s 1 H( s ) s 10
H( j )
1 . j 10 1 j 10 1
Bode Form
1 0.8 0.6
Imag Axis
0.4 0.2 0
10
}
0
-10
-8
-6
-4
-2
Real Axis
1) Initial Phase
Angle ( H( j ) )
0
Note :
Angle
j 1
Angle
j 10
= 0-0=0
see picture
Final Angle
Angle ( H( j ) )
Angle
j 1
Angle
j 10
Note :
= 90 - 90 = 0
see picture
98
2) Plot the negative of the poles and the zeros on the j axis zero at -1 pole at -10
3) Use an "up" arrow to denote a slope of +45 deg/dec and a "down" arrow to denote a slope of - 45 deg/dec
Angle ( H( j) ) deg
90 Decade
45
Initial Phase
Final Phase
10 1
4)
10 0
101
10 2
Frequency (rad/sec) Start at the initial phase and use arrows to draw the asymptotic plot
Angle ( H( j) ) deg
90 Initial Phase 45
45 deg/dec
D ecade
F inal P hase
- 45 deg/dec
10 1
10 0
10 1
10 2
F requency (rad/sec)
Use the Asymptotic Plots to draw the actual Bode Plot free hand (rough out the edges)
B o d e D i a g ra m s 0 -5 Phase (deg); Magnitude (dB) -1 0 -1 5 -2 0
50 40 30 20 10 10
-1
10
10
10
F re q u e n c y (ra d /s e c )
99
H( s )
10 ( s 10 ) s ( s 1 ) ( s 100 ) j 1 j 100 1
10 ( 10 ) . H( j ) 100
10 j j 1 1
}
}
Bode Form
Magnitude Plot 1) Initial Magnitude => n = 1 => Calculate the intercept 1 n 10 ( 10 ) 0 I 1 10 n 1 100
n 1
100
2) Plot the negative of the poles and the zeros on the j axis zero at -10 3) poles at 0 , -1 and -100
Use an "up" arrow to denote a slope of +20 dB/dec and a "down" arrow to denote a slope of -20 dB/dec
H( j )
20 0
dB
-20 -40 -60
}
102
I
100
101
Frequency (rad/sec)
4) Use the initial slope and the arrows to draw the asymptotic plot
H( j )
20
dB 0
-20 dB/dec -20 -40 -60 -20 dB/dec -40 dB/dec -40 dB/dec
100
101
10
101
Phase Plot
for
H (s) =
10 ( s 10 ) s ( s 1 ) ( s 100 ) j 1 j 100 1
H (s) =
10 ( 10 ) 100
10 j j 1 1
} }
Bode Form
1 0 .8 0 .6
Imag Axis
0 .4 0 .2 0
-0 .2 -0 .4 -0 .6 -0 .8 -1
100
10
R e a l A x is
1) Initial Phase
Angle ( H( j ) )
10 = 0 90 0 0
Angle
= 90
Final Angle
Angle ( H( j ) ) j 10
Angle
= 90 90 90 90 = 180
102
2) Plot the negative of the poles and the zeros on the j axis zero at -10 poles at 0 , -1 and -100
3) Use an "up" arrow to denote a slope of +45 deg/dec and a "down" arrow to denote a slope of - 45 deg/dec
Angle ( H( j ) )
10 1
90 0
10 0
10 1
10 2
10 3
deg
-90 -180
Initial Phase
-270
Decade
Final Phase
4)
Start at the initial phase and use arrows to draw the asymptotic plot
Angle ( H( j ) )
-45 -90 Initial Phase Final Phase - 45 deg/dec -180 -225 - 45 deg/dec
deg
-135
10 1
10 0
101
10 2
10 3
Frequency (rad/sec)
103
Use the Asymptotic Plots to draw the actual Bode Plot free hand (rough out the edges)
Bode Diagrams
-50
-100
10
10
10
10
10
10
Frequency (rad/sec)
1 s n
2
H (s) =
1 n
2
1 j n 1 j n 1
}
dB
Bode Form
Magnitude Plot
1
1) Initial Magnitude => n = 0 => Calculate initial magnitude
H( j )
Initial Magnitude =
20 .log
1 n
2
dB Conversion
104
2) Plot the negative of the poles on the j axis 2 poles at - n 3) Use an "up" arrow to deonte a slope of +20 dB/dec and a "down" arrow to denote a slope of -20 dB/dec
H ( j )
20 0
dB
n /10
10n
100n
105
Phase Plot
for
H (s) =
1 s n 1 n
2 2
H (s) =
1 j n 1 j n 1
} }
Bode Form
1 0.8 0.6
Imag Axis
0.4 0.2 0
Real Axis
1) Initial Phase
Angle ( H( j ) )
Angle
j n
Angle
j n
1 0
= 0 0 = 0
Final Angle
Angle ( H( j ) )
Angle
j n
Angle
j n
= 90 90 = 180
106
2) Plot the negative of the poles and the zeros on the j axis 2 poles at -n 3) Use an "up" arrow to denote a slope of +45 deg/dec and a "down" arrow to denote a slope of - 45 deg/dec
Angle ( H( j ) )
n 10
90
10 n
100 n
deg 0
-90 -180 -270
Final Phase Initial Phase
4)
Start at the initial phase and use arrows to draw the asymptotic plot
n
90 0 -90 -180 -270
10
10n
100n
107
Use the Asymptotic Plots to draw the actual Bode Plot free hand (rough out the edges) In the following plot
n 1
Bode Diagrams
10
10
Frequency (rad/sec)
108
817
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 G 2(s) = 10 s+1 s + 10 s1 s + 10 zero at 1 pole at 10 zero at + 1 pole at 10 minimum phase nonminimum phase
The magnitude responses of these two systems are: 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)) Bode-Magnitude Plot |G 1 ( j)|, |G 2 ( j)|
20 15 180 150 120 90 60 30 0 2 10
10
0 10
2
10
10
10
10
10
10
10
10
10
Note that the change in phase of G 1 is much smaller than change of phase in G 2. Hence G 1 is minimum phase and G 2 is nonminimum-phase
Lecture notes prepared by Dr. Gregory L. Plett
Frequency, (rads/sec.)
Frequency, (rads/sec.)
818
Non-minimum phase usually associated with delay. s1 G 2(s) = G 1(s) s+1 Delay Note: s1 is very similar to a rst-order Pad approximation to a s+1 delay. It is the same when evaluated at s = j.
Consider using feedback to control a nonminimum-phase system. What do the root-locus plotting techniques tell us? Steady-State Errors from Bode-Magnitude Plot Recall our discussion of steady-state errors to step/ramp/parabolic inputs versus system type (summarized on pg. 4417) Consider a unity-feedback system. If the open-loop plant transfer function has N poles at s = 0 then the system is type N K p is error constant for type 0. K v is error constant for type 1. K a is error constant for type 2... For a unity-feedback system, K p = lim G(s).
s0
At low frequency, a type 0 system will have G(s) K p . We can read this off the Bode-magnitude plot directly! Horizontal y-intercept at low freqency = K p . 1 ess = for step input. 1 + Kp
Lecture notes prepared by Dr. Gregory L. Plett
819
At low frequency, a type 1 system will have G(s) At low frequency, |G( j)|
Kv . s
Kv . Slope of 20 dB/decade. Use the above approximation to extend the low-frequency asymptote to = 1. The asymptote (NOT THE ORIGINAL |G( j)|) evaluated at = 1 is K v . 1 ess = for ramp input. Kv K a = lim s 2 G(s), and is nonzero for a type 2 system.
s0
At low frequency, a type 2 system will have G(s) At low frequency, |G( j)|
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 Similar for higher-order systems.
20 10
Example 1 Magnitude
60 50 40 30 20 10 0 2 10
Example 2
Magnitude
0 10 20 30 40 2 10
10
10
10
10
10
10
Frequency, (rads/sec.)
Frequency, (rads/sec.)
820
EXAMPLE
1:
2:
Slope = -20 dB/decade as 0, so we know this is type 1. Extend slope at low frequency to = 1. Intercept=20 dB. . . K v = 20 dB = 10 [linear units]. Stability Revisited If we know the closed-loop transfer function of a system in rationalpolynomial form, we can use Routh to nd stable ranges for K . Motivation: What if we only have open-loop frequency response?
A Simple Example
Consider, for now, that we know the transfer-function of the system, and can plot the root-locus.
EXAMPLE :
We see neutral stability at K = 2. The system is stable for K < 2 and unstable for K > 2.
Lecture notes prepared by Dr. Gregory L. Plett
821
Recall that a point is on the root locus if |K G(s)| = 1 and G(s) = 180. If system is neutrally stable, j-axis will have a point (points) where |K G( j)| = 1 and G( j) = 180. Consider the Bode plot of K G(s). . . A neutral-stability condition from Bode plot is: |K G( jo)| = 1 AND K G( jo) = 180 at the same frequency o . In this case, increasing K instability |K G( j)| < 1 at K G( j) = 180 =stability. In some cases, decreasing K instability |K G( j)| > 1 at K G( j) = 180 =stability.
KEY POINT:
40 20 0 20 40 60 80 2 10
K = 0.1 K =2 K = 10
10
1
10
10
10
10
10
We can nd neutral stability point on Bode plot, but dont (yet) have a way of determining if the system is stable or not. Nyquist found a frequency-domain method to do so.
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:
Lecture notes prepared by Dr. Gregory L. Plett
822
First, nd a way to count closed-loop poles inside a contour. Second, make the contour equal to the RHP. Counting is related to complex functional mapping.
F (s)
?
s
(F)
823
EXAMPLE:
1 C
EXAMPLE:
1 j B
(s)
s . s +2
1 C
FORESHADOWING :
1 j B
F ( A) F (B)1 j F(C)
(s)
By drawing maps of a specic contour, using a mapping function related to the plant open-loop frequency-response, we will be able to determine closed-loop stability of systems.
(zeros)
(poles).
824
EXAMPLE :
(s) c1 (s)
F(c1)
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) c2 (s)
F(c2)
One pole inside contour. Resulting map undergoes 360 net phase change. (Encircles the origin).
EXAMPLE :
(s) c3 (s)
F (c3)
825
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)
For closed-loop stability, no poles of T (s) in RHP. No zeros of 1 + D(s)G(s)H (s) in RHP. Let F(s) = 1 + D(s)G(s)H (s). Count zeros in RHP using Cauchy theorem! (Contour=entire RHP).
The Nyquist criterion simplies Cauchys criterion for feedback systems of the above form.
Lecture notes prepared by Dr. Gregory L. Plett
826
(s)
(s)
Simple? YES!!! Think of Nyquist path as four parts: I. Origin. Sometimes a special case (later examples). II. + j-axis. FREQUENCY-response of O.L. system! Just plot it as a polar plot. III. For physical systems=0. IV. Complex conjugate of II. So, for most physical systems, the Nyquist plot, used to determine CLOSED-LOOP stability, is merely a polar plot of LOOP frequency response D( j)G( j)H ( j). We dont even need a mathematical model of the system. Measured data of G( j) combined with our known D( j) and H ( j) are enough to determine closed-loop stability.
Lecture notes prepared by Dr. Gregory L. Plett
Y( s ) K Gp ( s )
Y( s ) R( s ) ( s)
KGp ( s ) 1
=
KGp ( s ) 1 KGp ( s )
Closed loop TF
Im K .Gp ( j )
versus
Re K .Gp ( j )
using the Nyquist contour. (Assume K = 1) 2) Apply the Nyquist Criterion to the Nyquist Plot and then determine the stability of the closed-loop system.
Nyquist Criterion P0
denotes the number of poles of
Gp ( s )
1 180
If the contour in the s-plane is CW, then CW is the positive direction. i.e., 1 CW
N =1 N =1
1 CCW
N =1 N =1
If the contour in the s-plane is CCW, then CCW is the positive direction. i.e., 1 CCW 1 CW
Zc
Zc N
P0
122
Example
Draw the Nyquist Plot for for the following s-plane contour. Step 1) Let
Im {s}
H( s )
1 s 1 1
Nyquist Contour
s j
H( j . )
j .
1
R
R Re{s}
Step 2) Plot a pole/zero plot for H(s) on the s-plane contour picture and include measurement scheme to the j - axis along with the necessary critical points.
Step 3) Enter a magnitude/phase table entry for each critical point. Point r mag Phase
Im {s}
A B C H ( j )
1 0 0 1 j
0 90 0 r 1 1 1)
-1 A C Re{s}
Angle( H ( j ) )
Angle( j
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half.
Im{H(j )}
B,C
A r Re{H(j )}
123
Example
Draw the Nyquist Plot for for the following s-plane contour. Step 1) Let
H( s ) 1 j ( j .
1 s( s 1)
Im{s}
Nyquist Contour
s j H( j . )
1)
R
0
R Re{s}
Step 2) Plot a pole/zero plot for H(s) on the s-plane contour picture and include measurement scheme to the along with the necessary critical points. Step 3) Enter a magnitude/phase table entry for each critical point. Point r mag Phase
axis
Im{s}
A B C D H ( j )
0 0
0 90 180 0 1 j . j 1 Angle( j 1)
Im{H(j)}
B
"Blow-up"
Im {s} B 90
o
A -1
D Re{s}
A Re{s}
Angle( H ( j ) )
Angle( j )
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half.
-1
C,D
A r Re{H(j)}
r=
124
Y( s ) K Gp ( s ) Gp ( s ) s .( s
1 1 ) .( s
10 )
Im{s}
Use Nyquist Plot, Contour and Criterion to discuss quantitatively how the control gain K affects closed-loop stability.
Nyquist Contour
K .Gp ( s ) Y( s ) R ( s ) 1 K .Gp ( s ) K.
( s) 1
s .( s
1 1 ) .( s
10 )
Nyquist Form
R 0
Re{s}
Step 1) Let
s j
K .Gp ( j ) Gp ( s )
K 1 ) .( j
axis
10 )
Assume K = 1
picture and include measurement scheme to the along with the necessary critical points. Step 3) Enter a magnitude/phase table entry for each critical point.
Im{s}
r
point mag
phase
A B C D
0 0
0 90 270 0 1 j . j 1 . j 10
"Blow-up"
Im {s} B 90
o
B A -10 -1
D Re{s}
A Re{s}
Gp ( j )
Angle Gp ( j )
Angle( j )
Angle( j
1)
Angle( j
10 )
125
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half. point
r
mag
phase
A B
Im{Gp(j )}
0 0
0 90 270 0
C D
C,D
A r Re{Gp(j )}
r=
Im{KGp(j)}
-1
C,D
A r Re{KGp(j)}
r=
Larger K B
As K is increased, the shape of the Nyquist plot does not change because K is a real number (i.e., K only affects the magnitude (size); K does NOT affect the phase (shape))
126
Im{KGp(j)}
Im {s}
-1
C,D
A r Re{KGp(j)}
-10
-1
Re{s}
r=
Nyquist Criterion
1) Find
P0
=>
P0 0
( Number of poles of
Gp ( s )
2) Determine the sign notation for the encirclements. Contour is CW so, CW encirclements are positive and CCW encirclements are negative
3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc N
Zc N Zc 0 2
P0
Stability Yes No
small K big K
0 2
4) Understanding the above table: For small K, no closed loop poles are inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is stable For big K, two closed loop poles are inside the s-plane contour; hence, for big K, the closed loop system is unstable
127
15
10
Gp ( s )
s .( s
1 1 ) .( s
10 )
Imag Axis
}
-12 -10 -8 -6 -4 -2 0 2 4
( s) 1
K .Gp ( s )
-5
-10
small K: closed loop system is stable big K: closed loop system is unstable
-15
Real Axis
N
small K big K
Zc 0 2
Stability Yes No
0 2
128
Im{s}
Y( s ) K H( s )
Nyquist Contour
Re{s}
Use Nyquist Plot, Contour and Criterion to discuss quantitatively how the control gain K affects closed-loop stability.
H( s )
s s
1 1
We can see from the root locus that the system goes unstable
Y( s ) K .H ( s ) R ( s ) 1 K .H ( s ) ( s) 1
Step 1) Let
K.
s s
1 1
Nyquist Form
Imag Axis
s j
Assume K=1
K .( j 1 ) K .H ( s ) ( j 1 )
H ( s)
Real Axis
axis
Im {s}
r
point mag
phase
Nyquist Contour
A B C
1 1 1
180
A C 1 Re{s}
0 0
-1
H ( j )
j j
1 1
Angle( H ( j ) ) Angle( j
1)
Angle( j
1)
130
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half.
r
point mag
phase
Im{H(j)}
A B K 1
1 1 1
180 0 0
A -1
B,C r Re{H(j)}
Im{s}
Nyquist Contour
A -1 1
CW + CCW -
C Re{s}
As K is decreased below 1, the Nyquist Plot intersects the Re{j } axis before -1 As K is increased beyond 1, the Nyquist Plot intersects the Re{j } axis beyond -1
Nyquist Criterion
1) Find
P0
=>
P0 0
( Number of poles of
H ( s)
2) Determine the sign notation for the encirclements. Contour is CW so, CW encirclements are positive and CCW encirclements are negative 3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc N
Zc N Zc 0 1
P0
Stability Yes No
small K big K
0 1
4) Understanding the above table: For small K, no closed loop pole is inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is stable For big K, one closed loop pole is inside the s-plane contour; hence, for big K, the closed loop system is unstable
131
Y( s ) K H( s )
Im {s}
Nyquist Contour
Use Nyquist Plot, Contour and Criterion to discuss quantitatively how the control gain K affects H( s ) closed-loop stability. Step 1) Let
Re{s}
s s
1 1
s j K .( j ( j 1) 1)
K .H ( s )
} K=1
H ( s)
Assume
axis
r
point mag
phase
Im {s}
Nyquist Contour
A B C
1 1 1
180 0 0
C -1 A 1
Re{s}
H ( j )
j j
1 1 1) Angle( j 1)
Angle( H ( j ) ) Angle( j
132
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half. point
r
mag
phase
Im{H(j)}
A B K 1 C
1 1 1
180 0 0
A -1
B,C r Re{H(j)}
CW CCW +
Im {s}
Nyquist Contour
As K is decreased below 1, the Nyquist Plot intersects the Re{j } axis before -1 As K is increased beyond 1, the Nyquist Plot intersects the Re{j } axis beyond -1
-1
Re{s}
Nyquist Criterion
1) Find
P0
=>
P0 1
( Number of poles of
H ( s)
2) Determine the sign notation for the encirclements. Contour is CCW so, CW encirclements are negative and CCW encirclements are positive 3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc N
Zc N Zc 1 1 0
P0
Stability Yes No
small K big K
4) Understanding the above table: For small K, one closed loop pole is inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is stable For big K, no closed loop pole is inside the s-plane contour; hence, for big K, the closed loop system is unstable
133
Im{s}
Y( s ) K H( s )
Nyquist Contour
R 0
Re{s}
Use Nyquist Plot, Contour and Criterion to discuss quantitatively how the control gain K affects closed-loop stability.
H( s )
s .( s
1 1 ) .( s
2)
Y( s ) K .H ( s ) R ( s ) 1 K .H ( s ) ( s) 1 K. 1 s .( s
1 ) .( s
2) ( j ) .( j
}
K
Step 1) Let
s j
K .H ( s )
1 ) .( j
2)
} K=1
Assume
H ( s)
picture and include measurement scheme to the Step 3) Enter a magnitude/phase table entry for each critical point.
axis
Im{s}
r
point mag
Nyquist Contour
phase
A B C D
0 0
0 90 270 0
"Blow-up"
Im {s} B 90
o
B A -2 -1
D Re{s}
A Re{s}
H ( j )
1 j . j 1 . j 2 1) Angle( j 2)
Angle( H ( j ) )
Angle( j ) Angle( j
134
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half. point
r
mag
phase
Im{Gp(j)}
K 1
A B C
0 0
0 90 270 0
-1
C,D
A r Re{Gp(j)}
r=
Im{s}
CW + CCW -
Nyquist Contour
B
-2 -1
B A
D Re{s}
Nyquist Criterion
1) Find
P0
=>
P0 0
( Number of poles of
H ( s)
2) Determine the sign notation for the encirclements. Contour is CW so, CW encirclements are positive and CCW encirclements are negative 3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc N
Zc N Zc 0 2
P0
Stability Yes No
small K big K
0 2
4) Understanding the above table: For small K, no closed loop pole is inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is stable For big K, two closed loop poles are inside the s-plane contour; hence, for big K, the closed loop system is unstable
135
Im {s}
Y( s ) K H( s )
R
Nyquist Contour
Re{s}
Use Nyquist Plot, Contour and Criterion to discuss quantitatively how the control gain K affects closed-loop stability. H( s ) Step 1) Let
s j K ( j ) .( j 1 ) .( j 2)
s .( s
1 1 ) .( s
R 0
2)
K .H ( s )
} K=1
Assume
H ( s)
axis
Im {s}
Step 3) Enter a magnitude/phase table entry for each critical point.
r
point mag
phase
Nyquist Contour
B D -2 -1 A Re{s}
A B C D
0 0
0 90 270 540 1
"Blow-up"
Im {s} B 90
o
A Re{s}
H ( j )
j . j
1 . j
2 1) Angle( j 2)
Angle( H ( j ) )
Angle( j ) Angle( j
136
Step 4) Use critical points to draw Nyquist Plot. Step 5) Nyquist plot is symmetric about real axis. Draw other half. point
r
mag
phase
Im{Gp(j)}
K 1
A B C
0 0
0 90 270 540
-1
C,D
A r Re{Gp(j)}
CW CCW +
D
Im {s}
r=
Nyquist Contour
-2 -1
Re{s}
Nyquist Criterion
1) Find
P0
=>
P0 3
( Number of poles of
H ( s)
2) Determine the sign notation for the encirclements. Contour is CCW so, CW encirclements are negative and CCW encirclements are positive 3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc N
Zc N Zc 3 2 1
P0
Stability Yes No
small K big K
4) Understanding the above table: For small K, all three closed loop poles are inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is stable For big K, only one closed loop pole is inside the s-plane contour; hence, for big K, the closed loop system is unstable
137
R( s )
B
Y( s ) K H ( s) (s
2 s .( s
Im{s}
H( s )
Im{H(j)}
2 ) .( s 1 ) .( s
4) 3 ) .( s 5)
K 1
-b -1 -1/a
Nyquist Contour
Re{H(j)}
R 0
Re{s}
r=
5
Stable region
4 3
Imag Axis
2 1 0
This is how you might be tempted to draw the root locus without the Nyquist plot Does the Nyquist Plot concur ? 1) Find
-1 -2 -3 -4 -5 -7 -6 -5 -4 -3 -2 -1 0 1 2
P0
P0 0
Real Axis
2) Determine the sign notation for the encirclements. Contour is CW so, CW encirclements are positive and CCW encirclements are negative 3) Find N (i.e., the number of encirclements of (-1,0) for different values of K Also compute
Zc Zc 2 0 2
Zc N
Stability No Yes No
P0
N
small K medium K big K
2 0 2
=>
138
N
small K medium K big K
Zc 2 0 2
Stability No Yes No
2 0 2
4) Understanding the above table: For small K, two closed loop poles are inside the s-plane contour. From the contour, we can see that this means that for small K the closed loop system is unstable For medium K, no closed loop poles are inside the s-plane contour. From the contour, we can see that this means that for medium K the closed loop system is stable For big K, two closed loop poles are inside the s-plane contour; hence, for big K, the closed loop system is unstable The above table assists in the Root Locus sketch
5 4 3
* K2
}
} small K
large K
Imag Axis
2 1 0 medium K
{
K
* 1
-1 -2 -3 -4 -5 -7 -6 -5 -4 -3 -2 -1
Real Axis
From the above root locus, we can conclude that the system is stable for
* K1* < K < K 2
K1* =
1 b
and
* K2 = a
-b -1
-1 /a
139
833
The distance between the current (stable) system and an unstable system is called a stability margin. Can have a gain margin and a phase margin.
GAIN MARGIN :
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). If we increase gain, Nyquist map stretches and we may encircle 1. For a stable system, GM > 1 (linear units) or GM > 0 dB.
PHASE MARGIN :
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.
Lecture notes prepared by Dr. Gregory L. Plett
834
If we increase open-loop delay, Nyquist map rotates and we may encircle 1. For a stable system, PM > 0. This is usually easiest to check on Bode plot, even though derived on Nyquist plot! Dene gain crossover as frequency where Bode magnitude is 0 dB. Dene phase crossover as frequency where Bode phase is 180.
30
IRONY:
GM = 1/(Bode gain at phase-crossover frequency) if Bode gain is measured in linear units. GM = ( Bode gain at phase-crossover frequency) [dB] if Bode gain measured in dB. PM = Bode phase at gain-crossover (180).
20
Magnitude
10 0 10 20 30 2 10
1 0 1 2
10
10
10
10
Frequency, (rads/sec.)
90 120
Phase
10
10
10
10
We can also determine stability as K changes. Instead of dening gain crossover where |G( j)| = 1, use the frequency where |K G( j)| = 1. You need to be careful using this test. It works if you apply it blindly and the system is minimum-phase.
Lecture notes prepared by Dr. Gregory L. Plett
Frequency, (rads/sec.)
835
You need to think harder if the system is nonminimum-phase. Nyquist is the safest bet. PM and Performance A bonus of computing PM from the open-loop frequency response graph is that it can help us predict closed-loop performance of the system. PM is related to damping. Consider open-loop 2nd -order system 2 n G(s) = s(s + 2 n ) with unity feedback,
2 n T (s) = 2 . 2 s + 2 n + n
The relationship between PM and is: (for this system) PM = tan1 For PM 60, 2 1 + 4 4 2 2
1 0.9
Damping ratio
0.8
0.6
0.4
0.2
0 10
0 0
10
20
30
40
50
60
70
80
Phase margin
Lecture notes prepared by Dr. Gregory L. Plett
Phase margin
836
Bodes Gain-Phase Relationship For any stable minimum-phase system (that is, one with no RHP zeros or poles), the phase of G( j) is uniquely related to the magnitude of G( j) 1 dM Relationship: G( jo) = W (u) du (in radians) du M = ln |G( j)| u = ln o
dM slope n of log-mag curve at = o du W (u) = weighting function = ln(coth |u|/2) W (u) (u). Using this re2 lationship, G( j) n 90 if slope of Bode magnitudeplot is constant in the decadeneighborhood of .
2
4 3.5 3
W (u)
Normalized freq. u
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:
Closed-Loop Frequency Response Most of the notes in this section have used the open-loop frequency response to predict closed-loop behavior.
Lecture notes prepared by Dr. Gregory L. Plett
837
How about closed-loop frequency response? K D(s)G(s) T (s) = . 1 + K D(s)G(s) General approximations are simple to make. If, |K D( j)G( j)| 1 for and |K D( j)G( j)| 1 for c c
where c is the cutoff frequency where open-loop magnitude response crosses magnitude=1. |T ( j)| = K D( j)G( j) 1 + K D( j)G( j) 1, |K D( j)G( j)|, c ; c .
Note: c bw 2c .
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
PD controller increases phase for frequencies over 0.1/TD . So, locate 1/TD < crossover so that phase margin at crossover is better. Problem: Magnitude response continues to increase as frequency increases. This amplies high-frequency sensor noise. Lead Compensation Compensator D(s) = K Ts + 1 , T s + 1 < 1. 1 . T
The phase contributed at frequency is = tan1 (T ) tan1 (T ) . The maximum phase is max = sin1 1 1+ at max =
1 . T
93
1 1 We can show that max occurs mid-way between and on a log T T scale log(max) = log T = 1 1 log 2 T
1 T
1 = log T + log
90 80 70
1 + log T .
1 T
60
max
50 40 30 20 10 0 0 10 10
1
10
1/
If we need more phase improvement, we can use a double-lead compensator: Ts + 1 2 D(s) = K . T s + 1 Need to compromise between good phase margin and good sensor noise rejection at high frequency.
94
Compute steady-state error of compensated system. Set equal to desired steady-state error by computing K . Evaluate the PM of the uncompensated system using the value of K from above. max initially set to crossover frequency. Add a small amount of PM (5 to 12) to the needed phase lead. (Lead network moves crossover point, so need to design conservatively): Gives max. 1 sin(max) Determine = . 1 + sin(max) 1 Determine T = . max Iterate if necessary (choose a slightly different max or max).
EXAMPLE :
Plant G(s) =
1 s(s + 1)
Want steady-state error for ramp input < 0.1, Want overshoot M p < 25%. Steady-state error ess = lim s
s0
= lim D(s) = K
s0
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.
Lecture notes prepared by Dr. Gregory L. Plett
95
Evaluating Bode diagrams of |K G(s)| at crossover, we see we have a phase margin of 18. Need about 27 more to meet spec. Note, addition of pole and zero from lead network will shift crossover frequency somewhat. To be safe, design for added phase of 37 instead of 27. 1 sin(37) 1 = = 0.25. T = = 0.667 1 + sin(37) 0.25(3) D(s) = 10
60 50 40 30 20 10 0 10 20 30 40 2 10 10
1
2s/3 + 1 . 2s/12 + 1
1.5 1
Magnitude
Imag Axis
0 1 2
10
10
10
(rad/sec)
90 100 6 4
Real Axis
Imag Axis
1 0 1 2
110
Phase
2 0 2 4 6 7 6 5 4 3 2 1 0 1 2
(rad/sec)
Real Axis
96
Step Response
1.2 1 0.8 0.6 0.4 0.2 0 0 3 2.5
Ramp Response
Amplitude
Amplitude
0.5 1 1.5 2 2.5
2 1.5 1 0.5 0 0
0.5
1.5
2.5
Time (sec.)
Time (sec.)
Summary of design example. 1. Determine dc-gain so that steady-state errors meet spec. 2. Select and T to achieve an acceptable PM at crossover.
97
+1 +1 1 +1 = K +1 K = .
Open-loop gain at c is designed to be 1: |D( jc )||G( jc )| = 1 K |G( jc )| = 1 K = . KG Our design is now complete. Desired gain crossover frequency of 10 radians per second. 1 Desired PM of 60. G(s) = . s(s + 1) 1 KG = = 0.01, G = 174.3. j10( j10 + 1) max = 60 + 174.3 180 = 54.3. 1 sin(max) = = 0.1037. 1 + sin(max)
Lecture notes prepared by Dr. Gregory L. Plett
EXAMPLE :
98
Matlab results:
99
Phaselead design (uncompensated=dashed; compensated=solid) Magnitude (dB) 40 20 0 20 40 60 0.01 90 Phase 120 150 180 0.01 0.1 1 Frequency/wc (i.e., "1"=wc) 10 0.1 1 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
TI 10TI
0.1TI 10K
90 TI 10TI
910
Innite gain at zero frequency Reduces steady-state error to step, ramp, etc. But also has integrator anti-windup problems. Adds phase below breakpoint. We want to kep breakpoint frequency very low to keep from destabilizing system. 1 c . TI Lag Compensation Approximates PI, but without integrator overow. Ts + 1 > 1. D(s) = T s + 1 Primary objective of lag is to add 20 log10 dB gain to low frequencies without changing PM. 1 1
T T
90 1 T 1 T
911
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
1. Set K = 4.5 for PM = 30. This gives crossover at c 1.2 rads/sec. 2. Low-frequency gain now = 4.5. 3. Should be raised by a factor of 2 to get K p = 9. So, = 2. 1 4. Choose corner frequency at = 0.2 rads/sec. = 0.2, or T = 5. T 1 1 5. We then know other corner frequency = = . T 10 5s + 1 D(s) = 2 . 10s + 1
Step Response
From: U(1) 1.4 1.2
Amplitude
To: Y(1)
0.8
0.6
0.4
0.2
0 0 5 10 15 20 25
Time (sec.)
20 2
Magnitude
Imag Axis
1 0 1 2
10 0 10 20 30 40 2 10
10
10
10
10
2 3.5
2.5
1.5
0.5
0.5
(rad/sec)
0 30 60 2
Phase
10
10
10
2 3.5
2.5
1.5
0.5
0.5
(rad/sec)
Lecture notes prepared by Dr. Gregory L. Plett
Real Axis
913
Many other aproaches exist. Typically require both lead and lag to meet specs. Many recipes . . . most require iteration. Design Based on Sensitivity Develop conditions on Bode plot of loop transfer function D(s)G(s)H (s) that will ensure good performance with respect to sensitivity, steady-state errors and sensor noise. Steady-state performance = lower bound on very-low-frequency gain of system. Sensor noise = upper bound on high-frequency gain. Unmodeled system resonance:
0
Magnitude
20 40 60 80 100 1 10
10
10
10
Frequency
Magnitude may go over 1. Can cause instability. Must ensure that high-frequency gain is low so magnitude does not go over 1.
914
Magnitude of D(s)G(s)
Sensitivity Functions
Consider
r (t) D(s) G(s) w(t) y(t) v(t)
Y (s) = W (s) + G(s)D(s)[R(s) V (s) Y (s)] [1 + G(s)D(s)] Y (s) = W (s) + G(s)D(s)[R(s) V (s)] 1 G(s)D(s) or, Y (s) = W (s) + [R(s) V (s)]. 1 + G(s)D(s) 1 + G(s)D(s) Tracking error = R(s) Y (s) 1 G(s)D(s) E(s) = R(s) W (s) [R(s) V (s)] 1 + G(s)D(s) 1 + G(s)D(s) 1 1 = [R(s) W (s)] G(s)D(s)V (s) 1 + G(s)D(s) 1 + G(s)D(s) Dene the sensitivity function S(s) to be 1 S(s) = 1 + G(s)D(s) which is the transfer function from r(t) to e(t) and from w(t) to e(t).
Lecture notes prepared by Dr. Gregory L. Plett
915
The complementary sensitivity function T (s) = 1 S(s) G(s)D(s) 1 S(s) = = T (s) 1 + G(s)D(s) which is the transfer function from r(t) to y(t). If V = 0, then and Y (s) = S(s)W (s) + T (s)R(s) E(s) = S(s)[R(s) W (s)].
The sensitivity function here is related to the one we saw several weeks ago T G T SG = 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
Lecture notes prepared by Dr. Gregory L. Plett
916
frequency noise effects, T (s) 0 as frequency increases, and S(s) 1. Typical sensitivity and complementary sensitivity (closed-loop transfer) functions are:
Performance Spec. Stability Spec.
|T ( j)|
|S( j)|
So, 1 + D( j)G( j) is the distance between the Nyquist curve to the 1 1 point. S( j) = . 1 + D( j)G( j) A large value of |S( j)| indicates a Nyquist plot that is nearly unstable. The maximum value of |S| is a more accurate measure of stability than PM or GM. So, we want max |S( j)| small. How small?
Lecture notes prepared by Dr. Gregory L. Plett
917
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)|
EXAMPLE :
1 . W1()
A unity-feedback system is to have an error less than 0.005 for all unity-amplitude sinusoids below 500 rads/sec. Draw |W1( j)| for this design.
Spectrum of R( j) is unity for 0 500. Since eb = 0.005, 1 W1() = = 200 for this range. 0.005
200
Magnitude
150
100
50
0 0
500
1000
1500
2000
Frequency (rads/sec.)
We can translate this requirement into a loop-gain requirement. When 1 errors are small, loop gain is high, so |S( j)| and |D( j)G( j)| 1 1 |D( j)G( j)| W1() or, |D( j)G( j)| W1()
Lecture notes prepared by Dr. Gregory L. Plett
918
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 600
Magnitude
Frequency (rads/sec.)
Design
Assume design for nominal plant G n (s) is stable. Thus, 1 + D( j)G n ( j) = 0 .
Lecture notes prepared by Dr. Gregory L. Plett
919
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 recall, T ( j) = 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.
For high freqencies D( j)G n ( j) is typically small, so T ( j) D( j)G n ( j). Thus |D( j)G n ( j)|W2() < 1 1 |D( j)G n ( j)| < . W2()
EXAMPLE :
The uncertainty in a plant model is described by a function W2() which is zero until = 3000 rads/sec, and increases linearly from there to a value of 100 at = 10, 000 rads/sec. It remains constant at 100 for higher frequencies. Plot constraint on D( j)G n ( j).
Where W2() = 0, there is no constraint on the magnitude of the loop gain. Above = 3000, 1/W2() is a hyperbola from to 0.01 at 10, 000.
920
Magnitude
Frequency (rads/sec.)
Log Magnitude
Frequency (rads/sec.)
Limitation: Crossover needs to be with slope 1. So, cannot make constraints too strict, or design will be unstable.
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 m b y(t) f (t)
..
then, x(t) =
y (t) .. y (t)
102
We can write this in the form x(t) = A x(t) + B f (t), where A and B are constant matrices. A= , B= .
Complete the picture by setting y(t) as a function of x(t). The general form is: y(t) = C x(t) + D f (t) where C and D are constant matrices. C=
.
D=
Fundamental form for linear state-space model: x(t) = A x(t) + Bu(t) y(t) = C x(t) + Du(t). where u(t) is the input, x(t) is the state, A, B, C, D are constant matrices. We usually assume that x(t) is a vector, so simplify notation by simply using x(t). Why Use Them? Transfer functions provide: u G(s) y. That is, only an input-output mapping. State variables provide easy access to what is going on inside the system (homogeneous dynamics). Convenient way to express E.O.M. The matrix format is great for computers.
Lecture notes prepared by Dr. Gregory L. Plett
103
Allows new analysis and synthesis tools. GREAT for multi-input, multi-output systems. These are very hard to work with transfer functions. How do we Formulate Them? A variety of ways. e.g., from E.O.M. Also from transfer functions. Three cases: 1] Transfer function is only made up of poles. G(s) =
... ..
1 Y (s) = s 3 + a1 s 2 + a2 s + a3 U (s)
.
y (t) + a1 y (t) + a2 y (t) + a3 y(t) = u(t) Choose output and derivatives as the state. x(t) = y (t) y (t) y(t) . Then .. ... y (t) y (t) 1 a1 a2 a3 .. . . 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).
.. .
T
2] Transfer function has poles and zeros, but is strictly proper. b1 s 2 + b2 s + b3 Y (s) G(s) = 3 = s + a1s 2 + a2s + a3 U (s)
104
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 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)
.. .
T
3] Non-proper transfer function. b0 s 3 + b1 s 2 + b2 s + b1 G(s) = 3 s + a1 s 2 + a2 s + a3 1 s 2 + 2 s + 3 = 3 + D, s + a1 s 2 + a2 s + a3 where the i terms are computed via long division. The remainder D is the feedthrough term. Matlab command tf2ss(num,den) converts a transfer function form to state-space form. We will see that we have a lot of freedom when making our state-space models (i.e., in choosing the components of x(t)).
Lecture notes prepared by Dr. Gregory L. Plett
105
Modal (Diagonal) Form There are various canonical forms for representing the dynamics of any particular system. All related by linear algebrachange of basis. Diagonal form very useful. . . N (s) Assume G(s) = , D(s) has distinct roots pi (real). D(s) N (s) G(s) = (s p1)(s p2) (s pn ) r1 r2 rn = + + + . s p1 s p2 s pn Now, let X 1(s) r1 = U (s) s p1 . . . x 1(t) = p1 x 1(t) + r1u(t)
.
, D=
r1 r2 B= . . . rn 0
106
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 s X (s) x(0) = AX (s) + BU (s) Y (s) = C X (s) + DU (s)
or
U (s) +
but
107
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) det =
EXAMPLE :
sI A B C D det[s I A] 1 B=0 0
a1 a2 a3 A= 1 0 0 0 1 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).
Lecture notes prepared by Dr. Gregory L. Plett
108
Poles of system are roots of det[s I A] = 0. Transformations State-space representations are not unique. Selection of state x are quite arbitrary. Analyze the transformation of . x(t) = Ax(t) + Bu(t) y(t) = C x(t) + Du(t) Let x(t) = T z(t), where T is an invertible (similarity) transformation matrix. . . z (t) = T 1 x(t) = T 1[Ax(t) + Bu(t)] = T 1[AT z(t) + Bu(t)] = T 1 AT z(t) + T 1 B u(t)
A C D B
y(t) = C T z(t) + D u(t) so z (t) = Az(t) + Bu(t) y(t) = C z(t) + Du(t). Argue that we should be able to use either model. Are they going to give the same transfer function? H1 (s) = C(s I A)1 B + D H2 (s) = C(s I A)1 B + D Need H1 (s) = H2(s). H1 (s) = C(s I A)1 B + D
Lecture notes prepared by Dr. Gregory L. Plett
109
= 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 = C(s I A)1 B + D = H2 (s). Transfer function not changed by similarity transform.
EXAMPLE :
b1 s 2 + b2 s + b3 H (s) = 3 s + a1 s 2 + a2 s + a3
Only six parameters in transfer function. But, A has 3 3, B has 3 1, C has 1 3: a total of 15 parameters. Appears that we have 9 degrees of freedom in state-space model. Contradiction? 9 = size . Time (Dynamic) Response Develop more insight into the system response by looking at time-domain solution for x(t). Scalar case rst, then many states and MIMO.
x(0).
Take Laplace. X (s) = (s a)1 x(0). Inverse Laplace. x(t) = eat x(0).
x(0).
1010
Take Laplace. X (s) = (s I A)1 x(0). x(t) = 1[(s I A)1]x(0). But, (s I A) so,
1
I A2 A = + 2 + 3 + s s s
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 iff expm.m A B = B A.
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, (s I A)1 = =
A=
1
0 1 2 3
s 1 2 s+3 s+3 1 2 s
1 (s + 2)(s + 1)
1011
1(t)
x(0)
Where did this come from? 1. x(t) ax(t) = bu(t) 2. eat [x(t) ax(t)] =
t
3.
0
ea bu( ) d.
n1
m1
e A(t ) Bu( ) d
Du(t) feedthrough
initial resp.
Lecture notes prepared by Dr. Gregory L. Plett
1012
More on the Matrix Exponential Have seen the key role of e At in the solution for x(t). Impacts the system response, but need more insight. Consider what happens if the matrix A is diagonalizable, that is, there exists a matrix T such that T 1 AT = =diagonal. Then, e At = T e t T 1, and e
1 t
0 e2 t ... en t ?
Much simpler form for the exponential, but how to nd 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
T
1013
AT = T
T 1 AT =
One eigenvalue = 0. Solve for the eigenvectors 0 1 0 0 va vb =0 all vectors of the form va 0 = 0.
Dynamic Interpretation
Write T 1 AT =
1 as T A = T 1 with T w1 T w2 = . . . T wn
T 1
i.e., rows of T 1.
wiT A = i wiT , so wi is a left eigenvector of A and note that wiT v j = i, j . How does this help? e At = T e t T 1
1 t
0 e2 t ... en t
v1 v2 . . . v n
0
n
. . . wn T
T w1 T w2
=
i =1
ei t vi wiT
Very simple form. Can be used to develop intuition about dynamic response ei t .
Lecture notes prepared by Dr. Gregory L. Plett
1014
Recall,
=
i =1
ei t vi (wiT x(0)).
Solution (trajectory) can be expressed as a linear combination of system modes: vi ei t . Left eigenvectors decompose initial state x(0) into modal coordinates wiT x(0). ei t propagates mode forward in time. Stability? vi corresponds to relative phasing of state contribution to the modal response.
EXAMPLE :
with x(t)
, y(t)
1015
Impulse Response
2 1.5 1
Amplitude
50
100
150
200
250
300
Time (sec.)
Output waveform is very complicated. Looks almost random or unpredictable. However, such a solution can be decomposed into much simpler modal components. How? Diagonalize A to form an equivalent system. Assume A is diagonalizable by T . Dene new coordinates by x(t) = T x(t) so x(t) = T 1 Ax(t) = T 1 AT x(t) =
.
x(t).
1016
1 0.5 0 0.5
50
100
150
200
250
0 1
50
100
150
200
250
50
100
150
200
250
0.5 0 0.5 0 0.5 0 0.5 0 1 0 1 0 1 50 100 150 200 250 50 100 150 200 250 50 100 150 200 250
50
100
150
200
250
1017
1/s 1
x1
1/s n
=
i =1
ei t vi (wiT x(0)).
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 .
Lecture notes prepared by Dr. Gregory L. Plett
1018
State space: Have input and state contributions u(t) = u 0e zi t , x(t) = x 0e zi t . . . y(t) = 0. x(t) = Ax(t) + Bu(t) zi e zi t x(0) = Ax(0)e zi t + Bu 0e zi t 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
.
Zero at frequency zi if there exists a nontrivial solution of det Recall det s I A B C D det(s I A)
EXAMPLES :
zi I A B C D
=0
We see that a specic frequency is blocked in the output by a zero, BUT, the output does not need to be identically zero.
1019
1 0.9 0.8
Amplitude
0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5
Time (sec.)
y1out y1out 0 Constant 1 s+1 Transfer Fcn (with initial states) s+1 s+10 Transfer Fcn y2out y2out
1 0.9 0.8
Amplitude
0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5
Time (sec.)
1020
Feedback Control System dynamics x(t) = Ax(t) + Bu(t) y(t) = C x(t) System poles given by eigenvalues of A. Want to use input u(t) to change the dynamics. Will assume the form of LINEAR STATE FEEDBACK. u(t) = r(t) K x(t), K 1n .
r (t) u(t) A, B, C x y(t) .
Full state feedback with gain vector K . Substitute: x(t) = Ax(t) + B(r(t) K x(t)) = ( A B K )x(t) + Br(t) y(t) = C x(t) If r = 0 . . . regulation. Design objective: Pick K so that ACL = A B K has some nice properties. For example, A unstable, ACL stable. Put two poles at 2 j. (Pole placement). There are n parameters in the gain vector K and n eigenvalues of A. So, what can we achieve?
Lecture notes prepared by Dr. Gregory L. Plett
1021
EXAMPLE :
x(t) =
1 1 1 2
x(t) +
1 0
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 k1 k2 .
1 k1 1 k2 1 2
So, det(s I A) = s 2 + (k1 3)s + (1 2k1 + k2). By choosing k1 and k2, we can put i ( ACL ) ANYWHERE in the complex plane (in complex-conjugate pairs, that is!) Poles at 5, 6? Compare desired closed-loop characteristic equation (s + 5)(s + 6) = s 2 + 11s + 30 with det(s I A) = s 2 + (k1 3)s + (1 2k1 + k2) So, k1 3 = 11, 1 2k1 + k2 = 30, or, k1 = 14 or, k2 = 57.
K = [14 57].
Lecture notes prepared by Dr. Gregory L. Plett
1022
So, with the n parameters in K , can we always relocate all n i ( ACL )? Most physical systems, qualied yes. Mathematically, EMPHATIC NO! Boils down to whether or not the system is controllable. That is, if every internal system mode can be excited by inputs, either directly or indirectly.
EXAMPLE :
x(t) =
1 1 0 2
x(t) +
1 0
u(t)
det(s I ACL ) = (s 1 + k1)(s 2). Feedback of the state cannot move the pole at s = 2. System cannot be stabilized via state feedback. Reason? Modal form: AV = V
.
1 0 0 2
V =
1 1 0 1
V 1 =
1 1 0 1
1023
Therefore, modal dynamics z (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 = full rank? EXAMPLE : Mc =
EXAMPLE :
1 0 0 2
z(t) +
1 0
u(t).
B AB A2 B . . . An1 B
nn
1 1 0 1 1 1 0 0
Rank =?
Mc =
Rank =?
Design tedious as shown for more than 2 2 since we need symbolic det(s I ACL ). Much easier to work with control canonical form of the state-space representation. a1 a2 a3 1 A= 1 B=0 0 0 , 0 1 0 0 C= b1 b2 b3
1024
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.
Lecture notes prepared by Dr. Gregory L. Plett
1025
0 1
0 1
14 57 .
acker.m Very easy in Matlab, but numerical issues. place.m Use this instead, unless you have repeated roots. polyvalm.m To compute d ( A). Reference Input So far, we have looked at how to pick K to get homogeneous dynamics that we want. i ( ACL) fast/slow/real poles ... How does this improve our ability to track a reference? Started with u(t) = r(t) K x(t). Want y(t) r(t) for good tracking. Y (s) Frequency domain, want 1. Usually only get this performance R(s) at low frequencies.
Lecture notes prepared by Dr. Gregory L. Plett
1026
Problem is that u(t) = r(t) K x(t) is simple, but it gives steady-state errors.
EXAMPLE :
A= Let C =
1 1 1 2
B=
1 0
K =
14 57
1 0
s2 . s 2 + 11s + 30 2 =1! 30
K C=[1 0]
y(t)
yout yout
Step
Kx(t)
K K=[14 57]
0.06
Step Response
0.04
Amplitude
0.02
0.02
0.04
0.06
0.08
10
Time (sec.)
Lecture notes prepared by Dr. Gregory L. Plett
1027
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
How to nd N u and N x ? Use equations of motion. . x(t) = Ax(t) + Bu(t) y(t) = C x(t) + Du(t) At steady state, 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
.
Control signal is now u(t) = Nu r(t) K (x(t) N x r(t)) = K x(t) + (Nu + K N x )r(t) = K x(t) + N r(t) N computed without knowing r(t). It works for any r(t).
1028
1 1 = 2 1 2
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) 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. Y (s) = R(s) new
1029
r (t)
Nu K
u(t)
A, B, C x
y(t)
Nx
r (t)
u(t)
A, B, C x
y(t)
K
Partial statespace model: A=[1 1; 1 2], B=[1; 0], C=[1 0; 0 1], D=[0; 0]. 15 Step Gain Sum x = Ax+Bu y = Cx+Du StateSpace Kx(t) x(t) y(t)
K C=[1 0]
yout yout
K K=[14 57]
1 0.8 0.6
Step Response
Amplitude
10
Time (sec.)
Lecture notes prepared by Dr. Gregory L. Plett
1030
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.
Amplitude
10
12
14
16
0.5
1.5
2.5
Time (sec.)
Lecture notes prepared by Dr. Gregory L. Plett
Time (sec.)
1031
Amplitude
10
12
14
16
0.5
1.5
2.5
Time (sec.)
Time (sec.)
1032
PROCEDURE :
1. Determine desired bandwidth o . 2. Find the nth-order poles from the table of constant bandwidth, and multiply pole locations by o . 3. Use Acker/place to locate poles. Simulate and check control effort.
PROCEDURE :
1. Determine desired settling time ts . 2. Find the nth-order poles from the table of constant settling time, and divide pole locations by ts . 3. Use Acker/place to locate poles. Simulate and check control effort.
Lecture notes prepared by Dr. Gregory L. Plett
1033
EXAMPLE :
G(s) =
1 s(s + 1)(s + 4) 5 4 0 A = 1 0 0 , 0 1 0
1 B=0 0
want ts = 2, and 3rd-order Bessel. 5.0093 s1 = = 2.5047. 2 3.9668 3.7845 j s2,3 = = 1.9834 1.8922 j 2 Bessel model has no overshoot, but is slow compared with ITAE. NOT a good idea for exible systems. Why?
0
ITAE: , Bessel,
20
Magnitude
40
60
80
100
120
140 1 10
10
10
, (rads/sec.)
111
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) = Y (s) is Laplace transform of output, y(t); U (s) is Laplace transform of input, u(t); H (s) is transfer functionthe Laplace tx of impulse response, h(t). y (t) = sY (s) for no initial conditions.
EXAMPLE:
Transforms for systems with LCCODE representations can be written as Y (s) = H (s)U (s), where b0s m + b1s m1 + + bm1s + bm H (s) = , a0s n + a1s n1 + + an1s + an where n m for physical systems. These can be represented in Matlab using vectors of numerator and denominator polynomials: num=[b0 b1 . . . bm]; den=[a0 a1 . . . an]; sys=tf(num,den);
113
Can also represent these systems by factoring the polynomials into zero-pole-gain form: m i =1 (s z i ) H (s) = K n . (s pi ) i =1 sys=zpk(z,p,k); % in Matlab Input signals of interest include the following: 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
= = = =
= = = =
This is useful when investigating steady-state errors in a control system. Block Diagrams Useful when analyzing systems comprised of a number of sub-units.
U (s) H (s) Y (s) Y (s) = H (s)U (s)
114
U (s)
H1 (s)
H2 (s)
Y (s)
R(s)
H1 (s)
Y2 (s)
H2 (s)
U2 (s)
Block-diagram algebra (or Masons rule) may be used to reduce block diagrams to a single transfer function.
U (s) H (s) Y1 (s) Y2 (s) U (s) H (s) 1 H (s) U1 (s) U2 (s) H (s) H (s) Y1 (s) Y2 (s)
U1 (s) U2 (s)
H (s)
Y (s)
Y (s)
R(s)
H1 (s) H2 (s)
Y (s)
R(s)
1 H2 (s)
H2 (s)
H1 (s)
Y (s)
Unity Feedback
115
Dynamic Response versus Pole Locations The poles of H (s) determine (qualitatively) the dynamic response of the system. The zeros of H (s) quantify the relationship. If the system has only real poles, each one is of the form: 1 H (s) = . s+ If > 0, the system is stable, and h(t) = e t 1(t). The time constant is = 1/, and the response of the system to an impulse or step decays to steady-state in about 4 or 5 time constants.
impulse([0 1],[1 1]);
1 1
0.8
0.8
h(t)
0.6
y(t) K
0.6
0.4
1 e
0.4
0.2
0.2
0 0
t =
0 0
Time (sec )
Time (sec )
If a system has complex-conjugate poles, each may be written as: 2 n H (s) = 2 . 2 s + 2 n s + n We can extract two more parameters from this equation: = n and d = n 1 2.
116
plays the same role as aboveit species decay rate of the response. d is the oscillation frequency of the output. Note: d = n unless = 0. is the damping ratio and it also plays a role in decay rate and overshoot.
= sin ( ) n
(s)
(s)
Impulse response h(t) = n e t sin(d t) 1(t). Step response y(t) = 1 e t cos(d t) + sin(d t) . d
Impulse Responses of 2nd-Order Systems
1
=0 0.2
0.5
1.5
0.4
y(t)
y(t)
0.6
=1
0.5
0.8
0.5
0.8 1.0
1 0
n t
10
12
0 0
n t
10
12
A summary chart of impulse responses and step responses versus pole locations is:
(s) (s)
117
Time-domain specications determine where poles SHOULD be placed in the s-plane. (step-response).
tp 1 0.9 Mp
0.1 tr ts
100 90
M p, %
Rise time tr = time to go from 10% to 90% of nal value. Settling time ts = time until permanently within 1% of nal value. Overshoot M p = maximum PERCENT overshoot.
80 70 60 50 40 30 20 10 0 0 0.2 0.4
0.6
0.8
1.0
tr 1.8/n ts 4.6/ / 1 2 Mp e
118
Stability depends on roots of denominator of T (s): 1 + D(s)G(s) = 0. Routh test used to determine stability. Steady-state error found from (for unity feedback) E(s) 1 = . R(s) 1 + D(s)G(s) ess = lim e(t) = lim s E(s) if the limit exists.
t s0
System type = 0 iff ess is nite for unit-step reference-input 1(t). System type = 1 iff ess is nite for unit-ramp reference-input r(t). System type = 2 iff ess is nite for unit-parabola ref.-input p(t). . . For unity-feedback systems, K p = lim D(s)G(s).
s0
K v = lim s D(s)G(s).
s0
K a = lim s 2 D(s)G(s).
s0
Steady-state errors versus system type for unity feedback: Step input Ramp input Parabola input 1 Type 0 1 + Kp 1 Type 1 0 Kv 1 Type 2 0 0 Ka
Lecture notes prepared by Dr. Gregory L. Plett
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
Lecture notes prepared by Dr. Gregory L. Plett
1110
which is the root-locus form. Drawing the root locus allows us to select K for good pole locations. Intuition into the root-locus helps us design D0(s) with lead/ lag/ PI/ PID. . . controllers. Root-Locus Drawing Rules The steps in drawing a 180 root locus follow from the basic phase denition. This is the locus of b(s) b(s) 1+K = 0, K 0 phase of = 180 a(s) 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 = qarr = i i i 180 l360 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.
Lecture notes prepared by Dr. Gregory L. Plett
1111 j 0 and
STEP 6: For the case of multiple roots, two loci come together at 180 and break away at 90. STEP 7 Complete the locus, using the facts developed in the previous steps and making
Three loci segments approach each other at angles of 120 and depart at angles rotated by 60 .
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 )|
When K is negative, the denition of the root locus in terms of the phase relationship is 0 locus denition: The root locus of b(s)/a(s) is the set of points in the s-plane where the phase of b(s)/a(s) is 0. For this case, the steps above are modied as follows: STEP 2: Draw the locus on the real axis to the left of an even number of real poles plus zeros. STEP 3: The asymptotes depart at
l = (l 1)360 , nm l = 1, 2, . . . n m.
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).
Lecture notes prepared by Dr. Gregory L. Plett
1112
We can plot G( j) as a function of in three ways: Bode Plot. Nyquist Plot. Nichols Plot (we did not cover this). Bode Plots A Bode plot is really two plots: 20 log10 |G ( j)| versus and G( j) versus . The Bode-magnitude plot is plotted on a log-log scale. The Bode-phase plot is plotted linear-log scale. The transfer function G(s) is broken up into its component parts, and each part is plotted separately.
Gain of K ; magnitude & phase dB |K | > 1 0.1 1 10
0.1 |K | < 1
10
0.1
10
0.1
10
0.1
10
0.1
10
1113
0.1
10
90
0.1i
1i
10i
0.1i
1i
10i
0.1i
1i
10i
Pole on real axis; magnitude & mp-phase & nmp-phase 0.1i dB 1i 10i 0.1i 1i 10i 0.1i 1i 10i
90
90 Complex zeros; magnitude & mp-phase & nmp-phase 40 20 90 0 20 0 0.1n n 10n 0.1n Complex poles; magnitude & mp-phase & nmp-phase 20 0 90 20 40 0.1n n 10n 180 0.1n 0 180
180
10n
10n
1114
Bode Plot Techniques It is useful to be able to plot the frequency response of a system by hand in order to Design simple systems without the aid of a computer, Check computer-based results, and Understand the effect of compensation changes in design iterations. H.W. Bode developed plotting techniques in the 1930s that enabled quick hand potting of the frequency response. His rules are: STEP 1: Manipulate the transfer function into the Bode form
K G( j ) = K o ( j )n ( 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.
STEP 5: Plot the low frequency asymptote of the phase curve, = n 90 . STEP 6: As a guide, sketch in the approximate phase curve by changing the phase gradually STEP 7: Locate the asymptotes for each individual phase curve so that their phase change
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 . 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.
Lecture notes prepared by Dr. Gregory L. Plett
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: I: Origin. Sometimes a special case. II: + j axis. FREQUENCY response of O.L. system! Just plot it as a polar plot. III: For many physical systems, zero. Some counter-examples. IV: Complex conjugate of II. The test: N = #CW encirclements of 1/K point when F(s) = D(s)G(s). P = # of OPEN-LOOP unstable poles. Z = # of CLOSED-LOOP unstable poles. Z=N+P The system is stable iff Z = 0. For poles on the j-axis, use modied Nyquist path. Bode Plot Performance At low frequency, approximate Bode plot with K G( j) = K 0( j)n . n = system type . . . slope = 20n dB/decade. K 0 = K p for type 0, = K v for type I, . . .
Lecture notes prepared by Dr. Gregory L. Plett
1116
Gain margin (for systems which become unstable with increasing gain) = factor by which gain is less than 0dB when phase = 180. Phase margin (for same systems) = amount phase is greater than 180 when gain = 1. PM related to damping. PM/100 when PM < 70. PM therefore related to M p .
1
1 0.9
Damping ratio
0.8
0.6
0.4
0.2
0 10
0 0
10
20
30
40
50
60
70
80
Phase margin
Phase margin
Gain-phase relationship: For minimum-phase systems, G( j) n 90 where n = slope of log-log plot of gain. (n = 1 if slope = 20dB/decade, n = 2 if slope = 40dB/decade . . . ) Therefore want slope at gain crossover 20dB/decade for decent phase margin.