Copyright @ IF AC Advanced Control of Chemical Processes, Pisa, Italy, 2000
STABILITY OF A PI-CONTROLLED NONLINEAR SYSTEM
Hector M. Budman 1 and Timothy Knapp
Department o/Chemical Engineering University 0/ Waterloo Waterloo, Ontario, CANADA N2L3GI
Abstract: This paper studies two methods to reduce the conservatism of the stability analysis of a PI-controlled non linear process: I-gain scheduling and 2-parameter affine Lyapunov functions. The use of a gain-scheduled PI controller was found to allow for a significant increase in the proportional gain compared to the fixed controller case, resulting in more aggressive control. In contrast, the use of the parameter-affine Lyapunov function lead to only a marginal reduction of conservatism of the stability test compared to the case where a parameter independent function is used. Copyright © 2000 IFA C. Keywords: State-affine models, Stability, LMI's, Nonlinear systems
approach is more systematic that the conventional search for a Lyapunov function, the method requires that:
1. INTRODUCTION This paper deals with the closed loop stability of a nonlinear process controlled by a PI controller. When a mathematical model of the nonlinear process is available, two approaches has been proposed in the past to test the closed loop stability: i- Find a Lyapunov function for the specific process under consideration ii- Represent the nonlinear system by a nominal linear model augmented by time varying bounded perturbations that account for the nonlinearities with respect to the nominal model. Then, test the stability using a scaled maximal singular value test. The main difficulty in the first approach is to find an appropriate Lyapunov function for the system that will lead to non-conservative results. This task will be generally accomplished through a trial and error procedure. The second approach was originally proposed by Doyle et al (1990) and applied for testing the stability of a CSTR (Continuous Stirred Tank Reactor) under linear control. Although this
i- a mechanistic first principle model of the process is available ii- an optimisation procedure will be carried out to find bounds on the perturbations representing the system nonlinearities. Unfortunately, in many situations, a nonlinear mathematical model of the process is not readily available from first principles. For instance, for biological reactors, the reaction kinetics is often unknown or very difficult to measure. Additionally, the optimisation procedure proposed by Doyle to calculate perturbation bounds may become very difficult when the model contains a large number of states. Therefore, to circumvent these difficulties, Knapp and Budman (1999) propose to model the system with an empirical model of state affine type (SA-model) given as follows:
1 Author to whom correspondence should be addressed, e-mail:
[email protected]. phone: 519-8884567 ext 6980, fax : 519-746-4979
51
!(t + I) = F{u{t ))!{t)+ G{u{t)) y{t) = H{u{t)l!{t)
(I)
Where! is the state vector and F(.), H(-) and G( .) are polynomial matrices. Thus, for example, F(u(t))=Fo +F1u+F2 u 2 +.. ..+Fnu n . In this work, only single input (u) single output (y) processes will be considered, The perturbations with respect to the nominal linear model are directly related to the powers of the input, i.e. u, J , ,; etc. Since in practice the inputs are bounded by known values, the optimisation procedure proposed by Doyle for computing perturbation bounds can be avoided, facilitating the application of the technique to systems with a large number of states. The fact that the model in (I) is identified from data eliminates the need for a first principle model. Using the SA models, Knapp and Budman formulated a stability test as a set of LMl's (Linear Matrix Inequalities) that may be solved using commercially available software. However, one common problem to the works of Doyle et ai, and Knapp and Budman is that they still produce conservative closed loop control designs. Consequently, in the current work, two different alternatives will be tested to make the design technique, proposed by Knapp and Budman, less conservative. The two options considered are as follows : 12-
Gain-scheduled PI control. Parameter dependent Lyapunov function .
Gain scheduling is a widely accepted technique used to control certain classes of nonlinear systems. Instead of seeking a robust LTI (Linear time invariant) controller for the whole operating window, gain scheduling consists in designing an LTI controller for each operating condition and in switching controllers when the operating condition changes.
The scheduling variable may be the input, the output or other time varying parameter of the system. The structure may be standard PI or a general time varying state feedback controller. For instance, Packard designs for LPV's will not produce generally PI controller structures. The closed loop stability was generally assessed in the past by studying the linearized system at different operating conditions. However, Shamma and Athans (1992) have shown examples where this type of analysis may lead to erroneous conclusions. Following Bequette's statements and to keep the practical relevance of the results, the present work is limited to PI control type only and the switching is effected at discrete values of the scheduling variable as done in industrial practice. It will be shown in a later section that when the input is selected as the scheduling variable, the stability of the nonlinear system under gain scheduled PI control can be tested by expanding the system of LMI ' s originally used by Knapp and Budman for fixed PI controllers. The second alternative to reduce the conservatism of the LMI stability analysis proposed by Knapp and Budman, is to use parameter dependent Lyapunov functions. Gahinet et al (1994) have proposed the use of parameter dependent Lyapunov functions to reduce the conservatism of stability results for a special class of models. The conditions given by Gahinet were developed for continuous systems whereas the state-affine models used by Knapp and Budman are discrete. Also, in Gahinet's work the issue of input saturation whereas it was accounted for in the present work. Consequently in the current work, a new set of conditions were developed to test the stability of the discrete models under consideration using Lyapunov functions that depend linearly with the scheduling variable, i.e. manipulated variable. Finally the two methods considered to reduce the conservatism of the results, i.e. gain scheduling and parameter dependent Lyapunov functions were applied and compared for a CSTR case study.
There are a number of decisions to be made when designing a gain scheduling controller: i- how the controller parameters are being switched/scheduled ii-the scheduling variable, iii- the controller structure and iv-closed loop stability. The parameters of the gain-scheduled controller may be changed continuously as a function of the scheduling variable or may be switched at discrete values of that variable. Bequette(1997) has recently reviewed in a comprehensive paper, gain-scheduling PI controller in the process industry. Bequette stated that most of the theoretical analysis has been based on continuous switching of the controller parameters (e.g. Becker and Packard, 1994.), while many of the (mostly unpublished) applications have probably used controllers switching at discrete values of the scheduling variable.
2. LMI's STABILITY TEST USING DISCRETE STATE AFFINE MODELS - REVIEW (KNAPP AND BUDMAN, 1999) In the absence of a mechanistic mathematical model, a NARMA (Nonlinear Autoregressive Moving Average) model can be easily identified from input output data using a conventional least squares fitting procedure. The NARMA model is not suitable for robust stability analysis due to the dependence of the output on past inputs and outputs raised to different powers and in different product combinations. If all these products and high order term will be assumed to be model uncertainty in a robustness analysis, a very conservative design generally results. On the
52
other hand, Knapp and Budman (1999) nonlinear discrete state-affine models, given in equation 1, are ideally suited for the robust stability test. They have the distinct advantage that the nonlinear terms, which are assumed in this work to be the source of model mismatch with respect to a nominal linear model, are a function of the current inputs u(t) only. This greatly facilitates the calculation of the uncertainty bounds since the inputs have a priori known limits due to e.g. actuator limits or economic constraint considerations. Then, for the purpose of robustness analysis, a minimal state affine model realization of the initially identified NARMA model was obtained using the method proposed by Diaz and Desrochers (1988). A minimal realization is sought to avoid conservatism in the robust stability analysis.
Ac =1 K C =_ c
(6)
'f I
c
Assuming that this controller is used to stabilise the process, set Y d (t) = 0 without loss of generality. Define a vector, 1](t)=[~(t)
{(t)f
To account for the saturation situation, the saturating c~ntroller can be formulated as a variable gain K c(t) as follows . Defme: (7)
The uncertainty of the system will be assumed to be the difference between the nonlinear model given by equation (1) and a nominal linear model defined by the linear terms of that equation, i.e. the affine model: ~,
+ I) = Fo!(t) + G 1u(t)
y(t) = Ho !(t)
Then the gain ofthe PI controller is given by:
ijO$'Y$1 (2)
(8)
else It is also assumed that all of the uncertainty in the nonlinear state affine model is due to the nonlinearity of the process around this operating point. It is therefore possible to describe the model uncertainty, &, in the form:
a; =u{ty
i =I, ... ,n
K c = K c = constant
Using equations (1)-(8) and the definition ofn :
(3)
Each input to a process is known to lie between a lower and an upper limit known during the design stage due to, for example, actuator constraints or economic considerations, thus :
(9)
Equation (9) may be written as:
(4)
1](t + 1) = A!l.(t)
The input u is normalised based on these bounds $1 . between -1 and 1, i.e. from (3)
(10)
la;1
Where A is a time varying matrix due to the time variation of the input u and consequently of a according to Equation (3). Since the entries in A are linear with respect to o's for '1'= 1 and linear with respect to 'I' when saturation occurs (i.e. u= S= 1 or l) , A may be represented by a polytope of matrices.
Since closed loop robust stability is desired, a linear controller is added to the process. A convenient form of linear controller to use for the analysis that follows is a state feedback controller given by:
~(t + I) = Ac~{t)+ Bce{t) u{t) =Cc ~{t)+ D ce{t)
Then, for this model a Lyapunov stability test can be formulated as follows . Assume a Lyapunov function :
(5)
Where A c, Bc, Cc, and Dc are functions of the control parameters, ~(t) is the controller internal state, and e(t) is the tracking error in the closed loop expressed as e(t) =YAt)-y(t) , Yd(t) being the desired
Vk =T/ TPri _k _k
Where P is positive definite . Then for stability:
setpoint of the process. In this work, a standard PI controller was desired and therefore the PI control parameters are related to A c, Bc, Cc, and Dc by :
53
(11)
Due to the convexity of the LHS in (12), to ensure stability it is sufficient to test this condition only at the vertices of the polyto pe defining A resulting in the following set ofLMI ' s: i = 1,2, ..... n
considered. A simplistic approach was taken as follows. The value of N, for the case study shown later, was selected arbitrarily . Then, following a simplistic rationale that higher gain values over larger ranges of the scheduling variable u will provide more aggressive control, the gains and switching values are selected from :
(13)
This LMI system is solved for P using Matlab . Then, vertices corresponding to the combinations of 'l' = 0 and 'l'=lfor u=landu=-1 have to be
max I[Kci
Kc!tU $1 ;-=0
s.t. system ofLMI's. and, uso =-1 and u sN =1 .
considered in the LMI stability test.
3. GAIN-SCHEDULED PI CONTROLLER
A second option to reduce the conservatism of the stability analysis give by (13), is to select a parameter dependent Lyapunov function (Gahinet et aI, 1994). A Lyapunov function of the form given by equation (11) is selected but with a time dependent weighting matrix P given by:
Where, P(k) is positive definite . The justification is that this form of P offers a larger number of parameters for the optimization problem solved with the equation (13) as compared to a fixed P. This may lead to less conservative results as compared to the constant P case.
The proportional gain K c is scheduled as follows : -I ~u < Us, u s, ~ U < u -'2
=Kc, K c =K Kc
C 2
(16)
4. PARAMETER DEPENDENT L YAPUNOV FUNCTION
Since the process under consideration is non linear, one way to reduce the conservatism is by applying a gain-scheduled controller. This will permit to select higher controller gains along a subspace of the range of operation. As stated in the introduction, the scheduling variable selected is the input u, the controller is PI and the switching will be effected at discrete values of the input u. Then, the system of LMI ' s in equation (13) can be expanded to account for a controller with parameters scheduled based on values of u. Let the operating window, (e .g., for a SI SO problem - I ~ u ~ I) be discretized into N different ranges where for each one of these ranges, different values of PI controller parameters are used. For simplicity, at this point the reset time 1" I is assumed constant whereas
for
+~USi -us~_,,]
Gahinet et al (1994) have previously studied this problem for continuous systems. Controller saturation was not considered in Gahinet ' s work. Since the state affine models used in this work are discrete and saturation is accounted for, a new set of stability conditions are developed and given in the following theorem .
(14)
To guarantee that all-possible values of the matrix A in (13) are accounted for, the system of LMI's is expanded to include two additional LMI's for each switching point. These two LMI ' s are calculated with the gain values from the two sides of the switching point. For example around the switching point defined by us, ' the two additional LMI's are :
Theorem 1:
Define
-I ~ Du ~ I and I~Di.k I~ ~max . where, M i.k =Di.hl -Di.k i =I,.... , n
(lSa)
For saturation :
A~c,PAKc, -P <0
A~2 PA Kc2 -P< 0
(15)
for
Di •k = I or -1,~Di.k = 0
and 0 ~ 'l'
~
I
(ISb)
Where e.g. A Kc , is the matrix A given by (9) using
The 'l' ,15' s and ~D' s evolve in a polytope whose
K c = Kc, .
vertices are in the set Q defined by the bounds given in equations (ISa-ISb) . Then, the system
The question on how to select the values ofN, Kc's
~k+1
and us's is still an open one because only stability is being tested and performance has not been yet
= [E(k)bk
where E(k)=Eo+EA.k+ .... +EnDn,k
54
(19)
8 s: 'i' where, E j = E j Uj,k + E j ' "
(19a)
from comparison of (9) and (19) and
OO,k
related to the convexity of the function f as gi ven by (22).
= I from
(3).
5. CASE STUDY: CSTR (CONTINUOUS STIRRED TANK REACTOR)
Is asymptotically stable iff: f(k)
=Vk+1 -
Vk
= E(k)T P(k+ I)E(k)-P(k)< 0
for all 0 i.k ,!lOj,le' 'I' E Q
The two methods presented above to reduce the conservatism of the stability analysis, are applied to a CSTR problem.
(20) The actual process is given by the following equations:
Where,
X2
P(k + I) = [P(k)+
j~ Pj!lOj,k ]
(21)
XI = - xI + Da (1- Xl
)e l+xdr
x,
And,
X2
2 I[(E;PjE j + E )PjE j + ETpjE j ~j,k j=fJ je",1
+ ET P j E j !lo j ,k ] ~ 0 for all i = 1,... , nand '1',0 j,k ,!lo j ,k
En (22)
Proof If a Lyapunov function Vk =1J..(k)T P(k}7J.(k)
is selected, then
f
= Vk+1 - V k < 0 with equations
(16)-( 19) lead to equation (20). Since equation (20) is computed only at the vertices of the polytope where OJ,k and !lOj,k are evolving, then to ensure
stability inside the polytope, the function f(k) has to be shown to be maximal at the vertices. This can be ensured by the following condition:
=-X 2
+BDa(I-xl )el+x2/r
-/3(x2 -xJ
(24)
Where XI and l2 are the reactor's non-dimensional concentration and temperature respectively . '" is the cooling temperature The purpose is to control J\ by manipulating", . The process has one stable steady state when the non-dimensional groups are Da=O.072, B=1.0, 13=0.3, and 'F20.0. The assumption in this work is that the model above is unknown a priori but an empirical state-affine model given by (1) can be identified from input (cooling temperature Xc ) and output (concentration Xi ) data. This data is generated using equation (24) responding to a multilevel PRBS input", signal in the range -10 ~ X c ~ 40 . The identified state-affine model is:
J
0 0.0217 0.2124 Fo = 0 - 0.4827 0.3177 [ 1 om 58 - 0.0235
FI
[-0.3111 3.1386 -0.2269
=
o o o
0.0919] 0.4964 0.0670
(23)
f
is
linear with respect to
1l0j,k'
then the
corresponding second derivative is zero. Since the Ej's in equation (19) are linear with respect to \jf (since OJ,k = I or -I ), and P>O, then
a2f T --=1J T LE 'i' PE'i'1J d'l' 2
-
'
,_
> O. E,'i''s are defined by
equation (19a) . The second derivative with respect to OJ,k leads to the additional condition given by equation (22). Since this equation is linear with respect to 0' sand !lo's it is sufficient to calculate it at the vertices of the polytope to guarantee it everywhere inside the polytope. In summary, the parameter-affine Lyapunov function allows for a larger flexibility in the optimisation of the weighting matrix P, but at the price of an additional restriction
Ho = [0.4722
0.0460
0.2564]
(25)
Using (25) and (9), the limit of stability for different combinations of the PI parameters, Kc and T / may be computed using equations (13). The resulting LMI ' s are solved using the Matlab function feasp. The dotted line in Figure I is the resulting limit of stability. For parameter values above the line the system is stable, below it is unstable . For comparison with the gain scheduling results, the best performing set of parameters along the dotted line in Figure I was selected. In the absence of a better performance test, the best performing set of parameters was chosen as the one that minimised the sum of squared errors for set point changes of Xl = ±O.2. From trial and error solutions, using different values along the solid line in Figure 1, the best set was found to be Kc =0.14 and T/ =1. For the application of the
gain scheduling controller, the number of switching ranges N was selected arbitrarily to be 3. The value of the reset time 'l" I was kept constant and equal to I . Then, from a trial and error solution of equation (16), the following gain-scheduled PI controller is obtained:
for
-l~
u <-0.7
in more aggressive control. In contrast, the use of the parameter-affine Lyapunov function leads to only a marginal reduction of conservatism of the stability test compared to the case where a constant weighting matrix P is used in the Lyapunov function .
...,
Kc = 0. 14
-0.7~u<-O.4
K c =0.17
-0.4~u~1
K c = 0.21
: J
:t
(26)
iI
11I
.... ....
I
E
..
It is clear from these results that the proportional gain can be significantly increased along significant regions of the operating window. To test the improvement in performance with the gain scheduled controller, set point changes simulations for XI = ±O.2 were conducted and the sums of squared
errors obtained with either the fixed (Kc
=0.14
= Po + PIDI,k '
Since
and
alln K.
Fig. I . Stability limit: Fixed P (dotted), Variable P (solid).
7. REFERENCES Becker, G. and A. Packard (1994). Robust Performance of Linear Parametrically Varying (LPV's) Systems Using Parametrically Sy stems and Dependent Linear Feedback. Control letters, 23, 205-215. Bequette, B. W. (1997). Gain-Scheduled Process Control : A Review NATO ASI Nonlinear Model Based Control Conference, Antalya Turkey, 1020 August. IEEE Budman H. and T. Knapp (1999). Mediterranea 99 Conference, June, Haifa, Israel. Doyle 111, F., A. Packard and M. Morari (1989). Robust Controller Design for a Nonlinear CSTR. Chem. Eng. Sci. , 44, 1929-1947. Gahinet P., P. Apkarian and M. Chilali (1994) . Affine-Parameter Dependent Lyapunov Functions for Real Parametric Uncertainty . Proceedings of 33rd CDC Lake Buena Vista, FL, December, 2026-2031 . Shamma J.S. and M. Athans (1992). Gain scheduling potential hazards and Possible Remedies. IEEE Control Systems magazine, pp. 101-107.
Then, the vertices
defining the set Q are as follows :
[1,2,1],[ -1,-2,1] }
__~__~__~__~
Prop;rtional
IDj,kI$1 , it is assumed in
[D,M, \fl] ={ [1,0,0], [1,-2,1], [-1,0,0], [-1,2,1]
I I
I
~L,____~====~==
= I) or the gain-scheduled PI controllers given by (26) were calculated. For a set point of 0.2, the sum of squared errors is 0.14 with the fixed PI versus 0.09 with the gain scheduled PI. For a set point of -0.2 the sum of errors is 0.144 for the fixed PI versus 0.1, obtained with the gain scheduled PI. Thus, as expected, the performance can be significantly improved using the gain scheduled PI controller. Finally the stability analysis using a parameter dependent Lyapunov function is conducted. From the model given by (25), n= 1 and then based on (16) : P(k)
I
a:.. *
'l"1
equation (17) that L\ max = 2 .
I
j.: • ~
(27)
Two vertices out of the possible eight can be ruled out because when the system is saturated ('¥ = 0 ), D = I or -1 and consequently, L\D =O. Equations (20) and (22) are solved at the vertices defined by equation (27) . The solid line in Figure I shows the reSUlting curve corresponding to the limit of stability, in terms of different PI tuning- parameters. It is clear from the figure that the improvement in terms of the increase in the proportional gain Kc is marginal as compared to the improvement achieved with the gain-scheduled PI controller.
6. CONCLUSIONS Two methods were proposed to reduce the conservatism of the stability analysis previously presented by Knapp and Budman (1999): I-gain scheduling and 2-parameter affine Lyapunov functions . The use of a gain-scheduled PI controller allows for a significant increase in the proportional gain compared to the fixed controller case, resulting
56