Design and Implementation of A Self-Tuning Pid Controller
Design and Implementation of A Self-Tuning Pid Controller
Design and Implementation of A Self-Tuning Pid Controller
Abstract: PID control schemes based on the classical control theory, have been
widely applied to real control systems, and there have been a lot of works on the
tuning of PID parameters, as they affect control performance. Several self-tuning
and auto-tuning PID techniques have been reported for systems with unknown or
slowly time-varing parameters. None, however, is applicable to discrete-time system
with unknown dead time. In this paper. a self-tuning PID control algorithm is
proposed based on the relationship between the PID control law and the generalized
minimum variance control law which is one of self-tuning control strategies. The
proposed control scheme is practically evaluated on a temperature control system
of a polybutene reactor. COpyright © 1998 IFAC
59
alized minimum variance control( G~IVC)( Clarke formance of the control system strongly depends
and Gawthrop. 1979) laws. a design scheme of self- on them . For systems with unknown parameters
tuning PID controllers is proposed . Finally, an im- and unknown time-delays. however. it is difficult
plementation of the proposed control scheme for to find the " optimal" PID gains easily. There-
a temperature control system of a polybutene re- fore , a self-tuning PID control algorithm based on
actor is considered , and the effectiveness is prac- the relationship between PID control and gener-
tically evaluated by applying it to the polybutene alized minimum variance control(G~IVC) laws, is
process. derived below .
2.2 PID Controller design Next, based on the relationship between PID con-
Next , the following digital PID control law to be trol and GMVC laws, a tuning method of PID
considered in this paper is described as: parameters is derived. Usually the dynamics of
Ts the system to be controlled, for example, the time-
t:.:u(t) = k c [{ e(t) - e.(t - I)} + T e ft)
, delays or the time constants, are rarely known pre-
cisely in advance . In particular, knowledge of the
+ -Td { e( t) - 2e( t - 1) + e.(t - 2)}] (4) delay is important . Here, the strategy is adopted ,
Ts
that km is under estimated i.e., initially use the
where e( t) denotes the control error signal given upperbound estimate of the delay, or assume that
by the order of B(z-l ) is large enough, in order to
e(t) := wit) - y(t) (5) cope with the above problem. Therefore, the es-
and kc, Ti and Td are the proportional gain , the re- timates km and B(z-l), i.e., the second term in
'set time and the derivative time, respectively. Fur- (10) , E(z-l )B(z-I) , includes some uncertainties.
thermore , Ts denotes the sampling interval. For In order to obtain a control law with a PID struc-
convenience, let C(z-l) be ture, consider the following control law replaced
Ts Td E(z-l)B(z-l) by the static gain £(I)B(I) :
C (z- I ) : = k c ( 1 + - + -) F(z-l)y(t) + {E(I)B(1) + A}lw(t)
T; Ts
2Td ) -1 kc T d_2 - R(z-l)w(t) = O. (13)
- k'c ( 1 + - z +- -z
Ts Ts Here, /1 is defined as
= Co + CIZ-1 + czz - z (6) v := E(I)B(I) +A (14)
then , (-!) can be rewritten by then, (13) can be rewritten by
C(z-l)y(t) + ~'U(t) - C (z-l )w(t) = O. (7) Flz- 1 ) R(z-l )
---y(t) + ~u(t) - . leU) = O. (15)
The tuning of the control parameters in PID con- v v
trol laws (4) or (7), is important, since the per- Furthermore, if the following relations are satis-
60
£led: dra. 1982 : Goodwin and Sin. 1984) :
= F(Z-l)
~
fl(z-l ) rll - 1) 1/J (t - 1)
fj(t.) = &(1.-1)+ 11ft )
f'(Z - I) (16) 1 +Ii-,T(I - 1)[(t - 1)1/J(t - 1)
C(Z-l ) = . .
I1 J (22)
then (15) becomes identical to (7). Therefore. f(O = ~ [r(t - 1)
based on (6) and (16) , PID parameters can be vJ
calculated as follows: _ fU - l)I/JU - 1)4)T(l- l )fU - 1) ]23
1 vJ + 1j;T(t, - l)f(1 - 1)1/J(t - 1) ( )
kc = --rh
v
+ 2fz)
T - _ h +2fz T c(t) = Yf(t) - (]TU - 1)1/I(t - 1) (24)
( 17)
t - fo + it + fz s
( >d
c(t) -tll(t) = c(t) - d
T--
d -
fz
it + 2fz
T
s· II(t) = ~ Ic(t)1 S d -tl/(t) = 0 (25)
l c(t) < -d -t If(t) = c(t) + d
Note that the parameter A is related to only k c .
where w is a forgetting factor given by 0 < w < 00 ,
In other words, T[ and T D are independent of A.
and c( t) is a prediction error. Also, 2d( > 0) in
Thus, the proposed scheme has a feature such that
after selecting p(z-l) in (8) or (9), A can be deter- (25) is the width of the dead zone. iJ(t) and 1/I(t-
mined or chosen independently by considering the 1) are the unknown parameter and data vectors,
respectively, i. e.,
stability of the control system based on a priori
- '" T
information. For example, the Bode diagram can (}(t) = [til(t) , a2(t) , bo(t) , b1(t), · · ., bm(t)] (26)
be utilized to determine A. Such a design method
for selecting A is discussed in detail in section 4.2.
I/J(t - 1) = [-Yf (t - 1), -Yf(t - 2) , 'u f(t - km - 1),
" ', 'uf(t - km - m - 1)]T .
(27)
The design method of P(z-l) is discussed below.
P(z-l) is designed based on the following two fea- In (25) and (27), the subscript " denotes the fil-
tures which allow one to select the response shape, tered values of the inputs and outputs, and they
overshoot, settling time, etc. are given by
Shigemasa et al. (1983) have presented a practical D(Z-l) is designed as the low-pass filter or the
method to design the reference model based on the band-pass filter. The filters are usually used for
above features in the continuous-time systems. By the purpose of improving reliability of the param-
transforming these features into the discrete-time, eter estimation in real systems.
the following coefficients can be obtained: Next , by solving the Diophantine equation (11)
_.£.. .j4J.L - 1 based on estimates included in iJ( t), and calcu-
PI = -2e ~"cos( p) (18)
2J.L lating (14) and ( 17) , PID parameters can be ob-
tained .
P2 = e-; (19)
The proposed self-tuning PID control algorithm is
where p and J.L are defined by
then realized via the following steps.
fl := Ts l o (20)
:Self. Tuning PID control algorithm]
J.L := 0.25(1 - b) + 0 .510 ( 21) 1. Choose p(z-l ) and A.
and 0 and J.L denote the rise-time and the damp- 2 . Design the estimator filter D(z-l) .
ing index , respectively. Here, the binomial model 3. Estimate iJ(t) by using the RLS algorithm in
response can be obtained for I> = 0, and the But- (22)-(28).
terworth model response for 6 = 1.0. Although 4 . Solve the Diophantine equation (11).
the response shape can be chosen to one's liking 5. Calculate PID parameters based on (14) and
by changing the parameter {; , (; should be set to be- ( 17).
tween 0.0 and 2.0 practically. On the other hand , 6 . Calculate the control inputu( t) based on
0i corresponding to the rise time, can be set to be-
( 4) .
tween 1/ 3 and 1/ 2 of the time constant depending 7. Update t and return to 3 .
on the practical needs.
First. unknown parameters included in (1 ) are es- 3.1 Outline of the polybutene process
timated by using the following least squares(RLS) In a polybutene plant . the object system products
algorithm with a dead zone (Peterson and Naren- of C 4 distillation (butene, isobutene and so on)
61
are polymerized by injection of a catalyst . Since 1~ : the temperature conducted at the heat
the thermal polymerization reaction is exother- exchanger [K]
mic , the temperature in the reactor must be strictly Fe: the flow of the coolant [kmol / s]
controlled. However. since a change in the oper- kex : the temperature gain outside of the heat
ating conditions or catalyst activity disturbs the exchanger to the change of the coolant
temperature control. the constant human inter- flow
vention and monitoring are required currently. T( : the time lag by holding up the tempera-
A schematic diagram of the polybutene reactor is ture inside of the heat exchanger [s]
shown in Fig.l. ='Iext, from the pressure balance in the reactor and
the heat balance owing to the heat exchanger, it
is found that the temperature Tr in the reactor is
expressed as the first order element to the temper-
ature Tc of the heat exchanger.
62
to sixtv times 1"5 for saletv . .-i.lld the svstem ;6.2r
l ------------------
identificatioll and P ID parameter calculation ;I? ~ 1
it 1~ (\ r\ ,il r\l\ri!A~ fl J
are carried out by using the last 250 sampled
d ata at each T5 C-
16.0~ · ~ .. ·.. V
·y-i.. ~(1· \ ..~·ff..~·r'rt ·~t1
· 0
:2] The following band-path filter D(::-l ) is em-
:
ployed for the input and output sampled data
of the plant in order to smooth the observa-
tion noise. and to remove the trend owing to
, ri' ~ IVJ ,', tJ! Operator tun ing PlO ' Self tuning PlO
the change of the catalyst activity.
1 5 .80=-----'--:-4-::-00:;;---'---;:8:-::0-;::0--'--'-;1-:::2':::0::::-0---L---:1:-::6-!;:,0c:::'0
1-/l 1 + :: - 1 1+ , j 1-:: - 1
0(::-1 ) = (__ )( __ ) t [step]
21-0::- 1 21-d:: - 1
(32) 90.0.---r--,---.-.--.--.-----r-........-,
J:~~: . ": I :d
50
i ·~lliT'
.~.
.50 '
. : :
! - - -·-
i ·- -·- · -· -' : - - '-_ . _ ._ ._ ._ ._. _. · .,---_ _ _ _........Jl
0.0 ~---'---~40:':-:O~~-:;::-80:':-:0~~~1~2~0~0~---:1~6~O~0
t [step]
1 1
10" 10 10
Frequency I(~d/secl Fig.5 . PlO parameters trajectories corresponding
to Fig...!.
63
respectivelv set to 0 and 3. furthermore.~· = tomatic Controls. Trans. AlEE. 70 . 606-61l.
O. 99( the forgett ing factor) and 2d = O.H t he dead :\ishikawa. Y .. T . Ohta and H. Tanaka (1984) . A
zone width) in the parameter estimation. The re- ~lethod for Auto- Tuning of PID Control Pa-
sults of the estimator to compute PID parameters rameters . Automatica. 20 . 321-332 .
are shown in Fig.5. Peterson. B .B. and K . S.~arendra (1982). Bound-
These results suggest that the newly proposed self- ed Error Adaptive Control. IEEE Trans. on
tuning PID control scheme is applicable to a real A utomatzc Control. 27-6 . 1161- 1168.
plant of which dynamics varies considerably. if ap- Proudfoot . C.G .. P.J . Gawthrop and O.L.R. Ja-
plied carefully. cobs (1983). Self-Tuning PI Control of a PH
:\eutralisation Process. Proc. lEE. l30D .
267-272 .
4. CONCLUSIONS
Radke. F . and R. lsermann (1987). A Parameter-
In this paper, a self-tuning PID control scheme Adaptive PID-Controller with stepwise Pa-
has been proposed based on the relationship be- rameter Optimization. Automatica, 23. 449-
tween the PID control and the GMVC laws. Also, 457.
a method for designing the parameter A and the Shigemasa. T. , Y . Takagi, Y. Ichikawa and T. Ki-
polynomial P(z-l) included in the cost function tamori (1983). A Practical Reference Model
of the GMVC law has been discussed, which are for Control System Design(in Japanese) .
selected based on some a priori information about Trans. on SICE, 19, 592-594.
the process. Finally, the effectiveness of the newly Takahashi. Y ., C.S . Chan, D.M . Auslander (1971).
proposed control scheme has been shown by prac- Parametereinstellung bei Linearen DDC-
tical evaluation on a temperature control system Algorithmen , Regelungstechnik und Prozej:J-
of a polybutene reactor. Especially, the control re- Datenverarbeitung. Verlag R. Oldenbourg, 19 ,
sults illustrate that the proposed scheme is appli- 237-644 .
cable to a real plant whose dynamics varies with Wellstead, P.E . and M .B.Zarrop (1991) . Self-Tun-
the catalyst activity and the change of product ing Systems, Control and Signal Processing,
grade. Transition control in the change of prod- John Wiley & Sons Ltd.
uct grade is currently under investigation. Ziegler. J .G. and N.B. Nichols (1942) . Optimum
Settings for Automatic Controllers, Trans.
REFERENCES ASME, 64, 759- 768.
Astrom. K.J. (1983). Theory and Applications
of Adaptive Control-A Survey. Automatica,
19, 471-486 .
Astrom , K.J. and T. Hiigglund (1984) . Automatic
Tuning of Simple Regulators with Specifica-
tions on Phase and Amplitude Margins.
Automatica, 20, 645-651.
Astrom. KJ. and T . Hiigglund (1988). Automatic
Tuning of PID Controllers. Instrument Soci-
ety of America. Research Triangle Park.
Astrom. K.J. and BWittenmark (l989\. Aaavtive
Control. Addison- \Veslev.
Cameron. F. and D .E. Seborg (1903 ). A Self-
Tuning Controller with a PID Structure . Int.
1. Control. 38 . 401-417.
Chien. K .L.. J .A . Hronesand J.B. Reswick (1952).
On the Automatic Control of Generalized
Passive Systems. Trans . ASME. 74.175-185.
Clarke. D .W. and P.J . Gawthrop (1979) . Self-
Tuning Control. Proc. lEE. l26D. 633-640.
Fujii. K .. T .Yamamoto and M .Kaneda (1997).
Self- Tuning PID Control of a Polybutene Pr~
cess. Proc. of IFAC International Sympost'Um
on Advance Control of Chemical Processes.
BanfI. 103-108.
Gawthrop. P.J . (1986). Self-Tuning PID Controller
: Algorithms and Implementation. IEEE
Trans .. AC-31. 201-209.
Goodwin. G.C. and K.S . Sin (1984). Adaptwe Fil-
termg Prediction and Control. Prentice-Hall.
~ew Jersey.
~ims . P.T. (1950) . Some Design Criteria for Au-
64