Copyright @ IF AC Advanced Control of Chemical Processes, Pisa, Italy, 2000
NITRATE CONCENTRATION-BASED CONTROL OF A PRE-DENITRIFYING ACTIVATED SLUDGE SYSTEM Oscar A. Zanabria Sotomayor* ,l Song W. Park * Claudio Garcia **
* LSCP - Department of Chemical Engineering ** LAC - Department of Electronic Engineering Polytechnic School of the University of Sao Paulo, Brazil E-mail:
[email protected]; Fax: +55-11-813.2380
Abstract: The strong variation in the flow and composition of the incoming wastewater generates a demand for on line control of the denitrification process in order to improve nitrogen removal. In this paper the nitrate concentration is controlled by manipulation of the nitrate recycle flow rate in an activated sludge process. The control strategy is based on the Reference System Synthesis/Generic Model Control (RSS/GMC) technique, using a reduced order model whose parameters were updated through an extended Kalman filter. Results are evaluated in simulations, demonstrating the robustness of the algorithm to variations in the influent flow and concentration, and dynamics not considered in the reduced order model. Copyright © 2000 [FAC Keywords : Waste treatment, Water pollution, Nonlinear control, Model based-control, Extended Kalman filter, Environmental engineering
1. INTRODUCTION
bodies can cause a severe lack of dissolved oxygen concentration (DOC) ; • The presence of ammonium in wastewater increases the consume of chlorine during the process of disinfection by the formation of chloramines and trichloride of nitrogen , with less disinfectant power than the one of chlorine. Besides, these are cancerigenic substances and they are responsible for bad smell and bad taste of water; • The consumption of vegetables , fish or water contamined with nitrate can lead , mainly in children under six years, to a disease called metahemoglobinemia. This disease is a product of transformation of hemoglobin when its ion Fe2+, present in its molecule, is oxidized to Fe3+ decreasing the amount of oxygen transported by blood and producing serious problems for human health;
In the past , the treatment of domestic and industrial waste just aimed the removal of organic loads. Nowadays, great stress has also been given for the removal of macro-nutrients such as nitrogen, due to the problems they cause as it is already known. Among these, we can highlight (Boaventura, 1997): • The nitrogen is present in several kinds of wastewater, e.g. ammonium (N Ht) , nitrate (NO;), nitrite (N0 2 ) and as organic compounds. The Ammonia (N H 3 ) is toxic for aquatic organisms, specially for big forms of life such as fish ; • When ammonium is oxidized to nitrate, a significant demand of oxygen in the receptor
1
Financial support of FAPESP (98/12375-7)
213
• The nitrate and the nitrite can become cancerigenic products. Nitrate, for example, reacts endogenously to secondary amines , amides and carbamates, forming N-nitrous composts, being some of them cancerigenic for the human being; and • The nitrogen and the phosphorus accelerate the process of eutrophication (aging) of receiving bodies. As mentioned before, the removal of nitrogen of wastewater has been receiving much attention , mainly through biological methods , as the activated sludge process, for presenting economical and operational advantages. The biological removal of nitrogen occurs in two stages: nitrification, where the ammonium is converted into nitrite and soon afterwards in nitrate by autotrophic bacteria under aerobic conditions; and denitrification where the nitrate is converted into nitrogen gas by heterotrophic bacteria under anoxic conditions. The strong variation in influent flow and composition, which if typical for wastewater treatment plants (WWTPs), generates a demand for on-line control of the denitrification process in order to guarantee a sufficiently low effluent nitrate concentration. Two variables can be manipulated to achieve this objective: the external carbon source dosage ( Isaacs et al. , 1993; HaBin et al., 1996; Yuan et al. , 1997; Lindberg, 1997; Barros and Carlsson, 1998), to guarantee that (almost) all the recirculated nitrate is removed in the anoxic zone. This strategy can increase denitrification rates and compensate for deficiencies in the influent C/N ratio, but can increase the cost considerably to a higher carbon requirement , a higher sludge production, affecting the nitrification process, and an increased oxygen demand. Another strategy is the manipulation of the nitrate recirculation flow rate ( Londong, 1992; Andersson et al., 1995) from aerobic zone to anoxic zone.
demonstrating the robustness of the algorithm to variations in the influent flow and concentration and dynamics not considered in the reduced order model.
2. PROCESS CONFIGURATION The activated sludge process (ASP) is shown in figure (I) . The configuration is formed by a bioreactor composed of an anoxic zone, two aerobic zones and a secondary settler. The compartments of the bioreactor are considered to have constant volume (15 m 3 each) and to be ideally mixed whereas the secondary settler (20 m 3 ) is modeled with a series of 10 layers (one-dimensional model) . The dissolved oxygen concentration is controlled in the second aerobic zone in 2.0 mg02/l , by a PI controller (not shown in the figure) . In the first aerobic zone, a constant air flow is considered. The influent flow Qin is 4.17 m 3 / h , with a proportion of biodegradable COD of 224 mg/l and a hydraulic retention time of 15.6 h.
Fig. 1. ASP configuration The model for each bioreactor zone is based on the IAWQ model No. 1 (Henze et al., 1987) and for the settler on the double exponential settling velocity model (Takacs et al., 1991) . The values of the process parameters are here omitted but can be found on Zanabria et al. (1999a) and Zanabria et al. (1999b).
In this work the level of nitrate concentration in the anoxic zone is controlled in a specific set point (1.0 mgN/ l) by manipulation of flow rate of nitrate recirculation in an activated sludge process with pre-denitrification which includes the removal process of organic matter, nitrification and denitrification of domestic effluents. the objective of this work is according with the European Program COST Action (Cost-624, 1998) .
3. ON-LINE IDENTIFICATION OF THE NITRATE DYNAMICS The IAWQ model No. 1 is very complex, containing 13 nonlinear coupled differential equations and 19 parameters to be used in on-line control and identification. Jeppsson (1996) proposed a reduced order model of the IAWQ model, with 5 state variables and 6 parameters that have to be estimated.
The proposed controller is based on RSS/GMC technique (Lee and Sullivan , 1988), using a reduced order model of the nitrate concentration dynamics in the anoxic zone, whose parameters have been previosly adjusted in an experiment of estimation using an Extended Kalman Filter (EKF). Results are evaluated in simulation,
The reduced order model equation that describes the nitrate concentration dynamics in anoxic conditions is given by the following expression:
214
~n (SNO in
- SNO)
Qint (S V NOin'
-
S) NO
C;;l (SNO.1 - SNO)
!:1t = 3.12 min., that is approximately 1/10 of the open loop response time constant to a 50% step variation in the internal recycle flow, in nominal operational conditions. The concentrations of the influent and the flows Qin and Qsl(= 0.8Qin) are kept constant.
+ + (1)
The disturbing flow used in the identification, the output (continuous line) , the identified output (dotted line) and the estimated parameters are shown in figure (2) .
where: YH is the yield factor for heterotrophs, rH is the reaction rate factor for heterotrophs (l/mg.h), XCOD is the biodegradable organic matter (mg/l) , X BH is the heterotrophic biomass concentration (mg/l), Q is the flow rate (m 3 /h) , V is the volume of the anoxic zone (m 3) and SNO is the soluble nitrate concentration (mg/l) . The subscript in, in! and ,I represents wastewater inflow , internal recycle and sludge recycle respectively.
~
0
The equation (1) is used considering the following assumptions:
0
• The XCOD variable is measurable and equal to Ss variable. In practice COD measurements are often considered to be equal to the amount of Ss ; • The X BH variable is considered constant and equal to their respective mean value. This is assumed because of the non-existence of heterotrophic biomass sensors. Besides, the relative variation of this variable is minimum (with exception of a strong change in the concentration of Ss, pH or toxic elements in the influent, in which case X BH considerably varies) ; • The flows and the nitrate concentration measurements in Qin, Qint and Qsl are available. The parameters YH and rH need are estimated. All sensor dynamics are neglected.
0
20
'5
'0 Lime (h)
15
20
15
20
'0 lime (h)
0.997 0."
0.9965
2'0.8
0.996
~
~O.7
~ 0.9955
t 0.6 0.5
0.9945
0
'0 Lime (h)
15
0.'
20
V-
10
0
-(h)
Fig. 2. Identification of the reduced order model for nitrate concentration Aiming to compare the obtained model with the process, in order to be used in control, the process and the model were submitted to a disturbing sequence in Qintt considering Y H = 0.995 and rH = 0.61/(mg.h) . The reduced order model (dotted line) adequately adjusts itself to the process response (continuous line) as shown in figure (3) .
The identification process is made on-line, in open loop, using a continuous-discrete EKF (Ljung, 1979) with a variable forgetting factor (Fortescue et al., 1981). The parameter vector gradient of the prediction error are determined by:
l:rL~:~ 10
12
,.
16
I,
20
m. (h)
102l2J
and
o
2
..
6
•
10
12
,.
16
la
~
m. (tI)
Fig. 3. Reduced order model comparison respectively, and the input signal corresponds to random variations in the internal recycle flow (rich in nitrate) , having as minimum and maximum values 0.1 and 1.9 times the nominal value of Qint(= 2Qin)' The initial parameter vector is 8(0) = [I , ljT and the initial covariance matrix is P(O) = diag(10 6 , 106 ). The observed noise covariance matrix is RI = 0 and the minimal forgetting factor is 0.95. The selected sampling time is
4. RSS/GMC CONTROL OF THE NITRATE CONCENTRATION The Reference System Synthesis/Generic Model Control (RSS/GMC) is a process control strategy developed to solve non-linear control problems with relative degree r = 1. 215
algorithm , a better result can be obtained. The parameter value ~ = 1.0 was chosen based on the fact that an overshoot is acceptable in the process (Lee, 1993). To ease the computational implementation, a discretized version of the resulting control law is used , applying a semi-implicit Euler scheme (Franklin and Powell, 1980):
Consider a process model described by the following equation: :i;
= f(x ,
'U c ,
d, t)
(2)
(3)
Y =g(x)
where, x is a state vector of dimension n , 'U c is the manipulaed variable vector of dimension rn , d is the disturbance variable vector of dimension q and y is the output vector of dimension p . In general, f and 9 are non-linear functions.
a(k)'Uc(k)
= a(k -
1)'U c(k - 1) +
Kdy(k - 1) - y(k)]
+
At · K 2 [ysp - y(k)] -
If the closed loop system satisfies the property:
{3(k)
+ {3(k -
1)
(8)
(4)
i/=v
where: where, v is an external reference input (called new input) , it implies that the map between v and the output y is linear for all state values x(t) in the neighborhood of analysis point Xo . The new input of the reference system can be chosen as follows ( Lee and Sullivan, 1988; Lee, 1993) :
a(k)
{3(k)
t
V
= Kl (Yap -
y)
+ Kz
J
(Yap - y)dt
l-YH
+
QsJk) (SNO., (k) - y(k»
where, Yap is the desired output and Kl and Kz are the controller tuning parameters. A reasonable choice for Kl and Kz is given by (Lee, 1993) :
= 2~
The sampling time used was At = 1.58min., that was calculated considering the sampling effect on the control performance, see (Marlin, 1995). The dynamics of the sensors and the control final element were neglected.
(6)
T
The controlled system was submitted to several disturbances in the influent concentrations and flow. The considered disturbances and the system response are shown below. The values of the disturbances were normalized to simplify its presentation. The set-point was 1.0mgNI l.
(7)
where, ~ is selected to provide a desired shape of response of the reference system and T is selected to provide an appropriate timing of response in relation to known or estimated plant speed of response.
Figure 4 shows the process response to measurable disturbances in the inflow nitrate concentration (nominal value=1.0mgNIl) and in the wastewater inflow (nominal value=4.17m3 I h) . Those disturbances were very well compensated by the controll er, specially for great increases in the influent flow.
The RSS/GMC algorithms is applied to control of the nitrate concentration in the anoxic zone using the reduced order model , previously identified. From equations 1, 2 and 3, if:
x == SNO(t) ,'Uc == Qint(t) , y ==
y(k»
= - 2.86YH THXBHXCOD(k) + d1(k) (dz(k) - y(k» V
(5)
o
Kl
= V1 (SNOin. (k) -
X
In figure 5 it is presented the process response to non-measurable disturbances in the inflow slowly biodegradable substrate (nominal value=160mgll) and inflow readily biodegradable substrate (nominal value=64mgI l) . Although not having the feedforward feature against these disturbances, the controller performance was very good, specially in the increase of SSin showing the algorithm good robustness against modeling errors and nonmeasured dynamics.
d1 == Qin(t), dz == SNOin (t) then:
The parameter T was chosen as for the time constant in open loop to be 0.1 hours (comparable to the time constant in open loop of 0.52 hours) . It was made to show that using the RSS/GMC
Process response to set-point changes are shown in figure (6) . The obtained results show the controller speed in achieving the new operation point. 216
2
•
10
12
14
{j-t ~ 2
18:~ 2
•
6
8
10
12
,
•
1· 10
6
r
12
L
14
16
18
14
16
18
i~f~~~>v 2
10
12
I I 20
20
l~ 2
4
6
8
10
12
'4
16
18
10
m. (h )
16
111
and non-measured strong disturbances in influent flow and concentrations, was very good. The same results was obtained for set point variations.
14
Fig. 4. Process response to measured disturbance in the inflow nitrate concentration (SNO;n) and influent flow (Qin)
2
6
Fig. 6. Process response to set-point changes
I~(h)
1'·1 :: I I
..
ro
""'~)
Fig. 5. Process response to non-measured disturbance in the inflow slowly biodegradable substrate (XS;n) and inflow readily biodegradable substrate (SS;n) 5. CONCLUSIONS This work presents a methodology for the identification and control of nitrate concentration in activated sludge systems. The on-line identification is based on a reduced order model of the process, proposed in the literature, whose parameters were updated through an Extended Kalman Filter. The obtained model properly adjusted to the nitrate concentration dynamics in the anoxic zone, in spite of the adopted assumptions. This was made to simplify the identification and to prove the control algorithm robustness against process modeling errors and non-measured dynamics. The controller project was based on the RSS/GMC technique using the identified process model. The controller performance to measured 217
6. REFERENCES Andersson, B. , U. Nyberg and H. Aspegren (1995). Methanol and ethanol as external carbon sources for denitrification. Nordic Seminar: Espoo , Finland. Barros, P. and B. Carlsson (1998) . Iterative design of a nitrate controller using an external carbon source in an activated sludge process. Water Science and Technology 37(12), 95102. Boaventura, K.M . (1997). State observer for the nitrification/ denitrification process of effluents in sequential batch reactor. Master's thesis. Federal University of ilio de Janeiro , Brazil. (In portuguese) . Cost-624 (1998) . Optimal management ofwastewater treatment system. The European Cooperation in the Field of Scientific and Technical Research, Website: (www.ensic.unancy.frjCOSTWWTPj). Fortescue, T ., L. Kershenbaum and B. Ydstie (1981). Implementation of self-tuning regulators with variable forgetting factor. Automatica 17(6) , 831-835. Franklin, G.F . and J .D. Powell (1980) . Digital control of dynamic systems. Addison-Wesley Publishing Company, Inc. Hallin, S. , C.-F. Lindberg, M. Pell, E . Plaza and B. Carlsson (1996). Microbial adaptation , process performance and suggested control strategy in a pre-denitrifying system with ethanol dosage. Water Science and Technology 34(1-2) , 91-99. Henze, M., W . Gujer, G. Marais and Matsuo M. (1987) . Activated sludge model n.l. Technical Report No.l. IAWQ. London. Isaacs, S., M. Henze, H. Soeberg and M. Kummel (1993) . Activated sludge nutrient removal process control by carbon source addition. Proceedings 12th World Congress of IFAC, Sydney-Australia. 7, 417-420.
Jeppsson, U. (1996). Modelling aspects ofwastewater treatment processes. PhD thesis. Lund Institute of Technology. Lund, Sweden. Lee, P.L. (1993) . Nonlinear Process Control: Applications of Generic Model Control. Springer-Verlag. London. Lee, P.L. and G.R . Sullivan (1988) . Generic model control (GMC). Computers and Chemical Engineering 12(6), 573-580. Lindberg, C.-F. (1997) . Control and estimation strategies applied to the activated sludge processes. PhD thesis. Uppsala University. Uppsala, Sweden. Ljung, L. (1979). Asymptotic behavior of the extended kalman filter as a parameter estimator for linear systems. IEEE TI-ans . on Automatic Control AC24(1) , 36-50. Londong, J . (1992) . Strategies for optimized nitrate reduction with primary denitrification. Water Science and Technology 26(5-6),10871096. Marlin, T .E. (1995). Process Control: Designing - Processes and Control Systems for Dynamic Performance. McGraw-Hill. New York. Takacs, I., G. Patry and D. Nolasco (1991) . A dynamic model of clarification-thickening process. Water Research 25(10), 1263-1271. Yuan, Z., H. Bogaert, P. Vanrolleghem, C. Thoeye, G. Vanstennkiste and W. Verstraete (1997) . Carbon dosage control for predenitrification processes. Proceedings 4th European Control Conference, Brussels-Belgium. Paper TH-A-H 3. Zanabria, O.A., S. Park and C. Garcia (1999a) . A model reference for the control of the activated sludge process. Technical Report BT jPEEj9918. Polytechnic School of the University of Sao Paulo. Silo Paulo, Brazil. (In portuguese). Zanabria, O.A., S. Park and C. Garcia (1999b) . A model reference for evaluating control strategies in activated sludge wastewater treatment plants. Proceedings of the 3rd Int. Res. Conf. on Water Reuse and Water Treatment Plants Operation, Toulouse-France. pp. 295-300.
218