Digital Control of a Continuous Stirred Tank Reactor

We project a novel digital control law for continuous stirred tank reactors, based on sampled measures of temperatures and reactant concentration, as it happens in practice. The methodology of relative degree preservation under sampling is used. It is proved that a suitably approximated sampled system, obtained by Taylor series expansion and truncation, in closed loop with the projected control law, is asymptotically stable, provided that a condition on the sampling period is verified. Such condition allows for values of the sampling period larger than necessary in practical implementation with usual technology. Many simulations show the high performance of the proposed digital control law.


Introduction
The control of the operation of chemical reactors has attracted the attention of researchers for a long time.The underlying motivation relies on the fact that industrial chemical reactors are frequently operated at unstable operating conditions, which often corresponds to optimal process performance 1-19 .Polymerization processes 5 and bioreactors fermentors 18 are important examples of large-scale chemical reactors operated at unstable conditions.As well known, the measures of the reactant concentration cannot be achieved on continuous time.In practice, these measures are available at certain time intervals.It is therefore very important to project control laws which are piecewise constant and are updated at each measures update.That is, for practical use, a digital control law has to be projected.Applications of nonlinear digital control theory to some chemical reactors can be found in 20, 21 .In 11 a discretetime controller is obtained by linear approximations successively executed at each sampling time, and an application to a continuous stirred tank reactor is shown.

Mathematical Problems in Engineering
In this paper we deal with a novel digital controller design for a continuous stirred tank reactor, where an irreversible, exothermic, liquid-phase reaction A → B evolves.The controlled output is the reactor temperature.The jacket temperature dynamics is considered.The control law is actuated by means of a pneumatic valve which regulates the cooling water flow rate.This actuation process is easier to implement than the ones based on the use of the inlet reactor concentration or of the jacket temperature as manipulated inputs.The model consists of three nonlinear ordinary differential equations.We develop a digital control law by means of a suitably approximated sampled model, obtained by Taylor series expansions see 21,22 .The preservation of relative degree methodology shown in 22 is here used.For the underlying continuous time model, the relative degree is not full.The relative degree is preserved for the approximated sampled model by introducing a dummy output.Then a feedback control law is projected, by which the approximated sampled system becomes asymptotically stable.Many performed computer simulations show the high performance of the proposed digital controller.Saturation effects have been taken into account in simulations.The convergence of the state variables to the arbitrarily chosen operating point is always obtained with the many considered system initial conditions even start-up initial conditions .

The Model of the CSTR
Here we study a CSTR with jacket cooling in which a first-order irreversible exothermic reaction takes place 23 : The liquids in the reactor and in the jacket are assumed perfectly mixed, that is, with no radial, axial, or angular gradients in properties temperature, concentrations .This allows to consider reactor and jacket temperatures and reactant concentrations as space invariant variables.If physical properties are assumed constant densities and heat capacities , the reactor volume is constant and the jacket volume is constant, the mathematical model of the CSTR is given by the following set of nonlinear functional differential equations: where T J jacket temperature K , u flow rate of coolant control input m 3 /s , K 0 pre-exponential factor s −1 , E activation energy J/kmol , R universal gas constant, 8314 Jkmol −1 K −1 , F flow rate of feed and product m 3 /s , ρ density of product stream kg/m 3 , Ca 0 concentration of reactant A in feed kmol/m 3 , V R volumetric holdup of liquid in reactor m 3 , T 0 temperature of feed K , C p heat capacity of product Jkg −1 K −1 , λ heat of reaction J/kmol , U overall heat transfer coefficient WK −1 m −2 , A j jacket heat transfer area m 2 , ρ j density of coolant kg/m 3 , C j heat capacity of coolant Jkg −1 K −1 , and T cin supply temperature of cooling medium K .
Fresh feed Let ß ∈ 0, 1 be the reaction conversion Let ß eq be the chosen operating point reaction conversion.By 2.2 it follows that the operating point concentration of reactant in the reactor Ca eq is given by Ca eq Ca 0 1 − ß eq .

2.3
From equations in 2.1 , setting zero the left-hand side, it follows that the operating point reactor temperature T R eq , the operating point jacket temperature T j eq , the necessary coolant water flow rate u eq for the chosen operating point are given by 2.4

Sampled System and Digital Control Law
The system 2.1 is in the form where the functions f, g can be easily defined by 2.1 as In order to rewrite 3.1 in normal form, as required in 22 , let us now consider the following variables: from which the easy inverse relation holds Let the control input be equal to u t u eq v t .

3.5
Let the controlled output be y t h ξ t ξ 1 t .

