7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
METHOD FOR REAL TIME OPTIMAL CONTROL OF THE ACTIVATED SLUDGE PROCESS Raynitchka Tzoneva Cape Peninsula University of Technology, Cape Town, South Africa,
[email protected] Abstract: The problem for optimal control of the activated sludge process based on ASM1 model is considered. The objective is to determine a method for real time calculation od an optimal dissolved oxygen trajectory and the corresponding optimal state trajectories subject to minimization of both the deviations from the effluent requirements and the control energy consumption. The paper presents the developed reduced biological model of the activated sludge process, Athlone plant mass balance model and method for the optimal control problem solution in a real time. The optimal control problem solution is calculated in Matlab environment and the real time control is implemented in Adroit SCADA environment. Copyright © 2007 IFAC Keywords: wastewater treatment, activated sludge process, reduced model, mass balance equations, optimal control, Lagrange’s functional, decomposition, real time control
1. INTRODUCTION The optimal operation of the wastewater processes with biological treatment is challenging because of the strong effluent requirements, the complexity of these processes as an object of control and the need to reduce the operating cost. The strict requirements were accepted during the last decade in Europe towards the effluent quality. These requirements are coming also to South Africa. The main component of the total operation cost of the wastewater treatment plants is the energy used by the system for aeration. Therefore the Dissolved Oxygen (DO) control is very important because if its values are optimal both will be achieved – the effluent kept in norms and the cost reduced. The complex dynamic behaviour of removal of nitrogen (N) uses two biological processes: nitrification and denitrification, taking place respectively under aerobic and anoxic conditions. These processes are very sensitive towards the influence of the influent disturbances. The influent is the main disturbance to the Activated Sludge Process (ASP) because of its large diurnal variations and dependence on the weather conditions. All mentioned above factors lead to a conclusion that the optimal behaviour of the ASP depends on the oxygen supply according to the process status and the values of the input disturbances. The control of the ASP has been a subject of a big number of studies. Investigation and comparison of different
control strategies was done by Potter et al., (1996), Lukasse (1999), Debusscher et al., (1999), Fikar et al., 2005). Lindberg (1998) proposed linear multivariable control, model predictive control was proposed in (Qin et al., 1997). Most of the mentioned papers considered the optimal control problem in insulation of the whole process characteristics and control tasks. The full biological models are used and because of the large amount of calculations needed, the proposed methods are not applicable for real time control calculation. The solutions depend on the model and can not give good results in the changing process environment. There is a need for real time solution of the problem for optimal control in the frameworks of an adaptive control approach. The paper presents a method for real time calculation of the optimal control of the ASP as a part of a three layer control strategy built on the basis of the influent disturbances prediction, parameter and state estimation, optimal control calculation and controller design. A decomposition method for optimal control problem solution is presented. The software realisation in Matlab is incorporated in the real time control hierarchy in the environment of Adroit SCADA system. 2. CONTROL STRATEGY The control strategy is based on the repetitive optimization, which depends on the frequency and
7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
values of the influent disturbances. Because the values of disturbances are changed during the day, the repetition of the calculations is done with a period of 2 hours. The sequence of problems to be solved are divided in a three layer control structure built in Adroit, Matlab, MySQL environment for control of a Lab scale ASP plant. The hardware of the system consists of PC and PLC. The three-layers of the control structure are developed to solve problems for adaptation, optimization and direct control of the ASP. The calculations of the control actions of every layer is done on the basis of real time data coming from the sensors, from the lab measurements of the process variables, and from prediction of the input disturbances. Fig. 1 shows a break down of the tasks of each layer. Layer of adaptation: Database, Monitoring, Simulation in real time Parameter estimation, Disturbance prediction Model parameters
Process data
Layer of optimization: Optimal control problem, Controller design Set point, Controller parameters Process data Layer of direct control: Control implementation, Controller self tuning Control actions
Sensors signals
Activated Sludge Process
Fig.1. ASP control hierarchy The place of the optimal control problem in the three layer hierarchy for DO control is shown in Fig. 2. Formulation and solution of the optimal control problem is based on a dynamic process model and a selected criterion. Real time calculation and implementation of the optimal control requires simpler models and fast methods. A reduced process model is developed in the next two parts. DO set point Error
PLC PID controller
on/off air flow
DO process
DO concentration
Kp , Ti ,Td
Kp , Ti ,Td calculation
optimal control problem
Model parameters estimation
Disturbance prediction
Due to the complexity of the full model (hard to calibrate, time consuming and computer intensive), the reduced version of the model is used for the purpose of real time optimal control calculation. The requirements towards the reduced model development are to describe adequately both carbonaceous and nitrogenous dynamics and to have minimum number of state variables and parameters to allow real time identification and optimal control calculation. The development is based on analysis of the process dynamics. The ASP is characterised with 3 groups of dynamics – of the biological variables, with time constants of weeks and months, of the carbon and nitrogen removal, with time constants of hours, and of the dissolved oxygen with time constants of minutes. The dynamics of the inflow disturbances are in the same range as the carbon and nitrogen removal ones. This part of the process model can be used for the purposes of the optimal control. Following then some of the model equations characterised with slow dynamics could be neglected. The components used for formulation of the optimal control problem are the concentration of ammonia (SNH), nitrate and nitrite nitrogen (SNO) and of biodegradable substrate (SS). The equation for the biodegradable soluble organic nitrogen (SND) also can be omitted if the input concentration of the (SNH,in) is multiplied by a factor of f (Lukasse, 1999). This is because around 20% of the influent nitrogen is entrapped in organic components and is ammonified. Then f =1.2. The biological processes corresponding to the selected 3 components and included in the reduced models are given in the corresponding Peterson matrix, Table 1. The model parameters and their typical values are given in a Table 2, (Henze et al., 1987). Table1 Peterson matrix of the Reduced ASM1 biological model Process Aerobic growth of XBH Anoxic growth of XBH
SSn
Aerobic growth of XBA Hydrolysis
0
1 YA
−iXB−
1
0
0
−
1 YH
−
1 YH
SNOn 0
−
1− YH 2.86YH
Fig.2. DO control structure in the control hierarchy 3. REDUCED ASM1 BIOLOGICAL MODEL The IAWQ Activated Sludge Model No 1 (ASM1) (Henze et al., 1987) is selected to model the biological processes in the process tanks. It describes the rate of change of concentrations of the different components of wastewater due to the biological activities of the microorganisms. The ASM1 model contains 13 different components, 20 parameters and 8 processes characterised by their process rates.
SNHn
Pnj (n = tank, j = state)
−i XB
SSn µˆ H K S + SS n
− i XB
SSn KOH SNOn η X µˆ H KS + SS KOH+ SO KNO+SNO g BHn n n n
SO n K + S On OH
X BH n
1 S NHn SO n X µˆ A K NH + SNH K OA + SO BAn YA n n Xsn / XBHn khXBHn Kx + Xs / XBH n n SO SNOn n + η KOH K + S h KOH +SO KNO +SNO n n OH On
The behaviour of the components is described by the following set of nonlinear differential equation. S S SO rS NH = − i XB µˆ H K + S X BH − + K S S OH O S SS − iXB µˆ H K S + SS
S NO K OH K + S K + S X BHη g + NO NO OH O
S NH 1 SO + − i XB − µˆ A YA KOA + SO K NH + S NH
X BA
(1)
7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
Table 3: Plant specifications rSNO
1 − YH SS X BH µˆ H = − Y 2 . 86 H KS + SS
K OH S NO η g + K S K S + + O NO NO OH
1 SO S NH + µˆ A Y K S K + O NH + S NH A OA 1 SS rSS = − µˆ H KS + SS YH
1 SS − µˆ H Y K S + SS H
X BA
S O K + S X BH − O OH
(2) (3)
S NO K OH K +S K + S X BH + NO NO OH NO
X s / X BH S O S NO K OH +ηh + kn K +S K + S X BH K x + ( X s / X BH ) KOH + S O NO NO OH NO
Table 2: Model parameters and values Par YA YH iXB µA µH KS KOH KNO KNH KOA ηg ηh kh KX
Values 0.24 0.67 0.086 0.8 6 20 0.2 0.5 1.0 0.4 0.8 0.4 3 0.03
Description AB yield HB yield Nitrogen mass per mass of COD in biomass Maximum specific growth rate for AB Maximum specific growth rate HB Half saturation coefficient for HB Oxygen half saturation coefficient for HB Nitrate for denitrifying heterotrophs Ammonium half saturation coeff. for AB Oxygen half saturation coefficient for AB Correction factor for AB growth Correction factor for hydrolysis Maximum hydrolysis rate Half saturation coefficient for hydrolysis AB – autotrophic biomass HB – heterotrophic biomass
4. ATHLONE PLANT MASS BALANCE MODEL Athlone treatment plant consists of anaerobic, anoxic and aerobic tanks as shown on Fig.3. The process is characterized with flow rates Q and concentrations of the waste material and biomass. Qe represents the effluent flow rate, Qn, n=1,2,3 are the output flow rates for every of the process tanks with corresponding concentrations of the variables SNOn SSn] T, represented by vectors x n= [SNHn n=1,2,3, where n is the number of the tank, xe is the effluent, x 0 the influent, x a the internal recycle, x p the second internal recycle, xr the external recycle vectors of concentrations of the components. All flow rates are described in Table 3.
Description Anaerobic volume Anoxic volume Aerobic volume Degree of sludge recirculation Internal recirculation flow rate Waste flow rate Influent flow
Symbol V anaer. V anoxic V aerobic Qr
Value 1148 m3 1148 m3 5273 m3 40003.2 m3/d
Qa = Qp
39916.8 m3/d
Qw Q0
3840 m3/d 80 000000 m3/d
Settler:The settler is ideal one, without biological reactions and with steady state mass balance. Input to the setter is the flow Q f and the output is Q e . Dependencies for the settler are as follows: Qf = Q3 − Qa − Qw , Qe = Qf − Qr = Qp + Q0 − Qw (4) xw = x3 Mass balance for the particulate substances are: xe = 0 Qe .0 = Q f x3 − Qr x r = (Q3 − Qa − Qw )x3 − Qr x r (5)
x r = (Q3 − Qa − Q w ) / Qr Mass balance for the soluble substances: x e = x3
(
)
Qe x3 = Q f x3 − Qr x r = (Q3 − Qa − Qw )x3 − Q r x r
(Q
p
)
+ Q0 + Qr + Qa − Qa − Qe − Q w x3 = Qr x r
(6) ∴ Qr x 3 = Qr x r and x r = x3 The mass balance equations for the tanks are obtained in a discrete state space with ∆t as a sampling interval. Tank 1:Inputs for the tank 1 are Q 0 x 0 , Q P x 2 , and output is Q1x1 . The mass balance equations are: S NH 1 (k + 1) = S NH 1 (k ) +
∆t Q p SNH 2 (k ) + fQ 0S NHφ1 ( k ) − Q1S NH 1 (k ) + ∆ trS NH (k ) 1 V1
SNO1 (k + 1) = SNO1 ( k) +
∆t Q pSNO 2 ( k) + Q 0SNOφ1 (k ) − Q1S NO1 (k ) + ∆trSNO ( k ) 1 V1
SS1 (k + 1) = SS1 (k ) +
∆t QpSS 2 (k ) + Q0SSφ1 (k ) − Q1SS1 (k ) + ∆trSS (k ) 1 V1
[
]
[
]
(7) Tank 2: Inputs for the tank 2 are Q1x1 , Qa x 3 , Q r x 3 and output is Q 2 x 2 . The mass balance equations are: SNH 2 (k + 1) = SNH 2 (k ) +
[
]
[
]
[
]
∆t Q1S NH1 (k ) + (Q a + Q r )S NH 3 ( k ) − Q1S NH 2 ( k ) + ∆trSNH ( k ) 2 V2
∆t SNO 2 ( k + 1) = S NO 2 (k ) + Q1S NO1 (k ) + (Q a + Q r )SNO 3 ( k ) − Q1S NO 2 ( k ) + ∆trS NO (k ) 2 V2
SS 2 ( k + 1) = SS2 ( k ) +
∆t Q1SS1 ( k ) + (Qa + Q r )SS3 ( k ) − Q1SS 2 ( k ) + ∆trSS ( k ) 2 V2
(8) Tank 3: Input for the tank 3 is Q 2 x 2 and output is Q3 x 3 . The mass balance equations are:
[
]
[
]
S NH 3 (k + 1) = S NH 3 (k ) +
∆t Q 2S NH 2 (k ) − Q 3S NH 3 (k ) + ∆trS NH (k ) 3 V3
Fig. 3. Athlone plant structure
S NO 3 (k + 1) = S NO 3 (k ) +
∆t Q 2S NO 2 (k ) − Q 3S NO 3 (k ) + ∆trSNO (k ) 3 V3
Mass balance model defines accumulation of components in the system as incoming minus outgoing plus/minus concentrations due to biological reactions. The equations are derived for the settler and every tank, where the biological reactions sre represented by the reduced model:
SS3 (k + 1) = SS3 (k) +
[
]
∆t Q 2SS2 (k ) − Q3SS3 (k) + ∆trSS (k ) 3 V3
(9) where ri represent the process rates given by the expression r = 4 C ρ , i = 1,3 where Cij are the i
∑ j =1
ij
j
coefficients from the Peterson matrix for the ASM1
7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
reduced model. The input concentration of SNH is multiplied by a factor f to represent around 20% of influent nitrogen that is entrapped in the organic components.
J (x, u ) =
The vectors of the state and control for every tank form the system state, control and rate vectors. The concentrations are selected to form the vector of state space. Control inputs are the concentrations of dissolved oxygen in the wastewater in every of the tanks. The vectors are: x = [x1
[
= S NH 1
u = [u 1
x3 ]T =
x2
S NO1
S S1
S NH 2
[
u 3 ] = S O1 T
u2
S NO2
S S2
S O2
S O3
]
S NH 3
T
S NO3
S S3
]
T
, x ∈ R9,u ε R3
The vector for the input concentration is:
[
]
xiφ = SNHφ SNOφ SSφ 0 0 0 0 0 0 T
xiφ ε R9
The vector for the biological rates is: T r (x, u , k ) = [r( x1, u1, k ) r( x2 , u2 , k) r (x3 , u3 , k)] r ε R9 From the above notations and mass balance equations the whole system can be written in a vector form in the following way: x (k + 1) = Ax (k ) + C T ρ ( x , u , k ) + Bxiφ (k ), x(0) = x0
(10) K where r ( x, u, k ) in the above equation is represented by CTρ where ρ = [ρ1 process rates C1 C = 0 0
04 x3 C2 0
ρ2
ρ 3 ]T , ρ ε R 12 are the and the matrix
0 C n ∈ R 4 x 3 , C ∈ R 12 x 9 0 , C 3
The matrix
∆t Q0 V1
∆t Q0 V1
0
0
∑ k =0
K −1
x sp ( k ) − x ( k )
2 Q
+ u (k )
2 R
→ min
(11) where x sp ∈ R 9 are the desired trajectories (set points) for the process state, K is the number of steps in the optimization interval, are Q ∈ R 9 x9 , R ∈ R 1x1 positively definite square weighting matrices. Then the problem for optimal control is to find the trajectory of the control input u (k ), k = 0, K − 1 in such a way that the deviation of the process variables from the set points is minimal, subject to the model equation (10) and physical and process limitations over the state and control variables of the form (12) xmin (k ) ≤ x (k ) ≤ xmax (k ), k = 0, K , (13) umin (k ) ≤ u (k ) ≤ umax , k = 0, K − 1 The values of the constraints and set points are given in Table 4. Table 4 States and control set points and constraints Variable DO SNH SNO SS
Min 1 mg.l 2 g/m3 1 g/m3 6 g/m3
Max 4 mg.l 6 g/m3 5 g/m3 20 g/m3
Set Point 2 mg.l 4 g/m3 4 g/m3 10 g/m3
The problem (10)-(13) is solved on the basis of a functional of Lagrange of the form: 2 2 1 K −1 sp x ( k ) − x ( k ) + u ( k ) + ∑ Q R 2 k =0 + λ ( k )T − x ( k + 1) + Ax ( k ) + C T ρ ( x , u , k ) + Bxiφ (k )
L=
[
consists of the coefficients from the Peterson ASM1 matrix for all tanks. The matrix B ∈ R 9 x9 is: ∆t f Q B = V1 0
1 2
0
0
08x9
0
is: A∈ R ∆t 0 (Q ) V 9 x9
∆t 0 0 0 0 0 p 1− V Q 0 1 1 ∆t 0 1− ∆t Q 0 0 0 0 0 0 Qp V1 V1 ∆t ∆t 0 0 1− Q 0 0 0 0 0 Qp V1 V1 ∆t ∆t 0 0 0 0 0 0 0 (Qa +Qr ) Q1 V2 V2 ∆t ∆t 0 0 0 0 0 0 (Qa +Qr) Q1 A= 0 V2 V2 ∆t ∆t 0 0 0 0 0 0 0 (Qa +Qr ) Q1 V2 V2 ∆t ∆t 0 0 0 0 0 0 0 (Qa +Qr ) Q2 V2 V3 ∆t ∆t 0 0 01 0 0 0 (Qa +Qr) Q2 0 V2 V3 ∆t ∆t 0 0 0 0 0 0 (Qa +Qr ) Q2 0 V2 V3
( )
( )
The model (10) is used for the development of a method for solution of the optimal control problem. 5. METHOD FOR OPTIMAL CONTROL PROBLEM SOLUTION The aim of optimization is to minimise the deviation of the ASP effluent from the standards (set points) and to minimise the energy necessary to be used for control. This aim can be presented mathematically by a quadratic criterion of the form
]
(14) 9 where λ ∈ R is the vector of the conjugate variables. Applying the calculus of variation techniques, the necessary conditions for optimality of the Lagrange functional according to the state, control and conjugate variables are derived. ∂L = −Q [x * (k ) − x (k )] + AT λ (k ) − λ ( k − 1) + ∂x ( k ) ∂ρ ( x, u , k ) + CT λ ( k ) = 0 = ex ( k ), k = 1, K − 1 ∂x ( k )
[
]
∂L = −Q T x sp ( K ) − x(K ) − λ ( K − 1) = 0 = e x ( K ), ∂x( K )
∂L ∂ρ ( x, u, k ) = R[u (k )] + C T λ (k ) = 0 = eu ( k ), ∂u(k ) ∂u( k ) k = 0, K − 1 ∂L = −x(k +1) + Ax(k) + CT ρ(x, u, k) + ∂λ(k)
(15)
+ Bxiφ (k) = 0 = eλ (k),k = 0, K −1
The partial derivatives ∂ρ ( x, u , k ) / ∂x(k ) ∈ R12 x 9 and ∂ρ ( x, u , k ) / ∂u ( k ) ∈ R12 x 3 are derived from the process rates expressions in the Paterson matrix. The solution to the equations for the necessary conditions for optimality determines the optimal problem solution. These equations are nonlinear and therefore numerical and decomposition techniques are used to find the solution. Decomposition in time domain (Sing and Titli, 1978) is used. This type of decomposition is based on the prediction of the
7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
conjugate variables. They appear in the necessary conditions for optimality of all other variables. The optimal solution for all other variables depends on the optimal solution for the conjugate variables. Decomposition is in a two level hierarchy where the first level priority is to calculate the state and control variables at separate time moments and coordinating variables are selected and improved in the second level. The calculating structure is shown on Fig 4.
Fig. 4. Two-level calculating structure The solution for every variable is obtained by a gradient procedure with gradients ex , eu , eλ determined from the necessary conditions for optimality (15). Algorithm of calculation: 1. The coordinator determines the values of the coordinating conjugate variables (16) λ (k ) = λA (k ), k = 0, K −1, λ (k ) ∈ R 9 where ℓ is the index of the coordination iterating procedure. The values of vector λ are sent to the problems of the first level, Fig. 4. These problems are parameterized by a vector λ. Their solutions are functions of vector λ. 2. The problems on the first level are to find the optimal trajectories of the state and control variables under the given trajectory of the coordinating variables λℓ(k). These sub-problems are solved by gradient procedures of the following kind:
l +1
sp
A ,q
|| e λ A (k ) ||≤ ε o , ε o > 0, ε o = 0.01 (20) If equation (20) is fulfilled, the obtained solution λℓ, xℓ, uℓ is the optimal one and the calculations stop. If (20) is not fulfilled the new value of the coordinating variable is calculated: (21) λA +1 ( k ) = λA ( k ) + α λ eA λ ( k ), k = 0, K − 1 The new values are sent to the sub problems. The initial trajectories for control and state are taken equal to the one obtained from the previous iteration of the first level x A ,1 (k) = x A -1,1 (k), k = 1, K and
u A,1 (k) = u A -1,1 (k), k = 1, K - 1 and the calculations are repeated until equation (20) is fulfilled. If the condition (20) cannot be reached, the iterations stop when max number of iterations is done ℓ = M. Matlab programme is developed according to the above algorithm and is incorporated in the system for real time control.
x A, q +1 (k ) = x A, q (k ) − α x e x A ,q (k ), k = 1, K − 1 u A ,q +1 (k ) = u A ,q (k ) − α u e x
calculations on first level can stop. If (18) is nor fulfilled, the gradient calculation continue until the maximum number of iterations of the first level N is reached. 4. The obtained trajectories xℓ(k), uℓ(k) are sent to a procedure to check if they belong to the area of constraints determined by the inequalities (12),(13). This is implemented by projection of the obtained values over the area of constraints as follows: v min ( k ), if v A, q ≤ v min ( k ) A A,q A ,q x ( k ) = v , if v min ( k ) ≤ v ≤ v max (k ) v A, q ≥ v max ( k ) v max ( k ), if (19) v = x, k = 1, K , v = u, k = 0, K − 1 The obtained trajectories are sent to the second level to be used for improving the coordinating problem solution. 5. The value of the gradient eλ (k ) is calculated to check how close to optimal solution the obtained one is. The norm of the gradient is checked according to:
(k ), k = 0, K − 1
−1 l
(17) x ( K ) = x ( K ) + Q λ ( K − 1) where q is the index for the gradient procedure and αx and αu are the steps of the gradient procedures. They are selected small in order to achieve convergence of the calculations. The calculation with the gradient procedures start for q=1, ℓ = 1 with the initial values for the control trajectory u1,1 (k ) = u1,1 (0) u1,1 (1) ...u1,1 (K − 1) and calculated on its bases initial state trajectory according to the model equation (10). 3. The values of the gradients are used to determine how close is the solution to the optimal one under the given values of the coordinating procedure vector λ(k). In order to do this evaluation a norm of the gradients is calculated and it is compared with some small positive number close to zero. If
[
]
e x A, q (k ) ≤ ε x , ε x > 0, ε x < 0
ε x = 0.01
e u A,q ( k ) ≤ ε u , ε u > 0, ε u < 0
ε u = 0.01
(18)
(18) is fulfilled, the gradient procedures is reaching the point close to the optimal solution and the
6. REAL TIME CONTROL The real time implementation of the optimal control solution is done in the SCADA system Adroit. Adroit is built on a client – server architecture. The client portion, which typically is the part of the application that interacts with the user, communicates with the server portion, which usually is a data repository. Adroit accesses information from the Modikon PLC registers, sends it to the MySQL database and presents it to the PC screen as graphic information (mimics) to be used by the plant operators. Real time control is implemented on the created Adroit User Interface (UI), where also the status of the plant is shown in real time, Fig.7. In the main window, the user can open the database query browser to view data stored in the database. Small windows are used to display the concentration of compounds in every tank. Ordinary diagrams are used to plot the concentrations of the three
7
3URFHHGLQJVRIWKHWK0HGLWHUUDQHDQ&RQIHUHQFHRQ &RQWURO $XWRPDWLRQ-XO\$WKHQV*UHHFH
compounds (SNH, SNO, SS) and the optimal DO control trajectory. The influent concentration representing the predicted input concentrations and the effluent and DO concentrations achieved after optimal control problem is solved can also be displayed.The control strategy was implemented using the simulated influent data, Fig. 5. The file is generated to simulate a dry weather period (Alex et al., 1999) and is saved in database. The data for the measured initial values of the SNH, SNO, SS for every tank and the steady state values of the heterotrophs and autotrophs are read by the Matlab program from the database using the Matlab database toolbox commands. The calculated optimal DO and the corresponding optimal state trajectories are sent in the same way to the database from where they are used to determine the optimal set point for the DO controller. The obtained optimal trajectories for the effluent are shown on Fig. 6.
simpler problems of the mathematical programming. The calculation shows good convergence towards the optimal solution and depend on the values of the steps in the gradient procedures, weighting matrices and the maximum number of iteration on the first level sub-problems.
Fig. 7. Adroit graphical user interface 8. ACKNOWLEDGMENT Fig. 5. Dry-weather influent file
The research work is under the NRF project “Advanced control of wastewater treatment”. GUN 2064957. REFERENCES
Fig.6. Optimal DO and states trajectories 7. CONCLUSION Reduced models and a decomposition method for calculation of the optimal process control for the Athlone wastewater treatment plant using ASM1 reduced model are developed. The comparison between the graphs in Fig. 5 and Fig 6 shows good reduction of the inflow concentrations. The developed algorithm and Matlab programs are implemented for real time control in the software environment of Adroit SCADA system. The applied control strategy is a repetitive one, based on the prediction of the variations of the influent disturbances which allows the process to be controlled according to its main disturbance. The developed solution of the optimal control problem on the basis of the conjugate variable predictions leads to simplification of the calculating process according to the dimension and complexity of the sub-problems solved on the first and second level of the calculating structure. Time domain decomposition transforms the dynamic optimal control problem into a series of
Alex, J.F. Beteau, J.B. Copp, et al. Benchmark for evaluating control strategies in wastewater treatment plants. In Proc. ECC’99, Karlsruhe, Germany, 1999. Debusscher D., H. Vanhooren and P. Vanrolleghem. (1999). Benchmarking two biomass loading control strategies for activated sludge WWTPs. In Proceed. Of the 13 Forum on Applied Biotechnology, Univ. Gent, 64/5a. 127-132. Fikar, M., B. Chachat and M. Latifi. (2005). Optimal operation of alternating activated sludge processes. Cont. Eng. Practice, 13, 853-861. Henze, M., C. Grady, W. Gujer, G. Marais and T. Matsuao.(1987). Activated Sludge model No 1. Technical report 1, IAWQ, London. Lindberg, C.F. (1998). Multivariable modelling and control of an activated sludge process. Water Science Technology, 37 (12), 149-156. Lukasse L. (1999). Control and Identification in Activated Sludge Processes. PhD Thesis Potter, T., B. Koopman and S. Svoronos. (1996). Optimisation of a periodic biological process for nitrogen removal from wastewater. Water Research, 30 (1), 142-152. Qin, S., V. Martinez and B. Foss.(1997). An interpolating model predictive control strategy with application to a waste treatment plant. Computers and Chemical Engineerings, 21, (S1), S881-S886. M. Singh and A Titli. Systems: Decomposition, Optimization and Control. New York: Pergamon Press. 1978.