ENG - Magnitude Optimum Techniques For PID Controllers
ENG - Magnitude Optimum Techniques For PID Controllers
1. Introduction
Today, most tuning rules for PID controllers are based either on the process step response or
else on relay-excitation experiments. Tuning methods based on the process step response
are usually based on the estimated process gain and process lag and rise times (Åström &
Hägglund, 1995). The relay-excitation method is keeping the process in the closed-loop
configuration during experiment by using the on/off (relay) controller. The measured data
is the amplitude of input and output signals and the oscillation period.
The experiments mentioned are popular in practice due to their simplicity. Namely, it is
easy to perform them and get the required data either from manual or from automatic
experiments on the process. However, the reduction of process time-response measurement
into two or three parameters may lead to improperly tuned controller parameters.
Therefore, more sophisticated tuning approaches have been suggested. They are usually
based on more demanding process identification methods (Åström et al., 1998; Gorez, 1997;
Huba, 2006). One such method is a magnitude optimum method (MO) (Whiteley, 1946). The
MO method results in a very good closed-loop response for a large class of process models
frequently encountered in the process and chemical industries (Vrančić, 1995; Vrančić et al.,
1999). However, the method is very demanding since it requires a reliable estimation of
quite a large number of process parameters, even for relatively simple controller structures
(like a PID controller). This is one of the main reasons why the method is not frequently
used in practice.
Recently, the applicability of the MO method has been improved by using the concept of
‘moments’, which originated in identification theory (Ba Hli, 1954; Strejc, 1960; Rake, 1987).
In particular, the process can be parameterised by subsequent (multiple) integrals of its
input and output time-responses. Instead of using an explicit process model, the new tuning
method employs the mentioned multiple integrals for the calculation of the PID controller
parameters and is, therefore, called the “Magnitude Optimum Multiple Integration”
(MOMI) tuning method (Vrančić, 1995; Vrančić et al., 1999). The proposed approach
therefore uses information from a relatively simple experiment in a time-domain while
retaining all the advantages of the MO method.
The deficiency of the MO (and consequently of the MOMI) tuning method is that it is
designed for optimising tracking performance. This can lead to the poor attenuation of load
disturbances (Åström & Hägglund, 1995). Disturbance rejection performance is particularly
www.intechopen.com
76 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
decreased for lower-order processes. This is one of the most serious disadvantages of the
MO method, since in process control disturbance rejection performance is often more
important than tracking performance.
The mentioned deficiency has been recently solved by modifying the original MO criteria
(Vrančić et al., 2004b; Vrančić et al., 2010). The modified criteria successfully optimised the
disturbance rejection response instead of the tracking response. Hence, the concept of
moments (multiple integrations) has been applied to the modified MO criteria as well, and
the new tuning method has been called the “Disturbance Rejection Magnitude Optimum”
(DRMO) method (Vrančić et al., 2004b; Vrančić et al., 2010).
The MOMI and DRMO tuning methods are not only limited to the self-regulating processes.
They can also be applied to integrating processes (Vrančić, 2008) and to unstable processes
(Vrančić & Huba, 2011). The methods can also be applied to different controller structures,
such as Smith predictors (Vrečko et al., 2001) and multivariable controllers (Vrančić et al.,
2001b). However, due to the limited space and scope of this book, they will not be
considered further.
2. System description
A stable process may be described by the following process transfer function:
where KPR denotes the process steady-state gain, and a1 to an and b1 to bm are the
corresponding parameters (m≤n) of the process transfer function, whereby n can be an
arbitrary positive integer value and Tdelay represents the process pure time delay. Note that
the denominator in (1) contains only stable poles.
The PID controller is defined as follows:
U ( s ) = GR ( s ) R ( s ) − GC ( s ) Y ( s ) , (2)
where U, R and Y denote the Laplace transforms of the controller output, the reference and
the process output, respectively. The transfer functions GR(s) and GC(s) are the feed-forward
and the feedback controller paths, respectively:
K I + bK P s + cK Ds 2
GR ( s ) =
s ( 1 + sTF )
. (3)
K + K P s + K Ds 2
GC ( s ) = I
s ( 1 + sTF )
The PID controller parameters are proportional gain KP, integral gain KI, derivative gain
KD, filter time constant TF, proportional reference weighting factor b and derivative
reference weighting factor c (Åström & Hägglund, 1995). Note that the first-order filter is
applied to all three controller terms instead of only the D term in order to reduce noise
amplitude at the controller output and to simplify the derivation of the PID controller
parameters. The range of parameters b and c is usually between 0 and 1. Since the feed-
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 77
forward and the feedback paths are generally different, the PID controller (2) is a two-
degrees-of-freedom (2-DOF) controller. Note that controller (2) becomes a 1-DOF
controller when choosing b=c=1.
The PID controller in a closed-loop configuration with the process is shown in Figure 1.
PID controller
c KDs
+ d
- + process
+
+ 1 u + ur y
b KP GP(s)
+ 1 + sTF
- +
r e KI
+ s
-
Y (s) GR ( s ) GP ( s )
GCL ( s ) = = . (4)
R (s) 1 + GC ( s ) GP ( s )
For the 1-DOF PID controller (b=c=1), the closed-loop transfer function becomes:
Y (s) GC ( s ) GP ( s )
GCL ( s ) = = . (5)
R (s) 1 + GC ( s ) GP ( s )
The deficiency of 1-DOF controllers is that they usually cannot achieve optimal tracking and
disturbance rejection performance simultaneously. 2-DOF controllers may achieve better
overall performance by keeping the optimal disturbance rejection performance while
improving tracking performance.
www.intechopen.com
78 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
The new design objective would be to maintain the closed-loop magnitude (amplitude)
frequency response (GCL) from the reference to the process output as flat and as close to
unity as possible for a large bandwidth (see Figure 2) (Whiteley, 1946; Hanus, 1975; Åström
& Hägglund, 1995; Umland & Safiuddin, 1990). Therefore, the idea is to find a controller that
makes the frequency response of the closed-loop amplitude as close as possible to unity for
lower frequencies.
GCL ( 0 ) = 1 , (6)
2
d 2 k GCL ( jω )
= 0 ; k = 1,2,⋯ , kmax (7)
dω 2 k
ω =0
f 0 + f 1s + f 2 s 2 + ⋯
GCL ( s ) = , (8)
e0 + e1s + e2s 2 + ⋯
then expression (7) can be met by satisfying the following conditions (Vrančić et al., 2010):
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 79
2n
∑ ( −1)
i =0
i +n
(f f
i 2 n − i e0
2
)
− ei e2 n − i f 0 2 = 0; n = 1,2,… (9)
Before calculating the parameters of the 1-DOF PID controller, according to the given MO
criteria, the pure time delay in expression (1) has to be developed into an infinite Taylor
series:
2 3 k
− sTdelay ( sTdelay ) − ( sTdelay ) ( −1)k ( sTdelay )
e = 1 − sTdelay + +⋯+ +⋯ (10)
2! 3! k!
or Padé series:
n k k
sTdelay sTdelay s 2Tdelay 2 k s Tdelay
1− 1 − + − … + ( −1 ) +⋯
e
− sTdelay
= lim 2n = 2 2 2 2! 2k k! . (11)
n →∞ sTdelay sTdelay s 2Tdelay 2 s kTdelay k
1+ 1+ + +…+ +⋯
2n 2 2 2 2! 2k k!
Then, the closed-loop transfer function (5) is calculated from expressions (1), (3) and (10) or
else (11). The closed-loop parameters ei and fi can be obtained by comparing expressions (8)
and (5). The PID controller parameters are then obtained by solving the first three equations
(n=1, 2 and 3) in expression (9) (Vrančić et al., 1999):
(
K P = f 1 K PR , a1 , a2 ,… , a5 , b1 , b2 ,… , b5 ,Tdelay ,TF ) (12)
(
K I = f 2 K PR , a1 , a2 ,… , a5 , b1 , b2 ,… , b5 , Tdelay , TF ) (13)
(
K D = f 3 K PR , a1 , a2 ,… , a5 , b1 , b2 ,… , b5 , Tdelay , TF ) (14)
The expressions (12)-(14) are not explicitly given herein, since they would cover several
pages. In order to calculate the three PID controller parameters – according to the given MO
tuning criteria – only the parameters KPR, a1, a2, a3, a4, a5, b1, b2, b3, b4, b5, and Tdelay of the
process transfer function (1) are required, even though the process transfer function can be
of a higher-order. However, accurately estimating such a high number of process
parameters from real measurements could be very problematic. Moreover, if one identifies
the fifth-order process model from the actually higher-than-fifth-order process, a systematic
error in the estimated process parameters would be obtained, therefore leading to the
calculation of non-optimal controller parameters. Accordingly, the accuracy of the estimated
process parameters in practice remains questionable.
Note that the actual expressions (12)-(14) remain exactly the same when the process with
pure time-delay is developed into a Taylor (10) or Padé (11) series (Vrančić et al., 1999).
www.intechopen.com
80 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
Namely, the process transfer function (1) can be developed into an infinite Taylor series
around s=0, as follows:
∞
1 k
k ! ∫0
Ak = t h ( t ) dt . (16)
However, the process impulse response cannot be obtained easily in practice since – due to
several restrictions – we cannot apply an infinite impulse signal to the process input.
Fortunately, the moments Ai can also be obtained by calculating repetitive (multiple)
integrals of the process input (u) and output (y) signals during the change of the process
steady-state (Strejc, 1960; Vrančić et al., 1999; Vrančić, 2008):
u (t ) − u ( 0) y (t ) − y (0)
u0 ( t ) = y0 ( t ) =
u(∞) − u(0) u (∞) − u (0)
t t
IU 1 ( t ) = ∫ u0 (τ ) dτ IY 1 ( t ) = ∫ y 0 (τ ) dτ
0 0 . (17)
t t
IU 2 ( t ) = ∫ IU 1 (τ ) dτ IY 2 ( t ) = ∫ IY 1 (τ ) dτ
0 0
⋮ ⋮
A0 = y 0 ( ∞ ) ; y1 = A0 IU 1 ( t ) − IY 1 ( t )
A1 = y 1 ( ∞ ) ; y 2 = A1 IU 1 ( t ) − A0 IU 2 ( t ) + IY 2 ( t )
. (18)
A2 = y 2 ( ∞ ) ; y 3 = A2 IU 1 ( t ) − A1 IU 2 ( t ) + A0 IU 3 ( t ) − IY 3 ( t )
⋮
It is assumed that:
yɺ ( 0 ) = yɺɺ ( 0 ) = ɺɺɺ
y (0) = ⋯ = 0 . (19)
Given that in practice the integration horizon should be limited, there is no need to wait
until t=∞. It is enough to integrate until the transient of y0(t) in (17) dies out. Note that the
first impulse (A0) equals the steady-state process gain, KPR.
In order to clarify the mathematical derivation, a graphical representation of the first
moment (area) is shown in Figure 3. Note that u0 and y0 represent scaled process input and
process output time responses, respectively.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 81
A0
A1
A0u0
y0
t
Fig. 3. Graphical representation of the moment (area) A1 measured from the process steady-
state change time response (see shadowed area).
Therefore, in practice the process can be easily parameterised by the moments Ai from the
process step-response or else from any other change of the process steady-state.
On the other hand, the moments can also be obtained directly from the process transfer
function (1), as follows (Vrančić et al., 1999; Vrančić et al., 2001a):
A0 = K PR
(
A1 = K PR a1 − b1 + Tdelay )
Tdelay 2
A2 = K PR b2 − a2 − Tdelay b1 + + A1 a1
2!
⋮ . (20)
k +1
k i
k + i Tdelay bk − i
Ak = K PR ( −1 ) ( ak − bk ) + ∑ ( −1 ) +
i!
i =1
k −1
k + i −1
+ ∑ ( −1 ) Ai ak − i
i =1
Let us now calculate the 1-DOF PID controller parameters by using the process transfer
function parameterised by moments (15). In order to simplify derivation of the PID
controller parameters, the filter within the PID controller (3) is considered to be a part of the
process (1):
GP ( s )
GP* ( s ) = . (21)
1 + sTF
www.intechopen.com
82 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
Therefore, GC(s) (3) simplifies into the “schoolbook” PID controller without a filter:
(
GC* ( s ) = K I + K P s + K D s 2 / s . ) (22)
Since a filter is considered as a part of the process, the measured moments (18) should be
changed accordingly. One solution to calculate any new moments is to filter the process
output signal:
Y (s)
YF ( s ) = (23)
1 + sTF
and use signal yF(t) instead of y(t) in expression (17). However, a much simpler solution is to
recalculate the moments as follows:
A0* = A0
A1* = A1 + A0TF
, (24)
A2* = A2 + A1TF + A0TF2
⋮
where Ai* denote the moments of the process with included the filter (21).
The parameters ei and fi in expression (8) can be obtained by placing expressions (22) and
(15) (by replacing moments Ai with Ai*) into (5). By solving the first three equations in (9),
the following PID controller parameters are obtained (Vrančić et al., 2001a):
−1
* A0* 0
K I − A1 −0.5
K = − A* A2* − A1* 0
P 3 . (25)
K D − A* A4* − A3* 0
5
The expression for the PID controller parameters is now much simpler when compared to
expressions (12)-(14). There are several other advantages to using expression (25) instead of
expressions (12)-(14) for the calculation of the PID controller parameters.
First, only the steady-state process gain A0=KPR and five moments (A1 to A5) instead of the
12 transfer function parameters (KPR, a1..a5, b1..b5, and Tdelay) are needed as input data.
Second, the expression for KI, KP, and KD is simplified, which makes it more transparent and
simpler to handle.
Third, the moments A1 to A5 can be calculated from the process time-response using
numerical integration, whilst the gain A0=KPR can be determined from the steady-state value
of the process steady-state change in the usual way. This procedure replaces the much more
demanding algorithm for the estimation of the transfer function parameters.
In addition, it is important to note that the mapping of expressions (12)-(14) into expression
(25) results in exact (rather than approximate) controller parameters. This means that the
frequency-domain control criterion can be achieved with a model parameterised in the time-
domain. Thus the proposed tuning procedure is a simple and very effective way for
controller tuning since no background in control theory is needed.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 83
Note that the calculation of the filtered PID controller parameters is based on the fact that
the filter time constant is given a priori. In practice this is often not entirely true, since the
usual way is rather to define the ratio (N) between the derivative time constant (TD=KD/KP)
and the filter time constant:
TD K
N= = D . (26)
TF K PTF
KD
TF = . (27)
KPN
The moments are recalculated according to expression (24) and the new controller
parameters from (25). By performing a few more iterations, quite accurate results can be
obtained for the a priori chosen ratio N.
The PI controller parameters can be calculated in a similar manner to those of the PID
controller by choosing KD=0. Since a filter is usually not needed in a PI controller (TF=0), the
original moments (Ai) are applied in the calculation. Repeating the same procedure as
before and solving the first two equations in (9), the following PI controller parameters are
obtained (Vrančić et al., 2001a):
−1
K I − A1 A0 −0.5
K = − A A2 0 . (28)
P 3
Note that the vectors and matrices in (28) are just sub-vectors and sub-matrices of
expression (25). Similarly, the I (integral-term only) controller gain is the following:
0.5
KI = . (29)
A1
The proportional (P) controller gain can be obtained by fixing KI=0 and KD=0, repeating the
procedure and solving the first equation in (9):
2 A0 A2 − A12
KP = . (30)
(
2 A0 A12 − A0 A2 )
However, condition (6) is not satisfied, since proportional controllers cannot achieve closed-
loop gain equal to one at lower frequencies. Therefore the proportional controller does not
entirely fulfil the MO conditions and will not be used in any further derivations.
In some cases, the controller parameters have to be re-tuned for certain practical reasons. In
particular, when tuning the PID controllers for the first-order or the second-order process,
the controller gain is theoretically infinite. In practice (when there is process noise), the
www.intechopen.com
84 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
calculated controller gain can have a very high positive or negative value. In this case, the
controller gain should be limited to some acceptable value, which would depend on the
controller and the process limitations (Vrančić et al., 1999). Note that the sign of the
proportional gain is usually the same to the sign of the process gain:
1 10
≤ KP ≤ . (32)
A0 A0
The remaining two controller parameters can now be calculated according to the limited
(fixed) controller gain from expression (25). If the chosen controller gain is:
1
KP > , (33)
2 A1* A2*
− 2 A0*
A3*
then:
0.5 + K P A0*
KI = (34)
A1*
and:
KD = 0 . (36)
When limiting the proportional gain of the PI controller, only Eq. (34) is used. Note that
proposed re-tuning can also be used in cases when a slower and more robust controller
should be designed (by decreasing KP), or if a faster but more oscillatory response is
required (by increasing KP).
The PID controller tuning procedure, according to the MOMI method, can therefore proceed
as follows:
• If the process model is not known a priori, modify the steady-state process by changing
the process input signal.
• Find the steady-state process gain KPR=A0 and moments A1-A5 by using numerical
integration (summation) from the beginning to the end of the process time response
according to expressions (17) and (18). If the process model is known, calculate the
moments from expression (20).
• Fix the filter time constant TF to some desired value and calculate the PID controller
parameters from (25). If needed, change the filter time constant and recalculate the PID
controller parameters. If the proportional gain KP is too high or has a different sign to
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 85
the process gain (KPR=A0), set KP manually to some desired value (32) and recalculating
remaining parameters according to expressions (33)-(36).
• The PI or I parameters can be calculated from expressions (28) or (29), respectively.
The proposed tuning procedure will be illustrated by the following process models:
1
GP 1 ( s ) =
( 1 + 2 s ) ( 1 + s )2
2
1
GP 2 ( s ) =
( 1 + s )6 (37)
1 − 4s
GP 3 ( s ) =
( 1 + s )2
e −5s
GP 4 ( s ) =
1+s
The process models have been chosen in order to cover a range of different processes,
including higher-order processes, highly non-minimum phase processes and dominantly
delayed processes. The models have the same process gain (A0=1) and the first moment A1=6.
If the process transfer function is not known in advance, the moments (areas) can be calculated
according to the time-domain approach given above. The ramp-like input signal has been
applied to the process inputs. The process open-loop responses are shown in Figure 4.
Process GP1: Open−loop response Process GP2: Open−loop response
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
0 10 20 30 40 0 10 20 30
time [s] time [s]
Process G : Open−loop response Process G : Open−loop response
P3 P4
1
1
0.5 0.8
0 0.6
−0.5 0.4
0.2
−1
0
−1.5
0 5 10 15 20 0 5 10 15 20
time [s] time [s]
Fig. 4. The process input (--) and the process output (__) signals during an open-loop
experiment for processes GP1 to GP4.
www.intechopen.com
86 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
The moments are calculated by using expressions (17) and (18) and the controller
parameters by using expressions (25), (28) and (29). The calculated parameters are given in
Table 1.
1.2 1.2
1 1
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
0 10 20 30 0 20 40 60
time [s] time [s]
Process GP3: Closed−loop responses Process GP4: Closed−loop responses
1.5 1.4
1.2
1
1
0.5 0.8
0 0.6
0.4
−0.5
0.2
−1 0
0 20 40 60 0 20 40 60
time [s] time [s]
Fig. 5. Closed-loop responses for processes GP1 to GP4 when using PID controller (__), PI
controller (--) and I controller (-.-) tuned by the MOMI method.
The results can be verified by calculating the moments and controller parameters directly
from the process transfer functions (37). The moments can be calculated from expression
(20). The controller parameters are calculated as before. The obtained parameters are given
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 87
in Table 2. It can be seen that the values are practically equivalent, so the closed-loop
responses are the same to those shown in Figure 5.
Fig. 6. Picture of the laboratory hydraulic setup (taken in stereoscopic side-by-side format).
The selected control loop consists of the reservoir R0, the pump P1, an electronic valve V1
(open), a valve V3 (partially open) and water columns R1 and R2. The valve V2 is closed and
the pump P2 is switched off. The process input is the voltage on pump P1 and the process
output is the water level in the second tank (h2), measured by the pressure to voltage
transducer. The actual process input and output signals are voltages measured by an A/D
and a D/A converter (NI USB 6215) via real-time blocks in Simulink (Matlab).
www.intechopen.com
88 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
R1 R2 R3
LT LT LT
1 2 3
R0 h1
h2
h3
V1 V2
P1
V3
P2
ur = 10 ⋅ u , (38)
The control output signal u is limited between values 0 and 10. The pump actually starts
working when signal ur becomes higher than 1V.
Note that artificially added non-linearity cannot ideally linearise the non-linearity of the
process gain. Moreover, the process time constants still differ significantly at different
working points.
After applying the non-linear function (38), the open-loop process response has been
measured (see Figure 9). The moments (areas) have been calculated by using expressions
(17) and (18):
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 89
3.5
2.5
1.5
1
0 200 400 600 800 1000 1200 1400
t [s]
1.5
0.5
0 200 400 600 800 1000 1200 1400
t [s]
Fig. 8. The process input and process output responses over the entire working region.
The calculated PID controller parameters, for an a priori chosen filter parameter TF=1s, were
the following (the proportional gain has been limited to the value KP=10/A0):
0.9
0.8
0.7
0.6
0.5
0.4
200 250 300 350 400 450
t [s]
1.3
1.2
1.1
0.9
0.8
200 250 300 350 400 450
t [s]
www.intechopen.com
90 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
The closed-loop response of the process with the controller was calculated in the previous
step, as shown in Figure 10. At t=300s, the set-point has been changed from 1.2 to 1.5 and at
t=900s it is returned back to 1.2. A step-like disturbance has been added to the process input
at t=700s and t=1300s. It can be seen that the closed-loop response is relatively fast (when
compared to the open-loop response) and without oscillations.
1.5
1.4
1.3
1.2
1.1
1
400 600 800 1000 1200 1400
t [s]
0
400 600 800 1000 1200 1400
t [s]
Fig. 10. The process closed-loop response in the hydraulic setup when using the PID
controller tuned by the MOMI method.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 91
1
GP 1 ( s ) =
( 1 + 6s )
1
GP 2 ( s ) =
( 1 + 3s )2
(41)
1
GP 3 ( s ) =
( 1 + s )6
e −5s
GP 4 ( s ) =
1+s
Two of them (GP3 and GP4) are the same as in the previous section (37) while we added two
lower-order processes in order to clearly show the degraded disturbance-rejection
performance. The moments and controller parameters for the chosen processes are given in
Table 3. Note that the proportional gain has been limited to 10 for GP1 and GP2.
Moments (areas) PID PI I
A1 A2 A3 A4 A5 KI KP KD TF KI KP KI
GP1 6 36 216 1296 7776 1.75 10 0 0 1.75 10 0.08
GP2 6 27 108 405 1458 1.69 10 14.5 0.2 0.25 1 0.08
GP3 6 21 56 126 252 0.22 0.87 0.96 0.2 0.15 0.4 0.08
GP4 6 18.5 39.3 65.4 91.4 0.16 0.49 0.45 0.2 0.13 0.27 0.08
Table 3. The values of the moments and controller parameters for processes (41) using the
MOMI method.
A step-like disturbance (d) has been applied to the process input (see Figure 1). The process
output responses are shown in Figure 11. It is clearly seen that the closed-loop responses of
the processes GP1 and GP2, when using the PI and the PID controllers, are relatively slow
with visible “long tails” (exponential approaching to the reference).
It is obvious that the MO criteria should be modified in order to achieve a more optimal
disturbance rejection. The closed-loop transfer function between the disturbance (d) and the
process output (y) is the following:
Y (s) GP ( s )
GCLD ( s ) = = (42)
D(s) 1 + GC ( s ) GP ( s )
However, the function GCLD (42) cannot be applied instead of GCL in expressions (6) and (7),
since GCLD has zero gain in the steady-state (s=0). However, by adding integrator to function
(42) and multiplying it with KI, it complies with the MO requirements (Vrančić et al., 2004b;
2010):
KI K I GP ( s )
GCLI ( s ) = GCLD ( s ) = (43)
s s ( 1 + GC ( s ) GP ( s ) )
www.intechopen.com
92 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
However, the expression for the PID controller parameters – due to higher-order equations –
is not analytic and the optimisation procedure should be used (Vrančić et al., 2010). Initially,
the derivative gain KD is calculated from expression (25). As such, the proportional and
integral term gains are calculated as follows (Vrančić et al., 2010):
β − β 2 − αγ
KP =
α
* 2 , (44)
KI =
(1 + K A )
P 0
2 (K A + A )
*2
D 0
*
1
where
(
β = A1* A2* − A0* A3* + K D A0* A1*2 − A0*2 A2* ) . (45)
γ = 3 *4
KD A0 2 *2 *
+ 3K D A0 A1 (
+ K D 2 A0* A2* + A1*2 )+ A3*
The optimisation iteration steps consist of modifying the derivative gain KD and re-
calculating the remaining two parameters from (44) until the following expression becomes
true (Vrančić et al., 2010):
−4 A0 A4 K I K D − 2 A3K D + 2 A4 K P − 2 A5K I + 2 A0 A4 K P2 − 2 A0 A2 KD
2
−
. (46)
−2 A1 A3K P2 − 2 A22 K I K D + A12 K D
2
+ A22 K P2 + 4 A1 A3K DK I = 0
Any method that employs an iterative search for a numeric solution – that solves the system
of nonlinear equations – can be applied. However, in Vrančić et al. (2004a) it was shown that
the initially calculated parameters of the PID controller are usually very close to optimal
ones. Therefore, a simplified (sub-optimal) solution is to use only the initial PID parameters.
In the following text, the simplified version will be applied and denoted as the DRMO
tuning method.
Note that the PI controller parameters do not require any optimisation procedure. The
derivative gain is fixed at KD=0 and the PI controller parameters are then calculated from
expression (44).
The PID controller tuning procedure, according to the DRMO method, can therefore
proceed as follows:
• If the process model is not known a priori, modify the process steady-state by changing
the process input signal.
• Find the steady-state process gain KPR=A0 and moments A1-A5 by using numerical
integration (summation) from the beginning to the end of the process step response
according to expressions (17) and (18). If the process model is defined, calculate the gain
and moments from expression (20).
• Fix the filter time constant TF to some desired value and calculate moments and the
derivative gain KD from (24) and (25). Calculate the remaining controller parameters
from expression (44). If the value α=0 or if the proportional gain KP is too high or has a
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 93
different sign to the process gain (KPR=A0), set KP manually to some more suitable value
and then recalculate KI from (44).
• The PI controller parameters can be calculated by fixing KD=0 and using expression
(44). If the value α=0 or if the proportional gain KP is too high or has a different sign to
the process gain (KPR=A0), set KP manually to some more suitable value and then
recalculate KI from (44).
Process G : Closed−loop responses Process G : Closed−loop responses
P1 P2
0.8 0.8
0.6 0.6
0.4 0.4
0.2 0.2
0 0
−0.2 −0.2
0 10 20 30 40 0 10 20 30 40 50
time [s] time [s]
Process G : Closed−loop responses Process G : Closed−loop responses
P3 P4
1.5 1.2
1
1
0.8
0.6
0.5
0.4
0.2
0
0
−0.5 −0.2
0 10 20 30 0 10 20 30 40
time [s] time [s]
Fig. 11. Closed-loop responses to step-like input disturbance (d) for processes GP1 to GP4
when using a PID controller (__), a PI controller (--) and an I controller (-.-) tuned by the
MOMI method.
The proposed DRMO tuning procedure will be illustrated by the same four process models
(41), as before. The PID and PI controllers’ parameters are calculated by the procedure given
above. Note that the I controller parameters remain the same as with the MOMI method
(29). The parameters for all of the controllers are given in Table 4.
Moments (areas) PID PI I
A1 A2 A3 A4 A5 KI KP KD TF KI KP KI
GP1 6 36 216 1296 7776 10.1 10 0 0 1.75 10 0.08
GP2 6 27 108 405 1458 2.92 10 14.5 0.2 0.25 1 0.08
GP3 6 21 56 126 252 0.27 0.97 0.96 0.2 0.17 0.43 0.08
GP4 6 18.5 39.3 65.4 91.4 0.18 0.52 0.45 0.2 0.14 0.29 0.08
Table 4. The values of moments and controller parameters for processes (41) using the
DRMO method.
www.intechopen.com
94 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
A step-like disturbance (d) has been applied to the process input. The process output
responses, when using the PID and the PI controllers, are shown in Figures 12 and 13. It can
be clearly seen that the closed-loop performance for processes GP1 and GP2 is now improved
when compared with the original MOMI method.
However, improved disturbance-rejection has its price. Namely, the optimal controller
parameters for disturbance-rejection are usually not optimal for reference following.
Deterioration in tracking performance, in the form of larger overshoots, can be expected for
the lower-order processes. A possible solution for improving deteriorated tracking
performance, while retaining the obtained disturbance-rejection performance, is to use a 2-
DOF PID controller, as shown in Figure 1. Namely, it has been shown that tracking
performance can be optimised by choosing b=c=0 (Vrančić et al., 2010). The closed-loop
responses on a step-wise reference changes and input disturbances (at the mid-point of the
experiment) are shown in Figures 14 and 15. It can be seen that the overshoots are reduced
when using b=c=0 while retaining disturbance-rejection responses.
0.02 0.02
0 0
−0.02 −0.02
0 10 20 30 40 0 10 20 30 40
1
1 MOMI method 0.8
DRMO method
0.6 MOMI method
0.5
0.4 DRMO method
0.2
0
0
−0.5 −0.2
0 10 20 30 40 0 10 20 30 40
time [s]
Fig. 12. A comparison of process output disturbance-rejection performance for processes GP1
to GP4 when using a PID controller tuned by the MOMI (__) and DRMO (--) tuning methods.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 95
0.02 0.2
0.1
0
0
−0.02 −0.1
0 10 20 30 40 0 10 20 30 40
1
1
0.8
0.2
0
MOMI method 0
DRMO method
−0.5 −0.2
0 10 20 30 40 0 10 20 30 40
time [s]
Fig. 13. A comparison of process output disturbance rejection performance for processes GP1
to GP4 when using a PI controller tuned the by MOMI (__) and DRMO (--) tuning methods.
www.intechopen.com
96 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
Process GP1 output: Closed−loop response Process GP2 output: Closed−loop response
1.4 1.4
1.2 1.2
1 1
0.8 0.8
0.6 0.6
b=0 b=0
0.4 b=1 0.4 b=1
0.2 0.2
0 0
0 5 10 15 20 0 20 40 60
Process GP3 output: Closed−loop response Process GP4 output: Closed−loop response
2 2
1.5 1.5
1 1
0.5 0.5
b=0 b=0
b=1 b=1
0 0
0 20 40 60 80 0 20 40 60 80
time [s]
Fig. 14. Process output tracking and disturbance-rejection performance for processes GP1 to
GP4 when using a PID controller tuned by the DRMO tuning method for the controller
parameters b=c=0 and b=c=1.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 97
Process GP1 output: Closed−loop response Process GP2 output: Closed−loop response
1.4 1.5
1.2
1
1
0.8
0.6
b=0 0.5 b=0
0.4 b=1 b=1
0.2
0 0
0 5 10 15 20 0 20 40 60
Process GP3 output: Closed−loop response Process GP4 output: Closed−loop response
2 2
1.5 1.5
1 1
0.5 0.5
b=0 b=0
b=1 b=1
0 0
0 20 40 60 80 0 20 40 60 80
time [s]
Fig. 15. Process output tracking and disturbance-rejection performance for processes GP1 to
GP4 when using a PI controller tuned by the DRMO tuning method for the controller
parameters b=c=0 and b=c=1.
The DRMO tuning method will be illustrated on the same three-water-column laboratory
setup, described in the previous section. According to the previously calculated values of
moments (39), the PID controller parameters are the following (the proportional gain has
been limited to value KP=10/A0) for the chosen TF=1s:
The closed-loop responses, when setting the parameter b=c=0.1, are shown in Figure 16.
Similarly, as with the MOMI method, the set-point has been changed from 1.2 to 1.5 at
t=300s and is returned to 1.2 at t=900s. A step-like disturbance has been added to the process
input at t=700s and t=1300s. The disturbance rejection performance is now improved when
compared with Figure 10. A comparison of responses obtained by the MOMI and the
DRMO methods with PID controllers is shown in Figure 17. It is clear that the tracking
response is slower and with a smaller overshoot, while the disturbance-rejection is
significantly improved.
www.intechopen.com
98 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
1.5
1.4
1.3
1.2
1.1
1
400 600 800 1000 1200 1400
t [s]
0
400 600 800 1000 1200 1400
t [s]
Fig. 16. The process closed-loop response in the hydraulic setup when using the PID
controller tuned by the DRMO method.
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 99
Tracking response
1.7
1.6
1.5
1.4
1.3
DRMO method
1.2 MOMI method
1.1
1
300 350 400 450 500 550 600
t [s]
1.51
1.5
1.49
1.48
650 700 750 800 850
t [s]
Fig. 17. A comparison of the process closed-loop responses in the hydraulic setup with PID
controllers tuned by the MOMI and DRMO methods.
6. Conclusion
The purpose of this Chapter is to present tuning methods for PID controllers which are
based on the Magnitude Optimum (MO) method. The MO method usually results in fast
and stable closed-loop responses. However, it is based on demanding criteria in the
frequency domain, which requires the reliable estimation of a large number of the process
parameters. In practice, such high demands cannot often be satisfied.
It was shown that the same MO criteria can be satisfied by performing simple time-domain
experiments on the process (steady-state change of the process). Namely, the process can be
parameterised by the moments (areas) which can be simply calculated from the process
steady-state change by means of repetitive integrations of time responses. Hence, the
method is called the “Magnitude Optimum Multiple Integration” (MOMI) method. The
measured moments can be directly used in the calculation of the PID controller parameters
without making any error in comparison with the original MO method. Besides this, from
the time domain responses, the process moments can also be calculated from the process
transfer function (if available). Therefore, the MOMI method can be considered to be a
universal method which can be used either with the process model or the process time-
responses.
www.intechopen.com
100 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
The MO (and therefore the MOMI) method optimises the closed-loop tracking performance
(from the reference to the process output). This may lead to a degraded disturbance-
rejection performance, especially for lower-order processes. In order to improve the
disturbance-rejection performance, the MO criteria have been modified. The modification
was based on optimising the integral of the closed-loop transfer function from the process
input (load disturbance) to the process output. Hence, the method is called the
“Disturbance-Rejection Magnitude Optimum” (DRMO) method.
The MOMI and the DRMO tuning methods have been tested on several process models
and on one hydraulic laboratory setup. The results of the experiments have shown that
both methods give stable and fast closed-loop responses. The MOMI method optimises
tracking performance while the DRMO method improves disturbance-rejection
performance. By using a two-degrees-of-freedom (2-DOF) PID controller structure, the
optimal disturbance-rejection and improved tracking performance have been obtained
simultaneously.
The MOMI and DRMO methods are not limited to just PID controller structures or stable
(self-regulatory) processes. The reader can find more information about different controller
structures and types of processes in Vrančić (2008), Vrančić & Huba (2011), Vrečko et al.,
(2001), Vrančić et al., (2001b) and in the references therein.
The drawback of the MO method (and therefore the MOMI method and, to an extent, the
DRMO method) is that stability is not guaranteed if the controller is of a lower-order than
the process. Therefore, unstable closed-loop responses may be obtained on some processes
containing stronger zeros or else complex poles. Although the time-domain implementation
of the method is not very sensitive to high-frequency process noise (due to multiple
integrations of the process responses), the method might give sub-optimal results if low-
frequency disturbances are present during the measurement of the process steady-state
change.
7. Acknowledgments
The author gratefully acknowledges the contribution of the Ministry of Higher Education,
Science and Technology of the Republic of Slovenia, Grant No. P2-0001.
8. References
Åström, K. J., & Hägglund, T. (1995). PID controllers: Theory, design, and tuning.
Instrument Society of America Research Triangle Park (2nd ed.).
Åström, K. J., Panagopoulos, H. & Hägglund, T. (1998). Design of PI Controllers based on
Non-Convex Optimization. Automatica, 34 (5), pp. 585-601.
Ba Hli, F. (1954). A General Method for Time Domain Network Synthesis. IRE Transactions
– Circuit Theory, 1 (3), pp. 21-28.
Gorez, R. (1997). A survey of PID auto-tuning methods. Journal A. Vol. 38, No. 1, pp. 3-10.
Hanus, R. (1975). Determination of controllers parameters in the frequency domain. Journal
A, XVI (3).
www.intechopen.com
Magnitude Optimum Techniques for PID Controllers 101
www.intechopen.com
102 Introduction to PID Controllers – Theory, Tuning and Application to Frontier Areas
www.intechopen.com
Introduction to PID Controllers - Theory, Tuning and Application to
Frontier Areas
Edited by Prof. Rames C. Panda
ISBN 978-953-307-927-1
Hard cover, 258 pages
Publisher InTech
Published online 29, February, 2012
Published in print edition February, 2012
This book discusses the theory, application, and practice of PID control technology. It is designed for
engineers, researchers, students of process control, and industry professionals. It will also be of interest for
those seeking an overview of the subject of green automation who need to procure single loop and multi-loop
PID controllers and who aim for an exceptional, stable, and robust closed-loop performance through process
automation. Process modeling, controller design, and analyses using conventional and heuristic schemes are
explained through different applications here. The readers should have primary knowledge of transfer
functions, poles, zeros, regulation concepts, and background. The following sections are covered: The Theory
of PID Controllers and their Design Methods, Tuning Criteria, Multivariable Systems: Automatic Tuning and
Adaptation, Intelligent PID Control, Discrete, Intelligent PID Controller, Fractional Order PID Controllers,
Extended Applications of PID, and Practical Applications. A wide variety of researchers and engineers seeking
methods of designing and analyzing controllers will create a heavy demand for this book: interdisciplinary
researchers, real time process developers, control engineers, instrument technicians, and many more entities
that are recognizing the value of shifting to PID controller procurement.
How to reference
In order to correctly reference this scholarly work, feel free to copy and paste the following:
Damir Vrančić (2012). Magnitude Optimum Techniques for PID Controllers, Introduction to PID Controllers -
Theory, Tuning and Application to Frontier Areas, Prof. Rames C. Panda (Ed.), ISBN: 978-953-307-927-1,
InTech, Available from: http://www.intechopen.com/books/introduction-to-pid-controllers-theory-tuning-and-
application-to-frontier-areas/tuning-of-pid-controllers-based-on-magnitude-optimum