Академический Документы
Профессиональный Документы
Культура Документы
Lead-Lag Compensation
4.1 Introduction
Among the simplest dynamic structures used in compensator design is the lead-lag compensator. A lead-lag
compensator has a transfer function of the form
(s + z1 ) (s + z2 )
Gc (s) = A . (4.1)
(s + p1 ) (s + p2 )
In this experiment, we will use the lead-lag structure to enhance the performance of an operational
amplifier. An op amp is different from the other control systems with which we are working this semester
in that it is a purely electrical device, operating over a relatively high range of frequencies and at low power
level. Nevertheless, compensator design problems for an op amp are mathematically similar to compensator
design problems for more conventional control systems such as a servomotor.
s + 1.88 × 106
G (s) = (4.2)
(s + 377)(s + 3.77 × 105 )(s + (2.83 + j4.81) × 106 ))(s + (2.83 − j4.81) × 106 )
9.33 × 1019 s + 1.76 × 1026
= 4 .
s + 6.03 × 106 s3 + 3.32 × 1013 s2 + 1.17 × 1019 s + 4.42 × 1021
G(s) has a DC gain of 92dB, a zero at 300KHz, and poles at 60Hz, 60KHz, and (450 ± j765)KHz. Actual
values of these parameters vary somewhat from one chip to another, but the mathematical model is still
accurate enough to obtain good results.
For the sake of numerical stability when analyzing (4.2) with MATLAB (and for overall convenience),
we will perform a frequency scaling by a factor 106 . This means that we must substitute “106 s” in place of
“s” wherever it appears. Doing so yields
93.3s + 176
G (s) = . (4.3)
s4 + 6.03s3 + 33.2s2 + 11.7s + .00442
One result of this transformation is that all frequencies (e.g. those appearing on Bode plots) must be read
as “Mrad/sec”, rather than “rad/sec”, and “MHz”, rather than “Hz”. Another result is time scaling: Values
of time must now be read as “µsec”, rather than “sec”.
It is useful to refer to the Bode plots for G(s):
25
26 EXPERIMENT 4. LEAD-LAG COMPENSATION
Figure 4.1
Figure 4.2
ωb ≥ ωc . (4.6)
4.3. PHASE MARGIN AND GAIN CROSSOVER FREQUENCY 27
Phase margin of G is related to stability of the closed-loop system according to the following argument:
Suppose φp = 0. This means that ∠G (jω c ) = −180 ◦ , so G(jω c ) = −1. Evaluating (4.4) at ω c shows that
applying unity feedback to a plant with φp = 0 results in a closed-loop system with a pole at s = jω c .
Consequently, H is (marginally) unstable.
A fundamental fact of feedback theory (which we state here without proof) is that the closed-loop
transfer function H is BIBO stable if and only if φp > 0. Moreover, it can be shown that increasing
φp tends to move the poles of the closed-loop system further to the left in the complex plane, increasing
damping. For the LM12, the phase plot of G shows that φp = 15 ◦ . Thus the op amp alone in a unity
feedback configuration would be stable.
Phase margin and gain crossover frequency can also be (somewhat loosely) related to the other closed-
loop performance specifications we encountered in Experiment 2. For example, (4.6) shows that, if ω c is
large, so is ω b ; thus even signals with substantial high frequency components tend to pass through the system
unattenuated. Large ω b also tends to give large ω m . In terms of the step response, large ω b implies that Tr
and Tp are small. If φp is large, the closed-loop system is heavily damped, leading to values of Mp and Mm
close to unity. Generally, a phase margin of 60 ◦ is considered good; smaller φp tends to result in oscillatory
and overshoot phenomena in the closed-loop system response. Settling time Ts is more closely related to the
compensation scheme used, rather than to φp and ω c , since it depends most heavily on the location of the
closed-loop pole with the smallest real part.
The remaining specification of interest in this experiment is the DC gain |G (0)| . The relationship between
DC gain and the steady-state error ess0 to a unit step input can be obtained by applying the Final Value
Theorem of Laplace transforms, yielding
1
ess0 = . (4.8)
1 + |G (0)|
1
ess0 ≈ (4.9)
|G (0)|
is extremely accurate. Excluding Ts , the various design parameters fall into three groups:
1
|G (0)| , (4.10)
ess0
1 1
ωc , ωb , ωm , ,
Tr Tp
1 1
φp , ,
Mp Mm
Ideally, we would like |G(0)|, ω c , and φp to be large. Closing the unity feedback loop around G is equivalent
to building the following circuit:
28 EXPERIMENT 4. LEAD-LAG COMPENSATION
Figure 4.3
Although we cannot actually change the plant itself, open-loop characteristics can, in effect, be altered
by connecting a compensator Gc in series with the plant. The series combination Gc G then replaces G in
the unity feedback configuration as shown.
Figure 4.4
Then K must be calculated to shift the crossover frequency down to the chosen ω 0c . The new gain crossover
frequency satisfies K |G (jω 0c )| = 1, so K is determined by
1
K= . (4.12)
|G (jω 0c )|
This yields steady-state error
1 1
ess0 = = .
|Gc (0) G (0)| K |G (0)|
Typically, gain compensation severely restricts the closed-loop bandwidth and increases steady-state error.
In the special case of op amp compensation, standard practice is to use a resistive network to achieve the
gain K:
Figure 4.5
Thus
R2
K= , (4.13)
R1 + R2
and we.are restricted to values 0 ≤ K ≤ 1. Although an active compensator would allow more flexibility,
such a controller would employ additional amplifiers. This approach would greatly add to the complexity of
the design process, since the magnitude and phase characteristics of each amplifier would have to be taken
into account. Placing Gc in series with G and closing the loop is equivalent to building the following circuit:
Figure 4.6
For a given K, resistance values may be obtained by solving (4.13) for R1 :
µ ¶
1
R1 = − 1 R2 (4.14)
K
The freedom in choosing R2 may be exploited to avoid interactions between the compensator and the input
and output impedances of the amplifier.
30 EXPERIMENT 4. LEAD-LAG COMPENSATION
Figure 4.7
(s + ω 1 ) (s + ω 2 )
Gc (s) = , (4.15)
s2 + (ω 1 + ω 2 + ω 3 ) s + ω 1 ω 2
where
1 1 1
ω1 = , ω2 = , ω3 = . (4.16)
R1 C1 R2 C2 R2 C1
A = 1, z1 = ω 1 , z2 = ω 2 , (4.17)
µ ³ ´ 12 ¶
1 2
p1 = ω 1 + ω 2 + ω 3 − (ω 1 + ω 2 + ω 3 ) − 4ω 1 ω 2 ,
2
µ ³ ´ 12 ¶
1 2
p2 = ω 1 + ω 2 + ω 3 + (ω 1 + ω 2 + ω 3 ) − 4ω 1 ω 2 .
2
From (4.15),
p1 p2 = z1 z2 . (4.19)
Hence, only 3 of the 4 poles and zeros can be adjusted independently. These constraints are a consequence
of using a passive compensator.
The closed-loop circuit is depicted below:
4.5. LEAD-LAG COMPENSATION 31
Figure 4.8
Figure 4.9
The phase plot of Gc hints at the origin of the name “lead-lag”. The phase “lags” at lower frequencies
and “leads” at higher frequencies. The basic idea in lead-lag design is to choose the lead portion of the
compensator (p2 and z2 ) to add phase in the vicinity of the desired value of ω 0c . The lag portion (p1 and z1 )
then attenuates the magnitude so that ω 0c is actually the crossover frequency. The phase lag is merely an
artifact of the compensator structure and plays no role in achieving the specifications.
The new gain crossover frequency is determined by
³ ´³ ´
2 2
(ω 0c ) + z12 (ω 0c ) + z22
³ ´³ ´ |G (jω 0c )|2 = 1. (4.20)
0 2 2 0 2 2
(ω c ) + p1 (ω c ) + p2
32 EXPERIMENT 4. LEAD-LAG COMPENSATION
2
(ω 0c )
p1 = . (4.23)
100p2
The relationship between φ0p and ω 0c is given by
ω 0c ω0 ω0 ω0
φ0p = arctan + arctan c − arctan c − arctan c + ∠G (jω 0c ) + 180 ◦ . (4.24)
z1 z2 p1 p2
From (4.21),
ω 0c ω0
arctan + arctan c = 168.6 ◦ . (4.25)
z1 z2
From (4.23),
ω 0c p2
arctan = arctan 100 0 ≈ 90 ◦ . (4.26)
p1 ωc
Combining (4.22) with a trigonometric identity yields
µ³ ´ 12 ¶
ω 0c ◦ p2 ◦ 0 2
arctan = 90 − arctan 0 ≈ 90 − arctan |G (jω c )| − 1 . (4.27)
p2 ωc
Combining (4.24)-(4.27),
µ³ ´ 12 ¶
2
φ0p ≈ arctan |G (jω 0c )| − 1 + ∠G (jω 0c ) + 168 ◦ . (4.28)
The design process consists of plotting (4.28), choosing a point on the graph corresponding to acceptable
values φ0p and ω 0c , and calculating z1 , z2 , p1 , and p2 from (4.21)-(4.23). Resistor and capacitor values may
be obtained by solving 4.16 for R1 , C1 , and C2 :
µ ¶
1 1 1 1 1 1 1 1 1
C2 = , R1 = + − − , C1 = . (4.30)
z2 R2 p1 p2 z1 z2 C2 z1 R1
The freedom in choosing R2 may again be exploited to avoid interactions between the compensator and the
input and output impedances of the amplifier.
Note that, regardless of the choice of lead-lag compensator, the steady-state error is extremely small:
1 1
ess0 ≈ = . (4.31)
|Gc (0) G (0)| |G (0)|
The lead-lag approach simultaneously achieves small steady-state error, large phase margin, and large gain
crossover frequency.
4.6. MATLAB COMMANDS 33
4.7 Preparation
1) Using MATLAB, construct the Bode plots for the uncompensated transfer function G. Use the frequency-
scaled version (4.3) of G.
2) Plot |H(jω)| and the closed-loop step response for the gain compensated system with K = 1.
3) From the graphs in 1) and 2), record the predicted values of φp , ω c , Ts , Tr , Tp , Mp , ω b , ω m , and Mm for
the unit gain feedback system.
4) From equation (4.11), plot the achievable values of φ0p versus ω 0c for arbitrary gain compensation. (Use
the “semilogx” command.)
5) Based on your graph in 4), determine values of ω 0c , φ0p , and K so that the gain compensated closed-loop
system meets the specifications
ess0 ≤ .01,
ω 0c ≥ 2 × 105 rad/sec,
φ0p ≥ 60 ◦ .
34 EXPERIMENT 4. LEAD-LAG COMPENSATION
7) Plot |H(jω)| and the step response for the gain compensated closed-loop system.
8) From the graphs in 6) and 7), record the predicted values of Ts , Tr , Tp , Mp , ω b , ω m , and Mm .
9) Let R2 = 510Ω. (This minimizes interactions between the compensator and the input and output
impedances of the amplifier.) Use equation (4.14) to find the value of R1 so that the gain compensation
network achieves the gain K in 5). (The resistance R2 = 510Ω minimizes interactions of the compensation
network with the amplifier input and output impedances and the signal generator output impedance.)
10) From equations (4.28), plot the achievable values of φ0p versus ω 0c for a lead-lag compensator.
11) Based on your graph in 10) and equations (4.21)-(4.23), determine values of ω 0c , φ0p , p1 , p2 , z1 , and z2 so
that the corresponding lead-lag compensator achieves the specifications
ess0 ≤ .01,
ω 0c ≥ 2 × 106 rad/sec,
φ0p ≥ 60 ◦ .
12) Construct the Bode plots corresponding to Gc G.
13) Plot |H(jω)| and the step response for the closed-loop system.
14) From the graphs in 12) and 13), record the predicted values of Ts , Tr , Tp , Mp , ω b , ω m , and Mm .
15) Assuming R2 = 510Ω, use equation (4.30) to calculate the other resistor and capacitor values for the
lead-lag compensation network.
1) Connect the power amplifier in the unity feedback configuration (Figure 4.3).
2) Apply a square wave input, and record the values of ess0 , Ts , Tr , Tp , and Mp .
3) Apply sinusoidal inputs at a variety of frequencies and record the values of ω m , ω b , and Mm .
4.9 Analysis
1) Construct a table that summarizes your data. The table should have eight columns corresponding to
Tr , Tp , Ts , Mp , ess0 , ω b , ω m , and Mm and three rows corresponding to the three closed-loop structures you
examined.
2) Write a few paragraphs summarizing your findings. In particular, compare the performance of each of
the three compensators relative to the various response parameters.