Lag compensators are sometimes the best controller to use to get a system
to do what you want it to do. Like other compensators, lag compensators
can be used to adjust frequency response by adding equal numbers of poles
and zeroes to a systems. Those added singularities may possibly be
manipulated to give better stability, better performance and general improvement.
Lag compensators are one tool that should be in the toolkit of every control
system designer.
Goals
Of This Lesson
Before we get very far, we need to
establish what our goals are for lag compensators.
Given a compensator transfer function,
Know which compensators are leads, and which are lags.
Given a lag compensator,
Determine the effects of the lag compensator on closed loop system behavior
using Bode' plot methods.
Determine the effects of the lag compensator on closed loop system behavior
using Root Locus methods.
Other goals of this lesson include:
Given a system to be controlled.
Determine if a lag compensator can be used to satisfy closed loop system
specifications.
Given a system in which a lag compensator can be used,
Determine the parameters of a lag compensator to produce a closed loop
system that meets specifications.
What
Is A Lag Compensator?
A lag compensator can be thought of in several different ways.
First, a lag compensator
is a device that provides phase lag in its' frequency response.
If the compensator has
phase lag - and never a phase lead - then there are implications about
where the corner frequencies are in the Bode' plot.
Other implications are
that the phase lag compensator will have only certain types of pole-zero
patterns in the s plane.
A
lag compensator will have a transfer function of the form:
Since a lead compensator
has only positive phase angle, we must have:
w_{z}
> w_{p}
A Bode' plot will make
this clearer.
Here's
a Bode' plot for a transfer function, G(s), with:
G(s) = (s + 1)/(10s
+ 1)
Notice:
w_{z}
> w_{p}
since:
w_{p}
= .1 rad/sec, and
w_{z}
= 1 rad/sec.
This
Bode' plot shows the essential characteristic of a phase lag compensator.
There is one pole and
one zero. Both are real.
Phase is always negative!
w_{z}
> w_{p}
If, for example, w_{z}
< w_{p}
, we would have a lead network, not a lag network.
Here
note the following in the plot of the example we encountered earlier.
Phase angle is always
negative.
The pole at w_{z}
= .1, or f = .0159 Hz, causes the magnitude plot to bend down, and the
phase to become negative near f = .159 Hz.
Later, the zero at 1.59
Hz. brings the Bode' plot's slope back to zero for high frequencies, and
the phase back to zero.
Below, we have a video that shows how lag networks
behave as the ratio of the pole to the zero changes.
In the video, the ratio
of pole to zero is Alpha. The pole is at -1, so the corner frequency
- in hertz - is .159.
The zero starts out equal
to the pole, so the zero corner is at .159 and then, as Alpha decreases,
the zero moves higher in frequency.
Notice the phase behavior
especially on the plot. Phase is always negative, but you can get
larger phase angles when the pole-to-zero ratio is larger.
You
can see the features of a lag network.
A lag network has one
pole and one zero - although you can add multiple lag networks in a system.
The pole corner frequency
(Bode' plot) is lower than the zero corner frequency.
The lag network adds phase
lag to a system.
In
the next section, we'll look at how you can use a lag network in a system.
Using
Lag Compensators
Usually, a lag network is used as part of the controller in a feedback
system. Here's where the lag network would be used.
In this system, we assume
that you have a lag network, and an adjustable gain in the lag network.
In that case, the compensator
transfer function would be:
Gc(s) = K_{c}(s
+ a)/(s + b)
And we must have a > b,
for a lag compensator.
Now,
let's look at how the lag network affects how the system behaves.
We'll look at root locus effects and then Bode' plot effects.
Bode'
Plot Effects
Let's first examine how adding a lag compensator to a system affects the
Bode' plot - and therefor the performance - of the system.
Consider a system with this transfer function.
G_{p}(s)
= 1/[(s + 1)(s + 4)]
Here is the Bode' plot for this transfer
function.
This is the Bode' plot
for the system as it stands - with no compensator or controller.
Let us first see how well we can control the system as it stands.
Here are some specifications to try to achieve.
SSE < 2%
Phase Margin > 50^{o}
The Bode' plot below has a line indicating where
the phase reaches -130^{o}.
Examining the Bode' plot we can conclude
the following:
The zero db crossing should
occur at around f = 0.8 if we want to get a phase margin of 50^{o}.
If the zero db crossing
is set at f = 0.8, the db gain at that point is-30 db.
If the gain is -30 db,
we can add 30 db gain to the system.
If we add 30 db of gain,
the DC gain will move from -12 db to +18 db. A gain of 30 db is a
gain of about 32.
A DC gain of 18 db is
a gain of 8.
A DC gain of 8 will produce
a SSE of .11 or 11%.
Here's the Bode' plot
after adjusting the gain.
Here is the response for the gain we have
just computed. This response shows the following:
11% SSE.
About 24% overshoot (up
to 1.1 when it settles out to 0.89).
A rise time (10-90%) that
looks to be a little less than 0.5 sec, and about what we predicted.
Note the following.
If the SSE if 11%, then
we cannot simultaneously achieve both specifications above.
If we raise the gain to
get the SSE smaller, we will also bring the phase margin below what we
need to have.
If we wanted to get the
SSE to <2%, we would need to increase the DC gain to 50. Since
it is now at 8, we need a further increase of (50/8) or a factor of 6.25.
Also note that since the
zero db crossing is at f = 0.8, we expect the closed loop bandwidth to
be near that frequency, and the rise time to be given by:
Rise time ~= .35/0.8
= .44 sec.
If you want to check things
on this system, click
here to open a simulated system + compensator
in a separate window. From the comments above, there are some general
conclusions to draw for this example.
It's possible to meet
the stability requirements (rise time and phase margin), and they depend
mostly on the behavior of the Bode' plot near the zero db crossing.
The accuracy requirement
is really a requirement on the DC gain - i.e. the behavior at low frequencies.
Now, we can examine what happens when a lag compensator is added.
We will try to go through this slowly - step-by-step.
When we use a lag compensator we are probably defining our problem as one
where the DC gain cannot be made high enough - as in the example above.
The important points in our thought processes are these.
We use the lag compensator
to allow us to increase the DC gain of the system. We focus on the
low frequency behavior.
We want to increase the
DC gain without disturbing the stability properties. In other words,
we are willing to accept the system's behavior around the zero-db crossing
for the open-loop Bode' plot.
In the example system
the zero db crossing of the uncompensated system was aat f = 0.8.
If we want to use a lag compensator in that system we will do that by trying
to leave the behavior around 0.8 Hz undisturbed. That means that
the pole and zero in the compensator will have to produce their phase and
magnitude changes at frequencies lower than f = 0.8 Hz.
The implications of these
considerations are:
We need a zero to pole
frequency ratio of 6.25 - the gain increase we need.
The zero will have to
be around f = 0.08Hz. By putting the zero there, there will be little
effect on the phase at f = 0.8Hz.
If the zero is a 0.08Hz,
then the pole has to be at .08/6.25, or at .013Hz
The actual compensator
will be (s + .08*2*p)/(s
+ .013*2*p)
= (s + .503)/(s + .082).
And remember that we want
a DC gain of 50, and we have:
Total transfer function
= K (s + .503)/[(s + .082)(s + 1)(s + 4)
To get a DC gain of 50,
we need K = 32 or thereabouts.
And, since these are very
low frequencies, the compensator may be best implemented digitally.
Here is a Bode' plot of the compensated system. In this plot, the
solid lines are for the original (uncompensated) system while the dotted
lines are for the compensated system. (Red for db, blue for phase)
Note how the magnitude and phase plots of both systems are pretty much
the same around the zero db crossing.
Here is the unit step response for a system with that gain calculated above.
There seems to be something wrong here.
It looks like this system has about 5% SSE. However, that's
not true! If you examine what happens over a longer time frame,
you get something like the response shown below. You can see the
same effect in the simulator where you can see how the exponential tail
approaches the steady state.
This response shows the following:
2.5% SSE.
About 15% overshoot if
you count from the final value.
A rise time (10-90%) that
looks to be a little less than 0.5 sec, and about what we predicted.
BUT!
The rise time doesn't
tell the whole story because there is a very slow "exponential
tail" in this response, and we don't get near
the steady state in anything like 0.5 sec.
There is clearly something here that we need to understand. The time
response of this system effectively contains two parts - a fast response
that overshoots a little, and a slow response that seems to take forever
to crawl up to the final value. The time response is not easily evaluated
because of the general shape it seems to have. We are going to examine
this through the lens of the Root Locus. Since the root locus is
a time-domain based approach we may be able to get more insight into what
is happening here because the root locus is the tool that addresses
time response more directly.
Root
Locus Analysis
Let's review the situation. We have a system
with this transfer function.
G_{p}(s)
= 1/[(s + 1)(s + 4)]
This system is embedded in a control loop
like this:
Now, examine the root locus for this system
Thinking about this root locus, we can conclude
the following.
When the closed-loop poles
move away from the open-loop poles they come together at s = -2.5
After coming together
at s = -2.5, the closed-loop poles have a real part of -2.5.
A real part of -2.5 implies
a settling time of approximately 1.1 sec. (Click
here for the relationship between the real part of the pole and the
settling time.)
Earlier, we found this
response for a DC gain of 8.
The DC gain of 8 corresponds
to a Root Locus gain of 32. In other words, the forward transfer
function, G_{c}G_{p}(s), is given by:
G_{c}(s)G_{p}(s)
= 32/[(s + 1)(s + 4)]
A root locus gain of 32
is off the scale in the root locus plot above, and the roots are at s =
-2.5 + j5.45 and -2.5 - j5.45.
Here's the step response
of the closed loop system for this gain. This plot was shown above
and is just reproduced here.
Now, what happens when we add the compensator?
To see the root locus for the compensated system
click the button on the right. You should be able to see that the
root locus doesn't change much except for the addition of a branch between
the compensator pole and the compensator zero. That branch is critical.
Here is the root locus for the compensated system.
Note the following points that you
can see in this plot.
The centroid (center of
gravity) shifts to the right when the lag compensator is added because
the zero is larger than the pole.
The shift isn't really
very large, but there is definitely a shift.
Putting the pole and zero
at higher frequencies - keeping the pole-to-zero ratio the same - would
cause the centroid to shift even further because the pole and zero would
both be further into the left half plane.
The asymptotes for the
branches going to infinity will be shifted to the right because of the
centroid's shift to the right.
If there is root locus
activity near the zero, then the locus will have a tendency to bend toward
the zero.
A
System Design Example
Here's a model of a chemical process. This process has three time
constants and three gains.
Parameters for this system are as follows.
K_{1} =
2.0, t_{1}
= 0.5s
K_{2} =
1.0, t_{2}
= 4.0s
K_{3} =
0.1, t_{3}
= 2.0s
We
want to control this system to meet several specifications.
The first specification
is that we want to have a SSE of 2%.
Problem
P1
What loop gain - K_{s} K_{p} G(0) - will
produce a system with 2% SSE?
You should have found that the value of the DC gain needs to be around
50. Now, we have:
K_{1} =
2.0,
K_{2} =
1.0,
K_{3} =
0.1,
So we have:
K_{1} x
K_{2} x K_{1} = 0.2
That means the proportional
gain, K_{p}, needs to be 250, to get:
K_{p} x
K_{1} x K_{2} x K_{1} = 50
We said we'd like to show you a simulation for
a gain, Kp, of 250. This is what we have. It's not pretty.
The system looks like
it is unstable!
We should check that conclusion
before committing to it completely.
Note that the root locus gain for this system
is 50/(10x.5) = 10. Let's examine the root locus for this system.
Note that the poles are
the negative reciprocals of the time constants, i.e.:
-1/0.5 = -2.
-1/4 = -0.25
-1/2 = -0.5
Here's the root locus, and the points at a root
locus gain of 10 are emphasized.
The system is unstable!
Here is the root locus again. Here poles
for a root locus gain of 4.22 are marked with black dots. The system
has poles on the imaginary axis for a root locus gain of 4.22.
We can draw one conclusion from this analysis.
We cannot meet the
SSE specification. The system is unstable for the gain that would
produce the SSE.
Clearly,
we need to do something if we want to control this system. Let us
consider the possibility of adding a lag compensator. We will examine
how we can change the system's behavior with this compensator. Note,
that we are still assuming an adjustable proportional gain as well as this
compensator transfer function.
(s + 1)/(20s + 1)
We will start by considering the effect on a root locus. Here is
the root locus for the compensated system. It's not much different
from the root locus for the system with no compensation.
Compute the root locus gain for instability
just to see if we can figure out what is possible. Here is the root
locus with points marked where the plot enters the right half plane.
At those points, the root locus gain is 13.7.
That means that the
DC gain is 13.7 which will not give 2% SSE.
The question is what to do to meet the SSE requirement. We need to
look at this problem a little differently. Let's try looking at this
from a Bode' plot viewpoint.