3.6
We want to control to zero this output, which corresponds to drive the reactor temperature to the reactor temperature operating point T R eq .We can write the system equations by using the new variables ξ t as follows: where p 1 , p 2 are given by , p 32 ξ t 0.

3.8
Since ξ 0 corresponds to x Ca eq T Req T Jeq , it follows that p 1 0 0. The introduction of the new variables allows to obtain the CSTR equations in normal form 22 , and the origin is an equilibrium point.Therefore, the stability of the origin for the system described by 3.7 is equivalent to the stability of the chosen operating point for the system described by 2.1 .Let us now sample and approximate, by Taylor series expansion and truncation, the system 3.7 as follows: where ξ kδ is the approximation of ξ kδ ; R 0 is given by Lie derivatives are used , q ξ kδ is given by

3.11
The approximated sampled system 3.9 is obtained by exploiting the normal form of 3.7 see 22 and by neglecting, in the Taylor series expansion, the terms which are 0 δ 3 in the expression of ξ 1 k 1 δ and in the expression of ξ 3 k 1 δ , and the terms which are 0 δ 2 in the expression of ξ 2 k 1 δ see terms N 2 r,δ in 22, Proposition 3.2 .Notice that, since ∂p 31 ξ kδ /∂ ξ kδ p 2 ξ kδ 0, the inclusion of a term which is 0 δ 2 in the approximation of ξ 3 k 1 δ does not cause a new presence besides the one in R 0 of the control input v k .As well, neglecting terms which are 0 δ 2 in the expression of ξ 2 k 1 δ avoids to have further terms besides R 0 which involve the control input.This fact is instrumental for building the digital control law here proposed, as will be shown below.
The approximated sampled system 3.9 admits relative degree equal to 1, thus not preserving the relative degree equal to 2 of the original continuous time system 2.1 with respect to the output x 2 t reactor temperature .Thus, a digital input/output linearizing feedback control law built up on the basis of the given output 3.6 yields a further internal dynamics.In order to preserve the relative degree, let us introduce the dummy output as proposed in 22 , 12 and let us define the variables where the nonsingular matrix M is given by We obtain, from 3.9 , where R 0 , rewritten with the variables χ, becomes be chosen such that the matrix 0 1 Γ 1 Γ 2 has eigenvalues inside the open complex unitary circle.Let the sampling period δ > 0 satisfy the following inequality: Then, the following discrete time feedback control law is such that the trivial solution of the closed-loop system 3.16 -3.20 is asymptotically stable.Moreover, the eigenvalues of the Jacobian (evaluated at 0) of the right-hand function describing the closed-loop system 3.16 -3.20 are given by the eigenvalues of the matrix 0 1 Γ 1 Γ 2 and by the eigenvalue
Proof.By the form of the matrix M 1 , the following equation holds for χ 1 and for χ 2 , in 3.16 Notice that, by construction, such subsystem and thus the overall system 3.16 admits relative degree equal to 2, in a neighborhood of the origin, with respect to the dummy output χ 1 k .Indeed, taking into account of the form of R 0 kδ , we have

3.23
and the term multiplying v kδ is nonzero in a neighborhood of the origin, since l p 2 l p 1 h M −1 χ k is smooth in a neighborhood of the origin and l p 2 l p 1 h 0 / 0. Therefore, taking again into account the form of R 0 , the proposed discrete-time feedback control law yields the following equations for the closed-loop-system 3.16 , 3.20

3.24
In order to show the asymptotic stability of the nonlinear system 3.24 , it is sufficient to show that the linear system obtained by linearizing 3.24 is asymptotically stable.The Jacobian, at zero, of the function in the right-hand side of 3.24 is given, taking into account of p 31 and of q, by where and α, β are suitable reals.Given the triangular structure of the Jacobian J, the eigenvalues are given by the eigenvalues of the matrix 0 1 Γ 1 Γ 2 and by γ .The eigenvalues of the matrix 0 1 are inside the open unitary circle.The eigenvalue γ is always positive for positive sampling period , and is inside the open unitary circle if the inequality 3.19 is satisfied.Moreover, by using the derivative of γ with respect to δ, we obtain that γ takes the minimum value, 0.5, at δ 1/2 .

Now, going back to initial variables x, by means of the approximated relation χ k Ù
Mφ −1 x kδ , the digital feedback control law here proposed is given, for kδ ≤ t < k 1 δ, k 0, 1, 2, . .., by

