Ind. Eng. Chem. Res. 1996,34, 2418-2426
2418
pH Control Using an Identification Reactor Su Whan Sung and In-Beum Lee* Automation Research Center, Pohang University of Science and Technology, San 31 Hyoja Dong, Pohang, 790-784 Korea
Dae Ryook Yang Department of Chemical Engineering, Korea University, 1 Anam 5 ga, Seongbukku, Seoul, 136-701 Korea
pH control plays an important role in chemical processes. However, pH control has been recognized as a very difficult control problem because of its nonlinearities and time-varying characteristics. A new pH control strategy using an identification reactor is proposed to incorporate both the nonlinearities and time-varying characteristics of the pH process. In this study, a n equivalent titration curve between the pH value and the scaled total ion concentration of the titrating stream is obtained from the identification reactor, and the pH value is controlled in the main reactor using the obtained equivalent titration curve. A simple stability analysis is used to determine the tuning parameters of the PI controller. Simulation results show that the proposed control strategy can handle both the nonlinearities and time-varying characteristics.
Introduction The control of the pH neutralization process plays a very important role in chemical industries, such as wastewater treatments, polymerization reactions, fatty acid production, biochemical processes, and so on. The pH neutralization processes show the highly nonlinear behavior and time-varying nonlinear characteristics resulting from the variation of the feed components or total ion concentrations. These behaviors cause many difficulties in controlling product quality with conventional control techniques such as PID controllers. Thus, many researchers have exerted much of their effort in the modeling and control study of pH processes. McAvoy et al. (1972) modeled a pH process with the equations for material balance and equilibrium relation, and Gupta and Coughanowr (1978) successfully applied PID control with the controller gain updated on-line using an identification reactor. Gustafsson and Waller (1983) introduced the concept of reaction invariant t o incorporate the nonlinearity and designed an adaptive pH control system which has the total ion concentrations of weak acids as adjustable parameters. Parrish and Brosilow (1988) suggested a nonlinear inferential control methodology that used a parametric model based on an imaginary weak acid concentration and dissociation constant. Williams et al. (1990) developed a twoparameter model which consists of the total ion concentration and dissociation constant of a single fictitious acid to describe the mixtures of acids and bases and designed a controller to control the multicomponent pH system where they estimated two parameters and designed a nonlinear model based controller by injecting a strong base at two points along the in-line neutralization process. This technique works well near a nominal operating condition for a l-protic weak acid and strong base system. However, if the system is other than a weak acid and strong base system or deviates from the nominal operating condition, the performance of the controller can be degraded. Gustafsson and Waller (1992) discussed the relative merits of linear and nonlinear continuous control of pH processes via simulations and experiments and suggested a nonlinear adaptive controller using a parameter model. Mahuli
* To whom
correspondence should be addressed.
0888-5885/95/2634-2418$09.00/0
et al. (1993)used a statistical cumulative sum technique for continuous model adaptation. Lee et al. (1993) parametrized the pH processes with a three-parameter model which is composed of the total ion concentration and dissociation constant of a fictitious weak acid and the total ion concentration of a fictitious strong acid. They identified the three parameters with the relay feedback method. However, these types of models could not identify the process nonlinearities over the entire operating region. For example, if the titration curve of a pH process is different from that of a weak acid (1protic acid) and strong base system, the control performance of the controller based on the two-parameter model may not work well when the operating region is shifted due to the lack of degree of freedom t o fit the situation by the two-parameter model. Wright and Kravaris (1991) suggested a first-order state equation by reducing the reaction invariant pH process models. They proved that the state/output map is related to the titration curve of the feed stream if the initial state is a steady state and the feed composition does not change. They used a PI controller for which the controlled variable is the scaled total ion concentration of the component in the titrating stream (a state variable) instead of the measured pH value. Wright et al. (1991) also demonstrated the control performance and robustness of their control strategy with experimental study. However, this technique requires the laborious identification of titration curves and the repetition of this tedious procedure for the time-varying pH processes. Thus, it is necessary to find a method which can identify the time-varying process characteristics and fit for the wide range of operating conditions. In this study, we suggest a method that can be applied to a wide range of operating conditions and even to the timevarying process due to feed change. The proposed method uses an identification reactor to identify the process characteristic by modifying Gupta and Coughanowr’s (1978) identification tank, and the overall structure of the proposed strategy is similar to that of Williams et al. (1990). The pH process model and the control strategy from Wright and Kravaris (1991) are combined with the identification reactor to overcome the shortcomings of the Wright and Kravaris’s (1991)
0 1995 American Chemical Society
Ind. Eng. Chem. Res., Vol. 34,No. 7, 1995 2419 Strong buc
I
Acid i n f l w t
KAik,KBik= Kth dissociation constant of ith weak acid and base, respectively number of weak acid and base, respectively
mAi,ntBi= number of protic and hydroxyl groups of Main reactor
Figure 1. Scheme of the pH process for nonlinear pH control.
method. Furthermore, a simple stability analysis of the Wright and Kravaris's (1991)method is provided for the comprehension of the pH process and the determination of controller parameters.
ith weak acid and base, respectively Wright and Kravaris (1991) reduced these material balance equations to one state space equation by introducing a state variable x . x is identical for each ith species, and the state space equation is as follows.
(3)
Modeling the pH Process Consider a continuous stirred tank neutralization reactor system as in Figure 1. The system has a feed which is composed of N components (acid and base) and a titrating stream. For simplicity, perfect mixing is assumed and the level is maintained constant. As in MacAvoy et al. (19721, the material balance for each component can be obtained as follows. dCi dt where V denotes the volume of the tank and Ci, Cpi, and CTi denote the total ion concentration of the ith component in the effluent stream, influent stream, and titrating stream, respectively, and F and u represent the flow rates of the feed and the titrating stream, respectively. kssuming the neutralization reaction is very fast and streams are electronically neutral, equilibrium equations are as follows (Wright and Kravaris (1991)).
V -= FCpi + uCTi- (F + u)Ci for i = 1 - N (1)
x=
cpi- ci CP~ -G
i = l , 2 , 3 ,...,N
i
This model is accurate if the initial state is at steady state and, afterward, there are no species added or removed and there are no concentration changes in the feed components. This statement implies that there could be some error in the model if, for example, the feed composition is changed. However, when steady state is reached after some changes have been made, this model becomes accurate again and a slight change in the feed concentration usually does not result in a serious modeling error for the sake of control in the ideal case. Notice that pH is a function of total ion concentrations as in (2) and the total ion concentrations are functions of the state variable x as in (3). Therefore, according to Wright and Kravaris's (1991) model, the pH value and x have one-to-one correspondence and their output map (equilibrium equation) is an equivalent titration curve because x is equal to the scaled concentration of the strong base of the titrating stream as in (3).
Control Strategy If u , V, F , CPI, and C T are ~ constant then (3) can be solved analytically. U
+ c exp(- FT Stu )
x(t) = -
FSu
(4)
where C is an integral constant. If (3) is converted into a discrete time system with zero order hold, (3) can be expressed by the following recursive form.
where
[Hfl = hydrogen ion concentration Kw = dissociation constant of water
C,, CBi= total ion concentration of ith weak acid and base, respectively
C,, C ,
= total ion concentration of
strong acid and base, respectively
where T,denotes the sampling time in the identification operation. The pH control strategy suggested in this research is shown in Figure 2. F( ) is the titration curve obtained from the identification reactor using an interpolation method such as the cubic spline method. F( ) transforms the measured pH value to the state variable x , and then the nonlinear pH process can be expressed as a bilinear form as in (3) by this coordinate transformation. Since the bilinear form is simpler than the nonlinear form and almost linear in the set point region, x is preferable to be used as a controller variable by PI controller instead of the pH value as shown in Figure 2.
2420 Ind. Eng. Chem. Res., Vol. 34,No. 7,1995
-
1
0
I
I
I
I
1000
2000
3000
4000
Time(=)
(a)
o
- -
1000
0.0
Main
2000
Figure 2. Scheme of the suggested pH process structure for nonlinear pH control.
(bl
81 6
1
42-
0
I
2
4
6
1’2
lb
:1
L
i
I
1
I
2000
1000
0 I
4000
Time(-I
nacIOI
I
3000
3000
4000
TilMta)
16x\03
TirnC(‘S1
(C)
(8)
o ] 0.0
I
1
I
I
f
0.2
0.3
0.4
0.5
0.6
Figure 4. Dynamic behavior of the identification reactor (type 11). (a) Open-loop response, (b) corresponding x value, (c) corresponding titration stream flow rate, and (d) corresponding equivalent titration curve.
’“1 io
a
0
12
14
16x10’
Tim(ree) (Cl
. . . . . . , . . .. 0.0
I
0.1
0.1
0.2
0.3
* **.
0.4
0,s
0.6
I
Figure 3. Dynamic behavior of the identification reactor (type I). (a) Open-loop response, (b) corresponding x value, (c) corresponding titrating stream flow rate, and (d) corresponding equivalent titration curve.
For the identification of the titration curve, two types of operating procedures for the identification reactor, type I (Figure 3) and type I1 (Figure 4), are proposed. The type I procedure is as follows. The increasing step input is imposed for the duration time of dt which is long enough that the pH value of the identification reactor reaches the desired upper pH value. Then the decreasing step input is applied for a period of time until a steady state is obtained. The step size in each directions should be carefully determined so that the system response can cover the entire operating range of the pH value. Field operator’s experience is very important in the determination of the step size. Then the equivalent titration curve can be obtained from the measured pH values and the calculated x values using ( 6 ) and (7) in the ideal case. This procedure will be repeated to update the titration curve if needed. The
changes of the pH value are confined to the identification reactor so that the main reactor will be operated near the nominal operating condition. The dynamic response obtained from this procedure can be modeled using (4)as follows.
-) u, u, xu F + u , + (xu,, - F-) + u , x ’ - F +u1u , + (x10 + )
UU UU F+u, xlo - F uu + (xuo - F + u u expj- 7 cit)
+
=
--
u1
F+u,
exp( - ~
t (6)
exp(- ’+)t
(7)
where the subscript 0 denotes the initial state, the subscripts u and 1denote the increasing and decreasing step inputs, respectively, time t will reset to zero for each step change, and dt is the retention time of the increasing step input. Here, (5) instead of (6) and (7) can be used to obtain the x value with respect to time. The type I1 procedure is a periodic operation. The increasing and decreasing step inputs are repeatedly switched when the output of the identification reactor reaches the lower and upper pH values of the concerned operating condition. This procedure has a shorter cycle time for the identification than the type I procedure. The dynamic response of the identification reactor of this pattern can be obtained by applying (5) directly.
)
Ind. Eng. Chem. Res., Vol. 34,No. 7, 1995 2421 The dynamic behavior of the identification reactor is calculated using the identification procedures above, and the titration curve between the measured pH value and the state variable x can then be obtained using an interpolation method such as cubic spline. The estimated titration curves are shown in Figures 3 and 4 for the second pH process. To remove the effects of noise and guarantee the small number of data, x and pH data points should be accepted only when the difference between the present sampled data and the previous accepted pH value is greater than some value under the operation with a sampling time as small as possible. If there is a need to update the curve frequently, either both the time constant of the identification reactor (V/ F)and the sampling time or the range of the pH values to be concerned need to be smaller t o obtain both the fast response and enough accuracy. However, the determination of the time constant of the identification reactor should be based on the time constant of the pH sensor and the rate of the hydrolysis. Since the proposed strategy uses a separate identification reactor, the effluent of the identification reactor has to be disposed appropriately. If the flow rate of the identification reactor effluent is small compared with the feed flow rate, the effluent can be returned to the feed stream of the main reactor. Otherwise, the amount of the titrating stream entering into the identification reactor can be subtracted from that of the titrating stream of the main reactor and all the effluent can be returned to the main reactor. Here, the former with the small influent flow rate of the identification reactor is recommended for easy implementation. However, the latter would be superior to the former from the viewpoint of the control performance even though the system becomes more complicated.
Stability Analysis Stability analysis can be very helpful to design and tune the control system. The pH processes can be represented by a bilinear form such as (3). Assume that the variation of the state variable x is small in the neighborhood of the set point, then (1- x ) in (3) can be approximated as (1 - x,) and if we transform every variable to a deviation variable, the following expression is possible.
T P *dt+ y = K u where Tpand K are VmlFm and (1- xs)/Fm, respectively and y and u are as follows.
C
T I -
8
timion curve
.." 2
timrion C-
I
I
I
I
I
4
6
8
10
12
PH
Figure 5. Linearization of the modeling error for the first pH process. 2,
= (1
+ S)3c - Sx, + B
ym=(l+S)y u = Kc(l
+ SI(-y) + Kc(lTi+ S>&Y)
dt
Therefore, the bias term disappears so that the stability of the control system is not affected by the bias term and the only slope S will affect the stability in the neighborhood of the set point. The S value can be used as a measure of possible procesdmodel mismatch. (8)can be expressed as follows for the data-sampled system. Ykfl
=yka
+ KUk(1 - a>
a = exp( -
2)
(11)
where T,denotes the sampling time. If the integral part of the PI controller is calculated by the trapezoidal method, the controller output is expressed as the following data-sampled system.
uk = -K,(1 + S)yk-N -
KCTS
+ s) x
y=x-xs where N denotes the number of the sampling time corresponding to the measurement time delay and the z transform of u is as follows.
(9) where the subscripts m and s denote the model and the set point. We can approximate the procesdmodel mismatch a t the set point using a linear form such as that shown in Figure 5 . X,
- x = S(X - x,)
+B
(10)
where B = Xma - x,. Then the following expressions can be obtained.
K,T,Il + S ) f N - l(y(z) + z-ly(z>+ ...+2 Ti
i L
2422 Ind. Eng. Chem. Res., Vol. 34, No.7, 1995
where R(z)denotes the result by the initial value yo and the z transform of (11)is as follows.
5 1
unmbk lane
+ ay(z) + K(1 - a)u(z)
i 2.0
:/ITi
(13) and then the characteristic equation (14) can be obtained by (12) and (13). zy(z> = zy,
3.07
UNUblc m
0.5
0
Subk ZON
0.0
0
that is,
p+2 - (1+ a)?''
+ w N+ C,z - C, + C, = 0
20
10
2s
-I
l
I
30
40
11
16
0
50
2
4
6
8
1
0
(14) SfIbk z m e
+
( + 2j
C, =KK,(l - a)(l S) 1 -
If the roots of this characteristic equation exist inside unit circle centered at (0,01, the closed-loop system is asymtotically stable in the ideal case. When the measurement time delay is zero (i.e., N = 01,the resulting quadratic characteristic equation can be solved directly. When the measurement time delay exists, this characteristic equation can easily be solved by numerical techniques such as the Newton-Raphson method or the Muller method. Here, the results of imperfect mixing may be considered by the measurement time delay. Until now, there are three assumptions in the ideal case. The f i s t assumption is that (1- x ) can be approximated by (1- xs). The second assumption is that the process/ model mismatch can be approximated by a linear form. These two assumptions have accuracy in the neighborhood of the set point. If the pH process is similar to the two-parameter model, these assumptions are very accurate as in the case of Figure 5. The third assumption is that the trapezoidal method for the calculation of the integral term of the PI controller is used. However, we recognize that there are many nonideal factors such as imperfect mixing, the effects of baffles, slow hydrolysis, measurement noise, drift phenomenon, etc. Therefore, we want to say that this stability analysis shows promise as a guideline in the determination of initial controller parameters.
Simulation and Analysis The effects of the measurement time delay, sampling time, integral time, slope of the titration curve mismatch, and set point for the stability condition are shown in Figure 6. As the sampling time, measurement time delay, and slope increase, the unstable region expands. However, as the set point value (x,) increases, the stable region gets wider and the boundary of the stable region almost does not change when x s (the set point) is smaller than 0.5. Notice that the integral time above a specific value almost does not affect the stable region and the stable region expands if the slope is negative. To determine the initial controller parameters, first assume that the possible maximum slope S, minimum x s , and maximum measurement time delay N can occur in the given pH process. Second, increase the integral
/
- 0
6
1
s
0
10
20
15
I
l105 I Unrubk IW
Subk M
0.0
0.2
0.4
0.6
0.8
scc polnl
Figure 6. Results of the stability analysis for the first pH process.
l 2 1 10
h
Rcsponscs with k =2.3
5-
The time of the feed compositionchange
4-
1 31-,/ Q
2
z
1-
-.
J " I
0
I
I
I
I
I
1
500
1000
1500
2000
2500
3000
Time(scc)
Figure 7. Responses of the first pH process with respect to the stable gain and the unstable gain, where k , = 2.572 is the boundary value obtained by the stability analysis.
time constant until the proportional gain does not vary. Third, choose a smaller value than the minimum unstable proprotional gain and the integral time constant as the initial controller parameters under the maximum slope S, N , and minimum xs. Figure 7 shows the response of the first pH process that has an initial feed composition of 0.05 m o m HC1, CH3COOH and then a final feed composition of 0.01 mol& HC1, CH3COOH at 300 s. Here the titration
Ind. Eng. Chem. Res., Vol. 34,No. 7, 1995 2423 Table 1. Data for Simulations data for the simulation of Figure 7 (the first pH process) initial feed composition: 0.05 mol& HC1,0.05 mol& CH3COOH final feed composition: 0.01 m o m HC1,O.Ol mol& CH3COOH CH3COOH dissociation constant: 1.8 x data for the simulation of Figure 8 (the second pH process) initial feed composition; 0.025 mol& H3P04,0.005 m o m NaOH, 0.05 m o m CH3COOH final feed composition: 0.005 mol& HCl, 0.025 mol& H3P04 H3P04 first dissociation constant: 7.11 x second dissociation constant: 6.34x third dissociation constant: 4.2 x 10-13 data for the simulation of Figure 10 (the process of Figure 7) time of the model update: 500 s proportional gain: 1.5 integral gain: 20 data for the simulation of Figure 11(the process of Figure 8) time of the model update: 500 s proportional gain: 1.5 integral gain: 20 data for the simulation of Figure 12 (the second pH process) initial feed composition: 0.005 m o m HC1, 0.025 mol& final feed composition: 0.025 mol& &Pod, 0.005 m o m NaOH, 0.05 mol& CH3COOH proportional gain: 1.5 integral gain: 20
Responses with k, I0.08
'I 6
l 2 1 10
Actual limtion wwe
I
0
Modclcd tirmicn curve
0.2
4 0.0
2
"
c
!--4!cL
8
0.6
0.4
0.8
1 .o
I:or x.
I
I
500
1000
I
I
I
I
1500
2000
2500
3000
Time(=)
The time of thc f d compositionchange
/ 1
I
1
I
I
4
6
S
10
12
PH
Figure 9. Linearization of the modeling error for the second pH process. 0
500
1000
1500
2000
2500
3000
Time(=)
Figure 8. Responses of the second pH process with respect to the stable gain and the unstable gain, where k, = 0.0922 is the boundary value obtained by the stability analysis.
curve t o control the first pH process is based on the initial feed composition so that the modeling error occurs after 300 s. In this case, x s and Xms are 0.28515 and 0.66605,respectively, and the slope is 0.08802 at the set point pH 7 so that the modeling error is approximated by Xm - x = 0.08802 (x - 0.28515) 0.3809.We simulated the various K, values and realized that when the concentration change of the feed component results in a small modeling error in the slope as shown in Figure 5, the control action is almost not affected under moderate control (Kc = 1.5). However, tight control (K, = 2.7)may produce unstable responses. The stability analysis results show that if the proportional gain is above 2.57153then the process is unstable and vice versa. Here, we assumed that the pH measurements are corrupted with random noise of 3~0.1pH units. Figure 8 shows the responses of the second pH process which has an initial feed composition of 0.025 m o m Ha-
+
P04,0.005m o m NaOH, and 0.05 moVL CH3COOH and then a final feed composition of 0.005 m o m HC1 and 0.025 m o m a t 300 s, as shown in Table 1. Here the titration curve to control the second pH process is based on the initial feed composition so that the modeling error appears &r 300 s. In this case, the modeling error at the set point pH 5 is approximated by xm - x = 33.750h - 0.37583) 0.1351as shown in Figure 9.The stability results show that if the proportional gain is above 0.09221 then the process is unstable and vice versa. The pH measurements are corrupted with random noise of fO.l pH units. Here, because the modeling error S is large, the system can be destabilized even though the gain of the PI controller is very small. From the results of Figures 7 and 8 we can recognize that the suggested stability analysis can be used to determine the initial controller parameters and to analyze the robustness when x s and S are chosen accurately. Figure 10 shows that the responses of the first pH process with unstable gain (K, = 2.7)in Figure 7 can be stabilized by updating the model from the cubic spline model based on the initial feed composition t o the cubic spline model based on the final feed composition. Also, from Figure 11 we can induce that the responses of the
+
2424 Ind. Eng. Chem. Res., Vol. 34, No. 7,1995
"1
121
... ....
I-
6
I.
.I
Responses without lhc model updale Responses with the model updsre
41
2
0
1
I
I
I
I
1
I
ZOO
400
600
800
1000
1200
1400
1000
1200
1400
Timc(sec)
4-
'1
4
The time of thc feed compositionchange
1
3
2
P 2 1 0
0
200
400
600
800 Timeirec)
Figure 12. Responses of the second pH process in the opposite case of Figure 8. Table 2. Data for the Operation of the Main Reactor and Identification Reactor Data for the Operation of the Main Reactor NaOH concentration: 0.05 m o m sampling time: 5 s feed flow rate: 0.0188 Us main reactor volume: 5 L Data for the Operation of the Identification Reactor (Type I) sampling time: 0.1 s NaOH concentration: 0.05 m o m feed flow rate: 0.001 Lis identification reactor volume: 0.5 L increasing titrating stream decreasing titrating stream ( ~ 1 ) : 0.0003 U S (UJ: 0.003 Lis
6
" I
0
I
I
I
I
I
I
500
1000
1500
2000
2500
3000
2000
2500
3000
Timdsec)
The time of the feed composition change /
0
500
1000
1500 Time(%)
Figure 11. Responses of the second pH process in Figure 8 with respect to the unstable gain (It, = 1.5).
second pH process with unstable gain ( k , = 1.5) in Figure 8 can be stabilized by updating the cubic spline model. The data for the identification reactor operation are shown in Table 2, and we accept the data point (x, pH) when the difference between the present sampled pH value and the previous accepted data point is greater than 0.2 pH units in the operation of the identification reactor. Figure 12 shows the responses of the second pH process which has an initial feed composition of 0.005 m o m HCl and 0.025 mol& H3P04 and a final feed composition of 0.025 mol& H3P04,0.005 m o m NaOH, and 0.05 m o m CH3COOH at 300 s. In this case, two simulations are performed (that is, in simulation 1 the
initial model is based on the initial feed composition and it is updated to the final model based on the final feed composition a t 500 s. On the other hand, in simulation 2 the initial model is based on the initial feed composition and this model is not updated by the final model). This is the opposite case of Figure 8 from the viewpoint of feed composition changes so that the slope S is negative and even though the proportional gain is 1.5 this process is stable for both simulations 1 and 2. However, the responses of simulation 2 are more sluggish. Figure 13 shows the effects of modeling error in the identification reactor. Although the volume and influent flow rate of the identification reactor are 0.5 L and 0.001 Us,respectively, we assume that the volume and influent flow rate are 0.45 L and 0.0015 Us. We recognize that the small modeling error in the identification reactor cannot affect the control performance. As a result, if the slope S is positive, the gain should be smaller for the stability, and if the slope S is negative, the gain should be larger for a good control performance, but if the slope S is near zero, it is not necessary to update the model. The concentration change of the feed components under the same ratio in the total ion concentration of each feed component does not change the slope S. The small modeling error in the identification reactor cannot result in serious effects on the control performance.
Discussion In Figure 9, consider the slope of the titration curve at pH 5. The slope of pH value with respect to the
Ind. Eng. Chem. Res., Vol. 34,No. 7, 1995 2426 suggest about half of the time constant (that is, about 0.5 VJFm) be used as the time of the model update. The smaller the modeling error is, the longer the time is after which the process becomes unstable and the smaller the effects of the model update time are. In practice, if the pH system is operated under moderate control and the drastic variation of the slope S as in Figure 8 does not occur, then it is a trivial problem. 0
I
I
I
I
I
I
I
200
400
600
800
1000
1200
1400
Time(wc)
'1
.f
4
$
2
a
3
1
0 0
200
400
600
800
1000
1200
1400
Timc(scc)
Figure 13. Responses of the second pH process of Figure 12 with the modeling error.
scaled concentration ( x ) of the model is much smaller than that of the real process so that the error term of the scaled concentration is larger than the real process with respect to the same pH error term. Therefore, the modeling error plays a role in increasing the proportional gain of the PI controller. Therefore, if the slope S of xm - x at the set point is positive (that is, the pH slope of the model is smaller than that of the real process) the controller gain should be smaller. On the other hand, if the pH slope of the model is larger than that of the real process, the modeling error plays a role in decreasing the proportional gain of the PI controller so that if the slope S of x m - x is negative, the controller gain should be larger for the aggressive control action. Furthermore, if the pH slope of the model is the same as that of the real process then the error term of the model is the same as that of the real process so that two responses are similar at the set point. These results are the same as those of the stability analysis. As a result, we can confirm the reliance of the stability analysis. When some disturbances such as in the case of Figures 7 and 8 enter under tight control, the time of the model update is important. When new components enter, the x values of these components change from 1 t o the new steady state values slowly, and when the concentrations of some components change drastically, the x values of these components change from the initial values t o the new steady state value slowly. Therefore, the average nonlinear property of the process changes from the initial state to the new steady state slowly. Until the new steady state is obtained, we cannot say that the new steady state model is appropriate for this transient state. In the case of Figure 12, if the model is updated as soon as the drastic disturbance enters, there is a possibility to destabilize the process because the old model is predominant for the time being. Of course, after about a quarter of the time constant of the process (that is, Vm/Fm), the process is again stabilized because the new state becomes predominant. In the case of Figure 8, the fast model update results in the sluggish response for the time being. Therefore, we
Conclusions
A pH control strategy using an identification reactor is proposed to incorporate the nonlinearities and timevarying characteristics of the pH process. Two types of procedures t o operate the identification reactor are suggested. Their dynamic responses can be characterized, and the titration curve can be obtained by matching the estimated x values with the measured pH values using an interpolation method such as the cubic spline method. Then, it is possible to transform the measured pH value to the state variable x which is the controlled variable of the PI controller. Therefore, the proposed control strategy incorporates the nonlinearities of the pH processes using Wright and Kravaris's (1991)control strategy and a t the same time adapts the time-varying characteristics which can arise from changes in the feed components or composition. The stability analysis with Wright and Kravaris's (1991) model is also performed to enhance the understanding of the closed-loop system behavior and tuning of PI controller. Nomenclature C h , C B= ~ total ion concentration of ith weak acid and base, respectively, mom CA,CB = total ion concentration of strong acid and base, respectively, mom F = flow rate of the process stream flowing into the identification reactor, Us Fm= flow rate of the process stream flowing into the main reactor, Us [H+l = hydrogen ion concentration, 10(-pH),m o m Khk, K B , k = kth dissociation constant of ith weak acid and base, respectively K, = proportional gain of the PI controller K, = dissociation constant of water mh,mB1 = number of protic and hydroxyl groups of ith weak acid and base, respectively NA,NB = number of weak acid and base, respectively S = slope of xm - x at the set point t = time, s TI= integral time of the PI controller, s T,= sampling time, s u = control variable, Umin V = volume of the identification reactor, L V, = volume of the main reactor, L x = state variable xm = model value of state variable x y = deviation variable of x ym = deviation variable of xm Subscripts 1 = lower step input 10 = initial value when the upper step input is entered
m = model P = process s = set point T = titrating stream
2426 Ind. Eng. Chem. Res., Vol. 34, No. 7,1995
u = upper s t e p i n p u t u0 = initial value w h e n the lower s t e p i n p u t is entered
Literature Cited Gupta, S. R.; Coughanowr, D. R. On-Line Gain Identification of Flow Processes with Application to Adaptive pH Control. AZChE J . 1978,24,654-664. Gustafsson, T. K.; Waller, K. V. Dynamic Modeling and Reaction Invariant Control of pH. Chem. Eng. Sci. 1983,38,389-398. Gustafsson, T. K.; Waller, K. V. Nonlinear and Adaptive Control of pH. Znd. Eng. Chem. Res. 1992,31,2681-2693. Lee, J.; Lee, S. D.; Kwon, Y. S.; Park, S. Relay Feedback Method for Tuning of Nonlinear pH Control Systems. AZChE J . 1993, 39,1093-1096. Mahuli, S. K.; Rhinehart, R. R.; Riggs, J. B. pH Control Using a Statistical Technique for Continuous On-Line Model Adaptation. Comput. Chem. Eng. 1993,17, 309-317. McAvoy, T. J.; Hsu, E.; Lowenthal, S. Dynamic of pH in Control Stirred Tank Reactor. Znd. Eng. Chem. Process Des. Dev. 1972, 11,6a-70.
Parrish, J. R.; Brosilow, C. Nonlinear Inferential Control. AlChE J . 1988,34,633-644. Williams, G. L.; Rhinehart, R. R.; Riggs, J. B. In-Line Process Model Based Control of Wastewater pH Using Dual Base Injection. Znd. Eng. Chem. Res. 1990,29,1254-1259. Wright, R. A.; Kravaris, C. Nonlinear Control of pH Process Using the Strong Acid Equivalent. Znd. Eng. Chem. Res. 1991,30, 1561-1572. Wright, R. A.; Soroush, M.; Kravaris, C. Strong Acid Equivalent Control of pH Processes: An Experimental Study. Znd. Eng. Chem. Res. 1991,30,2437-2444.
Received for review March 21, 1994 Revised manuscript received April 27, 1995 Accepted May 10, 1995@ IE940179K
@Abstractpublished in Advance A C S Abstracts, J u n e 15, 1995.