Назад
260 7 The Control Problem and Design of Simple Controllers
f
k
= e(t) : (IE = integral of error) is the simplest function. The advan-
tage are simple calculations. However, it is only suitable for overdamped
transient responses as otherwise positive and negative parts cancel them-
selves and the criterion can be zero even if the transient response is highly
oscillatory.
f
k
= |e(t)| : (IAE = integral absolute value of error) removes the drawback
of the previous approach and is also suitable for oscillatory responses. How-
ever, from the computational point of view, it can be difficult to implement
as the absolute value is non-differentiable.
f
k
= |e(t)|t : (ITAE = integral time multiplied absolute value of error)
the time term in the cost function penalises the settling time, as well as
reduces the large initial error in the cost function. Otherwise it is the same
as the previous one.
f
k
= e
2
(t) : (ISE = integral squared value of error) combines advantages of
a simple surface and of the absolute value. Large values of control error are
penalised more than small values and lead to controllers with larger settling
time than the IAE cost. Squared error is mathematically convenient for
analytical purposes.
f
k
= e
2
(t)t : improves the previous cost and decreases the settling time.
f
k
= e
2
(t)+φ ˙e
2
(t) : by penalising a square of derivative suppresses oscilla-
tory behaviour typical for ISE cost. Dampens large changes of the control
error and thus also large values of the manipulated input and its change.
The choice of the penalisation factor φ can be difficult.
f
k
= e
2
(t)+φu
2
(t) : can suitably penalise the manipulated variable and
simply regulate the ratio between speed and robustness of the controller.
In each case it has been assumed that e(t)andu(t) are stable and con-
verge to zero, so that the cost functions converge. If this is not correct, it is
necessary to work with deviations of the variables from their steady state or
to implement some special strategy.
7.3.3 Control Quality and Frequency Indices
Control quality can also be characterised by frequency domain indices. Some
of them measure directly quality, others describe relative stability,i.e.quantify
how far is the closed-loop system away from instability.
Gain margin measures relative stability and is defined as the amount of
gain that can be inserted in the loop before the closed-loop system reaches
instability. Mathematically spoken it is the magnitude of the reciprocal of
the open-loop transfer function evaluated at the frequency ω
π
at which
the phase angle of the frequency transfer function is 180
GM =
1
|G
o
(ω
π
)|
(7.20)
7.3 Control Performance Indices 261
where arg G
o
(ω
π
)=180
= π and ω
π
is called the phase crossover
frequency.
Phase margin is a measure of relative stability and it is defined as 180
plus
the phase angle of the open-loop at the frequency ω
1
at unity open-loop
gain
φ
PM
= 180
+ ϕ[G
o
(ω
1
)] (7.21)
where |G
o
(ω
1
)| =1andω
1
is called the gain crossover frequency. Recom-
mended values are between 30
65
.
Gain and phase margins are graphically shown in Bode plots in Fig. 7.5.
10
-1
10
0
10
1
10
2
-100
-50
0
50
Magnitude
[dB]
10
-1
10
0
10
1
10
2
-300
-250
-200
-150
-100
-50
Frequency [rad/min]
Phase
[deg]
π
ω
φ
PM
ω
1
1/PM
Fig. 7.5. Gain and phase margins for a typical continuous system. Intersection for
ω
1
is at the value 0 dB
Bandwidth ω
b
. Loosely spoken it is defined as the frequency range over
which the system responds satisfactorily. Often it is defined as the fre-
quency range where the magnitude is approximately constant compared
to the value at some specified frequency and differs by not more than
3 dB. However, there are also other definitions. A good approximation is
the frequency ω
1
defined by (7.21).
Cutoff rate is the frequency rate at which the magnitude decreases beyond
the cutoff frequency ω
c
. For example it can be chosen as 6 dB / decade.
Resonance peak M
p
is the maximum of the magnitude frequency response.
Resonant frequency ω
p
is the frequency at which the resonance peak oc-
curs.
These indices are shown in Fig. 7.6.
Example 7.2: Gain and phase margins
Let us consider a system with the transfer function
262 7 The Control Problem and Design of Simple Controllers
10
-1
10
0
10
1
-30
-20
-10
0
10
Frequency [rad/min]
Magnitude [dB]
ω
b
p
M
3 dB
ω
p
Fig. 7.6. Bandwidth, resonant peak, and resonance frequency in magnitude fre-
quency response
G(s)=
432
s(s
2
+13s + 115)
Substituting s =jω, the magnitude and phase of the transfer function is
given as
|G(jω)| =
432
(jω)
3
+ 13(jω)
2
+ 115(jω)
=
432
|−13ω
2
+ j(115ω ω
3
)|
=
432
169ω
4
+ (115ω ω
3
)
2
ϕ = ϕ(1) ϕ(13ω
2
+ j(115ω ω
3
)) = arctan
115ω ω
3
13ω
To find the gain margin it is necessary to determine the frequency when
the phase is equal to ϕ = π. This gives
π = arctan
115ω
π
ω
3
π
13ω
π
115ω
π
ω
3
π
13ω
π
= tan π ω
π
=
115
Gain margin is given by the reciprocal of the magnitude of the transfer
function at this frequency (7.20), hence
GM =
1
|G(jω
π
)|
=
1
0.2897
=3.45
For phase margin it is necessary to find the frequency when the magnitude
is equal to one
432
169ω
4
1
+ (115ω
1
ω
3
1
)
2
=1
Manipulating this equation yields the 6th order equation
ω
6
1
61ω
4
1
+ 115
2
ω
2
1
432
2
=0
Solving this equation gives a single real positive root ω
1
=3.858. From
the phase at this frequency follows from (7.21) φ
PM
=63
.
Fig. 7.5 illustrates graphical procedure to find the indices for this system.
7.3 Control Performance Indices 263
Example 7.3: Determination of the resonant peak
Consider a system with the transfer function
G(s)=
5
s
2
+2s +5
We will find values of the resonant peak M
p
, the corresponding resonance
frequency ω
p
, and bandwidth ω
b
. As these are calculated from the mag-
nitude frequency resonance, this will be derived at first
|G(jω)| =
5
|−ω
2
+2jω +5|
=
5
ω
4
6ω
2
+25
The maximum can be found by setting the derivative equal to zero
ω
p
(ω
2
p
3) = 0
Only the second root has meaning and thus ω
p
=
3. The resonant peak
is then
M
p
= |G(jω
p
)| =
5
/
ω
4
p
6ω
2
p
+25
=1.25
Bandwidth can be determined if the magnitude of G(s) decreases by 3 dB
as compared to the value at the beginning (0.707G(0)). As G(0) = 1, it
holds
|G(jω
b
)| =
2
2
ω
b
=2.97.
Fig. 7.6 illustrates graphical procedure to find the indices.
7.3.4 Poles
Very often specification of the control quality can be described by the locations
of poles. Of course, stability dictates the left half plane for the pole locations.
A suitable pole region is shown in Fig. 7.7.
In general, the closer the pole is near the origin, the larger settling time
results. A real pole is coupled with aperiodic (overdamped) response. If the
closed-loop system has more poles, some of them dominate the process dy-
namics the so called dominant poles. These poles are at least five times
nearer to the origin as the other. This means that for example when designing
a pole placement control design it is necessary to characterise only 2-3 poles
and the rest needed for physical realisation of the controller can be chosen
within the far left half plane.
To clarify the relations and influences among several specifications let us
consider the following example.
264 7 The Control Problem and Design of Simple Controllers
Fig. 7.7. Suitable region for pole locations of a closed-loop system
Example 7.4: A second order system - quality indices
Let us consider a closed-loop system with the transfer function of the form
G
yw
=
GR
1+GR
=
ω
2
0
s
2
+2ζω
0
s + ω
2
0
(7.22)
where ζ is the damping coefficient and ω
0
is the natural undamped
frequency. This transfer function can be obtained with a first order con-
trolled system with gain Z and time constant T controlled by a controller
with the transfer function R =1/T
I
s. In that case holds ω
2
0
= Z/TT
I
a
2ζω
0
=1/T .
Assume that the damping coefficient is inside ζ (0, 1). If the setpoint is
the unit step change then the controlled output is given as
y(t)=1
1
1 ζ
2
e
ζω
0
t
sin
ω
0
t
1 ζ
2
+ ϕ
= arctan
1 ζ
2
ζ
(7.23)
Similarly, the transfer function between the output and a disturbance
acting on the plant input is given as
G
yd
=
G
1+GR
=
Z
T
s
s
2
+2ζω
0
s + ω
2
0
(7.24)
and the time response for the unit step change of the disturbance is
e(t)=
Z
ω
0
T
1 ζ
2
e
ζω
0
t
sin
ω
0
t
1 ζ
2
(7.25)
The closed-loop poles are complex conjugated and of the form
p
1,2
= ζω
0
± jω
0
1 ζ
2
(7.26)
7.3 Control Performance Indices 265
When the frequency ω
0
is assumed constant then poles are located in the
complex plane on half circles with radius ω
0
centered in origin. If ζ is
constant, then half lines from origin occur with slope being a function of
ζ (Fig. 7.8).
Re
Im
ω
1
ω
2
ω
3
ζ
1
ζ
2
ζ
3
Fig. 7.8. Curves with constant values of ζ,ω
0
(ζ
1
2
3
, ω
1
2
3
)
The process is underdamped with a period
T
p
=
2π
ω
0
1 ζ
2
(7.27)
and damping coefficient
ζ
d
=
1
ω
0
e
ϕ/ tan ϕ
(7.28)
Settling time T
for a band with accuracy ±p from the steady state is a
complex function of parameters, but can be approximated as
T
log
p
1 ζ
2
ζω
0
(7.29)
Maximum overshoot is given by the relation
e
max
=e
πζ
1ζ
2
=
ζ
d
(7.30)
and occurs at the time
t(e
max
)=
π
ω
0
1 ζ
2
(7.31)
If a step change of a disturbance at the plant input is considered, then for
its maximum value holds
266 7 The Control Problem and Design of Simple Controllers
e
max
=
Z
0
1 ζ
2
e
ϕ tan ϕ
sin ϕ (7.32)
t(e
max
)=
1
ω
0
1 ζ
2
ϕ (7.33)
and the integral performance index IE can be derived as
I
IE
=
Z
ω
2
0
T
(7.34)
These expressions can be used for better understanding of performance
indices and their relations to controller parameters and vice versa. Integral
cost function value is inversely proportional to ω
2
0
. Maximum overshoot
and all time indices are inversely proportional to ω
0
. Transient response
of the closed-loop system to setpoints or disturbances is improved by in-
creasing ω
0
. Further, maximum overshoot or damping coefficient increase
with decreasing ζ.
Results presented in the example do not hold only for closed-loop systems
with the given transfer function but can also be generalised for other systems
as almost any process can be decomposed into a set of the first and second
order systems. Moreover, from the dynamic point of view, in the majority of
processes some subsystem dominates over the rest and the overall system is
approximable by a second order system.
7.4 PID Controller
Among various controllers used in industry, the PID (proportional-integral-
derivative) controller is the most often employed. There are estimates that
more than 90% of controllers are of PID type. Its advantage is simplicity,
robustness as well as the fact that it can be realised in various analogue
(electrical, pneumatic), as well as digital versions.
The principle of the PID controller is processing of its input signal control
error in three branches that will be examined in more detail below.
7.4.1 Description of Components
Proportional Controller
Consider the most simple form of a feedback controller described be the ex-
pression
u(t)=
u
max
if e(t) > 0
u
min
if e(t) < 0
(7.35)
In this case the manipulated input u can have only two values depending on the
control error e sign. This controller is called on-off controller. Its advantage
7.4 PID Controller 267
is simplicity and easy implementation. As the control signal is not defined
for e = 0 (see eq. (7.35)), it is usually modified by introducing some kind of
hysteresis in the neighbourhood of zero.
Its drawbacks are oscillations of the controlled variable in the steady-state
as even a small control error causes the maximum value of the manipulated
input. A suitable improvement for this situation can be introduction of pro-
portional behaviour for small control errors
u(t)=Z
R
e(t) (7.36)
The controller that realises this equation is called proportional (P controller)
and Z
R
is its gain.
From the practical point of view can any controller realise proportional
action only in some limited range of control errors as the manipulated vari-
able can always be only in the range between u
min
and u
max
. Proportional
behaviour of the controller can then be characterised either by its gain Z
R
or
by some range when the controller is linear proportionality band P
p
. Their
relation is
u
max
u
min
= Z
R
P
p
(7.37)
If we consider the maximum range of the manipulated variable normalised, e.
g. u
max
u
min
= 100% then
Z
R
=
100
P
p
(7.38)
If the control error is too large in magnitude then the P controller implements
on-off behaviour with the manipulated variable constrained to its maximum
and minimum values.
From steady-state analysis of the P controller (see page 256) follows that
if the controlled system does not contain at least one pure integrator, the
closed-loop system will exhibit non-zero permanent control error. The sim-
plest scheme to guarantee the zero steady-state control error is to introduce
a suitable constant term u
b
to the manipulated variable
u(t)=Z
R
e(t)+u
b
(t) (7.39)
such that for e(t) = 0 holds u = u
b
.
Example 7.5: Proportional control of a heat exchanger
www
Consider a feedback control of a heat exchanger with the P controller
described by the transfer function R(s)=Z
R
. The heat exchanger can be
given by the differential equation
T
1
y
+ y = Z
1
u +
Z
2
Z
1
d
268 7 The Control Problem and Design of Simple Controllers
where u is the manipulated variable and d is a disturbance. For the sim-
ulation purposes assume that Z
1
=1,T
1
=1.
Consider at first the disturbance rejection case when the disturbance is a
step change. (W (s)=0,D(s)=A/s).
The closed-loop transfer function with respect to the disturbance is in this
case given as
G
yd
=
GG
d
1+GR
=
Z
1
T
1
s+1
Z
2
Z
1
1+Z
R
Z
1
T
1
s+1
The output variable is then given as
Y (s)=
Z
1
T
1
s+1
Z
2
Z
1
1+Z
R
Z
1
T
1
s+1
A
s
=
AZ
2
1+Z
R
Z
1
1
1+
T
1
1+Z
R
Z
1
s
A
s
y(t)
AZ
2
=
1
1+Z
R
Z
1
1 e
t
T
1
/(1+Z
R
Z
1
)
The heat exchanger output is stable for any value of Z
R
and its new
steady-state settles at the value
y()=
AZ
2
1+Z
R
Z
1
A permanent control error exists
e()=w() y()=
AZ
2
1+Z
R
Z
1
This confirms that by increasing the controller gain decreases the control
error (Fig. 7.9).
The slope of the response in time t = 0 will be derived by evaluating the
derivative
1
AZ
2
dy
dt
=
1
1+Z
R
Z
1
1+Z
R
Z
1
T
1
e
t
T
1
/(1+Z
R
Z
1
)
1
AZ
2
dy
dt
t=0
=
1
T
1
It is clear that all step responses have the same slope in time t =0
(Fig. 7.9).
Consider now tracking case when the setpoint is a step change (W (s)=
A/s, D(s) = 0).
The closed-loop transfer function with respect to the setpoint is in this
case given as
G
yw
=
GR
1+GR
=
Z
R
Z
1
T
1
s +1+Z
R
Z
1
The output variable is then given as
7.4 PID Controller 269
Y (s)=
Z
R
Z
1
T
1
s +1+Z
R
Z
1
A
s
=
AZ
R
Z
1
1+Z
R
Z
1
1
T
1
1+Z
R
Z
1
s +1
1
s
y(t)
A
=
Z
R
Z
1
1+Z
R
Z
1
1 e
t
T
1
/(1+Z
R
Z
1
)
The heat exchanger output is stable for any value of Z
R
and its new
steady-state settles at the value
y()=
AZ
R
Z
1
1+Z
R
Z
1
A permanent control error exists
e()=w() y()=A
1
Z
R
Z
1
1+Z
R
Z
1
This again confirms that by increasing the controller gain decreases the
control error.
The slope of the response in time t = 0 is given as
1
A
dy
dt
=
Z
R
Z
1
1+Z
R
Z
1
1+Z
R
Z
1
T
1
e
t
T
1
/(1+Z
R
Z
1
)
1
A
dy
dt
t=0
=
Z
R
Z
1
T
1
Compared to the disturbance rejection case, here the speed of the response
increases with the increasing controller gain (Fig. 7.10).
0 1 2 3 4
0
0.2
0.4
0.6
0.8
1
1.2
y/AZ
2
t/T
1
Z
R
=1
Z
R
=3
Z
R
=10
Fig. 7.9. Response of a heat exchanger
to a step change of the d with a P con-
troller
0 1 2 3 4
0
0.2
0.4
0.6
0.8
1
1.2
y/A
t/T
1
w
Z
R
=1
Z
R
=3
Z
R
=10
Fig. 7.10. Response of a heat exchanger
to a step change of the w with a P con-
troller
In both cases it can be noticed that the controller changes the closed-loop
time constant from the open-loop value T
1
to T
1
/(1 + Z
R
Z
1
). If negative
feedback is assumed, both gains Z
R
a Z
1
have to be positive and the
resulting time constant is smaller than the one of the controlled system
the closed-loop acts faster to a setpoint or disturbance changes as the