3.27
The digital control law 3.27 is applied to the CSTR system, described by the differential equations 2.1 , by means of a zero-order hold device.Such control law can be easily implemented on a microprocessor.It is a static feedback control law, that is, no dynamics are involved.The control law has to be computed at every sampling period which is very much larger than the computation time many minutes versus some seconds at maximum .The great advantage of this digital control law is also given by the fact that only sampled-data measures, provided by a suitable device, are necessary.Take into account that, in practice, continuous time measures are difficult to obtain, or even impossible.The feedback control law here presented is therefore easily realizable.The closed-loop system 2.1 , 3.27 with the zero-order hold is simulated in the following section.

Simulation Results
Simulations, using MatLab The MathWorks, Inc. Software Package, have been carried out to verify the effectiveness of the proposed method.The values of the model parameters used in simulation are given in Table 1 taken from 23 .In all the carried out simulations, a minimum and a maximum value for the input u, specifically the volumetric flow rate of the refrigerant, is imposed, to take into account of the actuator saturation.It is considered: with the following acceptable physical values for a control valve F J min 0.002 m 3 /s 7.2 m 3 /h, F J max 0.08 m 3 /s 288 m 3 /h.

4.2
With these parameters, δ max in condition 3.19 is equal to 0.57 h, which corresponds to about 34 min.The value of δ 1/2 is equal to about 0.28 h which corresponds to about 16 min.
We performed several sets of simulation runs and all showed the high performance of the digital control law here proposed.We choose the reactor conversion ß eq 0.85, to which the following unstable operating point corresponds: Ca eq 1.2015 kmol/m 3 , T R eq 350 K, T J eq 312 K, u eq 69.86 m 3 /h.In the simulations here presented, the process is initially assumed to be at the start up, that is x 1 0 Ca 0 concentration of reactant in feed 8.01 kmol/m 3 , x 2 0 T 0 temperature of feed 294 K, x 3 0 T cin supply temperature of cooling medium 294 K.This means that the reactor is very far from the operating point.
In Simulation 1 see Table 2, Figure 2 we consider the reactor at nominal parameters values see Table 1 , without any uncertainty.Figure 2 shows the evolution of the reactant concentration, of the reactor temperature, of the jacket temperature, and of the piecewise constant control signal, respectively, with sampling period equal to 10 −1 h 6 min .
As can be seen, all the state variables converge to the operating point ones in a very good fashion, without dangerous oscillations.The reactor temperature settling time is estimated from plots to be about 6 h, the steady-state error is equal to 0.
In Simulation 2 see Table 3, Figure 3 we consider again the reactor at nominal parameters values see Table 1 , without any parameters mismatch, and a sampling period equal to 0.25 h 15 min is considered.The same desirable convergence to the operating point is achieved, with a reactor temperature settling time of about 8 h.Again no dangerous oscillations appear and the reactor temperature is driven in a very good fashion to the operating point, with steady-state error equal to 0.
In Simulations 3, 4 see Table 4, Figure 4, and Table 5, Figure 5, resp.we consider the reactor whose parameters are uncertain, with sampling time again equal to 0.1 h and 0.25 h, Mathematical Problems in Engineering  respectively.We apply the controller obtained using the nominal values of the parameters see Table 1 , to a reactor whose parameter values are different with respect to the nominal ones as reported in Table 5.In this case we observe a reactor temperature steady-state error of about 5 K. Take into account that the parameters mismatch has been deliberately chosen very critical, in order to show the robustness of the proposed controller.The performed simulations show the high performance of the proposed controller, as evidenced, in the case the reactor parameters are exactly known, by zero steady state error, no dangerous oscillations, good settling time.When parameters mismatch occurs, the proposed controller yields a very good behavior for the reactor, evidenced by small steadystate errors, no dangerous oscillations, and good settling time.We stress the fact that the 14 Mathematical Problems in Engineering Parameters mismatch: proposed controller allows for sampled-data measures of the state variables, which is very useful in practical applications.

Conclusion
In this paper we have presented a digital control law for a continuous stirred tank reactor, constructed on the basis of an approximated sampled model and of the preservation of the  relative degree methodology.The proposed feedback control law is easy to implement and simulations show high performance.A condition on the sampling period is found, by which the asymptotic stability of the closed-loop approximated sampled system is proved.Such condition is verified by sampling periods belonging to feasible sets, allowing for values larger than necessary in practical implementation.Future work will concern the construction of a discrete-time observer, in order to avoid reactant concentration measures, which are difficult Mathematical Problems in Engineering to do and expensive see 24-27 .Another topic which will be investigated is the problem arised by the recycle time-delay see 21, 28-31 , on the basis of the results in 32 .

Table 2 :
Process parameters of Simulation 1.

Table 3 :
Process parameters of Simulation 2.

Table 4 :
Process parameters of Simulation 3.