# Active Disturbance Rejection Control of a Coupled-Tank System

Authors: Fayiz Abukhadra
Journal: Journal of Engineering
 (2018)

---

## Abstract

In process industries, liquid is pumped and stored in interacting coupled tanks. The liquid level in these tanks must be accurately controlled. This study aims to investigate the performance of the active disturbance rejection control method in controlling a coupled-tank system. A mathematical model of the coupled-tank system is derived to facilitate a simulation study. Assuming that the water level in the second tank is the only measured state, an extended observer with time-varying parameters estimates the second state and the total disturbances of the system. The system is then regulated using a time-varying feedback controller. The results show the effectiveness of the method in improving the time domain measures and the disturbance rejection compared to other controllers.


---

## Body

## 1. Introduction

In process control, the liquid level control in multiple connected tanks performed by controlling the liquid flow is a typical nonlinear control problem present in many industrial processes. A mathematical model of the plant is required to design a controller to maintain a constant level in such tanks. The mathematical model of the controlled plant can be obtained by two techniques: analytical and experimental. The mathematical models for a coupled-tank system are obtained by applying the laws of energy conservation, mass conservation, etc. The mathematical models obtained by means of analytical designs are generally complex and most often contain nonlinear dependencies of variables. The need to estimate system uncertainties using input and output is a fundamental problem of the control theory. Different methodologies were proposed to solve this problem. Among them are the backstepping control strategy [1], the adaptive fuzzy proportional-integral controller [2], the neurofuzzy-sliding mode controller [3], the hybrid fuzzy inference system that uses artificial hydrocarbon networks at the defuzzification step or the so-called fuzzy-molecular control [4], and second-order sliding mode controllers (SMC) [5]. A hybrid system that combines the advantages of the robustness of the fractional control and the SMC [6] and a digital proportional integral controller [7] were also proposed. Moreover, an observed-state feedback controller via eigenvalue assignment and linear-quadratic-Gaussian control were designed in discrete-time and implemented by an industrial controller (i.e., programmable logic controller) [8]. Several other researchers reported model-based controllers as the development of an optimal PID controller for controlling the desired liquid level using the particle swarm optimization (PSO) algorithm for optimizing the PID controller parameters [9]. A static sliding mode control scheme was proposed for the system [10], and two different dynamic sliding mode control schemes were proposed to reduce the chattering problem associated with the static sliding mode control scheme.The active disturbance rejection control (ADRC) [11] is a method that does not require a complete mathematical description of the system. The basic idea for this method comprises the use of an extended observer coupled with a feedback controller in the closed-loop control. The observer estimates all states of the system, uncertainties, and external disturbances (total uncertainty). The total uncertainty is considered as an extended state of the system. If the estimation of the observer is accurate, the system to be controlled is converted to a simpler model because the total uncertainty is canceled in real time. The ADRC method has been successfully applied to several practical problems [12–14].The current study aims to apply the ADRC method to regulate the liquid level in the second tank of a coupled-tank system. In addition, this study attempts to reduce the tuning parameters of the ADRC, use the time-varying parameters of the observer and the controller, and optimize the parameters of the observer and the controller using the integral absolute error (IAE) as the cost function and the genetic algorithm as the optimization method. To the best of the author’s knowledge, this is the first study to apply the ADRC method to the problem of the coupled-tank system.The remainder of this paper is structured as follows: Section2 derives a mathematical model of the coupled-tank system and introduces the ADRC method; Section 3 describes the ADRC method used herein and discusses the simulation results; and Section 4 concludes this paper.


## 2. Methods

### 2.1. Mathematical Modeling of the Coupled-Tank System

Figure1 shows a schematic of the coupled-tank system, which consisted of two connected tanks. A pump supplied water into the first tank (q). The second tank was filled from the first tank via a connecting pipe (q1). An outlet was located at the bottom of the second tank to change the output flowq2. The mathematical model of the coupled-tank system is nonlinear.Figure 1
Schematic diagram of the coupled-tank system.We derive the following equation by applying the flow balance equation for tanks 1 and 2 [10]:(1)dh1dt=1Aq-q1dh2dt=1Aq1-q2In (1),q1 andq2 are defined as follows [10]:(2)q1=a12gh1-h2forh1>h2q2=a22gh2forh2>0whereh1 andh2 are the water level in tanks 1 and 2, respectively;q is the inlet flow rate;q1 is the flow rate from tanks 1 to 2;A is the cross section area for both tanks;a1 is the area of the pipe connecting the two tanks;a2 is the area of the outlet; and g is the constant of gravity. The system can be considered as a single input-single output system (SISO) if the inlet flowq is selected as the input and the liquid levelh2 in the second tank is selected as the output. The dynamic model of the coupled tanks is described by the following equation [10]:(3)dh1dt=-k1signh1-h2h1-h2+qAdh2dt=k1signh1-h2h1-h2-k2h2Parametersk1 andk2 are defined as follows:(4)k1=a12gAk2=a22gANote thatq is always positive, which means that the pump can pump water into the tank (q≥0). At equilibrium, for the constant water level set point, the derivatives with regard to the water levels in the two tanks must be zero, such that the following condition can be written:(5)dh1dt=dh2dt=0Therefore, the following algebraic relationship holds when (3) is used in (5):(6)-k1signh1-h2h1-h2+qAk1signh1-h2h1-h2-k2h2The equilibrium flow rateq can be calculated as follows:(7)q=-Ak1signh1-h2h1-h2In the case of coupled tanks, the inequalityh1≥h2holds in every operating point, which implies that the terms k1signh1-h2≥0. The dynamic model can then be written as(8)dh1dt=-k1h1-h2+k2h2dh2dt=-k1h1-h2-2k2h2+1AuUsing the following transformation,(9)x1=h2x2=-k1h1+k2h1-h2Eq. (8) can be written as(10)x˙1=x2x˙2=fx,t+gx,tuy=x1Accordingly,f(x,t) and g(x,t) in (10) have the following form:(11)fx,t=k1k22h2h1-h2-h1-h2h2+k122-k22gx,t=k22A1h1-h2


### 2.2. Active Disturbance Rejection Control

The ADRC method is explained on the second-order SISO dynamical system of the following form:(12)x˙1=x2x˙2=fx,t+dt+gx,tuty=x1where u(t) and y(t) are the system input and output, respectively. The nonlinear function f(x,t) is the internal dynamics of the system, and d(t) is the external disturbance. Taking the estimation value of g(x,t) as b0, (15) can be rewritten as follows:(13)x˙1=x2x˙2=x3+b0utx˙3=f˙y=x1where the state variables x1 and x2 are the system states, and x3=f is added as an additional state representing the total disturbance. The states of (13) are estimated using an extended state observer (ESO). The main advantage of an ESO is that it can estimate the total uncertainties without knowledge of the system’s mathematical model. The ESO treats the total uncertainties as a new state. An ESO for the second-order system is constructed as follows [15, 16]:(14)x^˙1=x^2t+α1Rtx^2t-x1tx^˙2=x^3t+α2R2tx^2t-x1t+b0utx^˙1=α3R3tx^2t-x1tThe time-varying functionR(t) has the following form:(15)Rt=Ro1-e-at1+e-atThe parameterαi in (21) can be determined, such that the characteristic polynomial(16)λs=s3+α1s2+α2s+α3is Hurwitz.If the observer tuning procedure is adequate, the observer states converge to the system statesx^1 → x1,x^2 → x2, and x^3 → x3 in finite time.The control objective is to cancel the total disturbance while satisfying the tracking task. The total disturbance is rejected with the system input signal:(17)ut=-x^3t+u0tb0where u0(t) is a control signal from a feedback controller. Substituting (17) in (13) and assuming an accurate estimation of the total disturbance, the controlled system transforms to a double integrator:(18)x¨t=x3-x^3t+u0t≈u0tA double integrator can be controlled with any classical controller design. The following control law can be obtained if a linear proportional and derivative controller is used:(19)u0t=kprt-x^1t-kdr˙t-x^2twhere rtandr˙(t)are the reference signal and its derivative, respectively; and x^1(t) and x^2(t) are the estimated states of the plant. One possible method to simplify the controller tuning is to set(20)kd=Rtandkp=R2t4.Figure2 shows the block diagram of the ADRC closed-loop system.Figure 2
Block diagram of the ADRC for second-order system.


## 2.1. Mathematical Modeling of the Coupled-Tank System

Figure1 shows a schematic of the coupled-tank system, which consisted of two connected tanks. A pump supplied water into the first tank (q). The second tank was filled from the first tank via a connecting pipe (q1). An outlet was located at the bottom of the second tank to change the output flowq2. The mathematical model of the coupled-tank system is nonlinear.Figure 1
Schematic diagram of the coupled-tank system.We derive the following equation by applying the flow balance equation for tanks 1 and 2 [10]:(1)dh1dt=1Aq-q1dh2dt=1Aq1-q2In (1),q1 andq2 are defined as follows [10]:(2)q1=a12gh1-h2forh1>h2q2=a22gh2forh2>0whereh1 andh2 are the water level in tanks 1 and 2, respectively;q is the inlet flow rate;q1 is the flow rate from tanks 1 to 2;A is the cross section area for both tanks;a1 is the area of the pipe connecting the two tanks;a2 is the area of the outlet; and g is the constant of gravity. The system can be considered as a single input-single output system (SISO) if the inlet flowq is selected as the input and the liquid levelh2 in the second tank is selected as the output. The dynamic model of the coupled tanks is described by the following equation [10]:(3)dh1dt=-k1signh1-h2h1-h2+qAdh2dt=k1signh1-h2h1-h2-k2h2Parametersk1 andk2 are defined as follows:(4)k1=a12gAk2=a22gANote thatq is always positive, which means that the pump can pump water into the tank (q≥0). At equilibrium, for the constant water level set point, the derivatives with regard to the water levels in the two tanks must be zero, such that the following condition can be written:(5)dh1dt=dh2dt=0Therefore, the following algebraic relationship holds when (3) is used in (5):(6)-k1signh1-h2h1-h2+qAk1signh1-h2h1-h2-k2h2The equilibrium flow rateq can be calculated as follows:(7)q=-Ak1signh1-h2h1-h2In the case of coupled tanks, the inequalityh1≥h2holds in every operating point, which implies that the terms k1signh1-h2≥0. The dynamic model can then be written as(8)dh1dt=-k1h1-h2+k2h2dh2dt=-k1h1-h2-2k2h2+1AuUsing the following transformation,(9)x1=h2x2=-k1h1+k2h1-h2Eq. (8) can be written as(10)x˙1=x2x˙2=fx,t+gx,tuy=x1Accordingly,f(x,t) and g(x,t) in (10) have the following form:(11)fx,t=k1k22h2h1-h2-h1-h2h2+k122-k22gx,t=k22A1h1-h2


## 2.2. Active Disturbance Rejection Control

The ADRC method is explained on the second-order SISO dynamical system of the following form:(12)x˙1=x2x˙2=fx,t+dt+gx,tuty=x1where u(t) and y(t) are the system input and output, respectively. The nonlinear function f(x,t) is the internal dynamics of the system, and d(t) is the external disturbance. Taking the estimation value of g(x,t) as b0, (15) can be rewritten as follows:(13)x˙1=x2x˙2=x3+b0utx˙3=f˙y=x1where the state variables x1 and x2 are the system states, and x3=f is added as an additional state representing the total disturbance. The states of (13) are estimated using an extended state observer (ESO). The main advantage of an ESO is that it can estimate the total uncertainties without knowledge of the system’s mathematical model. The ESO treats the total uncertainties as a new state. An ESO for the second-order system is constructed as follows [15, 16]:(14)x^˙1=x^2t+α1Rtx^2t-x1tx^˙2=x^3t+α2R2tx^2t-x1t+b0utx^˙1=α3R3tx^2t-x1tThe time-varying functionR(t) has the following form:(15)Rt=Ro1-e-at1+e-atThe parameterαi in (21) can be determined, such that the characteristic polynomial(16)λs=s3+α1s2+α2s+α3is Hurwitz.If the observer tuning procedure is adequate, the observer states converge to the system statesx^1 → x1,x^2 → x2, and x^3 → x3 in finite time.The control objective is to cancel the total disturbance while satisfying the tracking task. The total disturbance is rejected with the system input signal:(17)ut=-x^3t+u0tb0where u0(t) is a control signal from a feedback controller. Substituting (17) in (13) and assuming an accurate estimation of the total disturbance, the controlled system transforms to a double integrator:(18)x¨t=x3-x^3t+u0t≈u0tA double integrator can be controlled with any classical controller design. The following control law can be obtained if a linear proportional and derivative controller is used:(19)u0t=kprt-x^1t-kdr˙t-x^2twhere rtandr˙(t)are the reference signal and its derivative, respectively; and x^1(t) and x^2(t) are the estimated states of the plant. One possible method to simplify the controller tuning is to set(20)kd=Rtandkp=R2t4.Figure2 shows the block diagram of the ADRC closed-loop system.Figure 2
Block diagram of the ADRC for second-order system.


## 3. Results and Discussion

Table1 lists the numerical values of the parameters of the coupled-tank system [10].Table 1
Characteristic of the coupled-tank system.
Gravitational rateg 981 cm/s2  Cross-sectional area of both tanks 208.2 cm2  Area of the connecting pipea12 0.58 cm2  Area of the outleta2 0.3 cm2The range of the pump flow rate was limited betweenumin = 0 and umax = 50 [cm3/s].The Methods clearly showed that the parameters of the closed-loop control using ADRC areα1,α2,α3,Ro,b0, and a. The Hurwitz characteristic polynomial is selected as follows with the poles −4.4848, −0.2576 + 2.5735i, −0.2576 − 2.5735i:(21)λs=s3+5s2+9s+30Accordingly,Ro,b0,anda were obtained using a genetic algorithm optimization method with the objective of minimizing the IAE defined as follows:(22)IAE=∫0tedtThe optimum parameters obtained areR0=78.14,b0=0.30,anda=0.99.Figure3 shows the regulation performance of the controller for a desired level of 6 cm and confirms that the controllers successfully regulated the water level. Figure 4 depicts the control signal of the ADRC. Figure 5 presents the ESO performance in estimating the system states. The observer accurately estimated the states. The errors e1t=x1-x^1,e2t=x2t-x^2t and e3t=x3(t)-x^3(t) converged to zero in less than 1 s.Figure 3
Response of the system for the 6 cm desired level.Figure 4
Performance of the ESO in estimating the system states.Figure 5
Control signal of the ADRC for the 6 cm desired level.The following performance measures were introduced to facilitate a comparison with the other control methods: the settling time defined as the time taken until the output finally settles within 2% of the steady state value; the rise time,Tr, defined as the time taken by the output to change from 10% to 90% of its final value; and, in addition to the IAE, the integral squared error (ISE) and the time weighted absolute error (ITAE) computed as follows:(23)ISE=∫0te2dt(24)ITAE=∫0ttedtThe performance of the ADRC was then compared with that of the SMC method reported in [10]. Table 2 presents the rise time, settling time, and error indices (i.e., IAE, ISE, and ITAE) for the design in [10] and the ADRC method. The table clearly shows that the ADRC outperforms the other designs in all performance measures. The response of the system controlled by the ADRC took 58.2 s to settle, whereas that in the design in [10] took 113 s. The rise time of the output response in the ADRC controller was 46 s, whereas that of the SMC was 52 s. The ADRC method resulted in a 48% smaller settling time than that in [10]. Moreover, the rise time was 27% smaller than that in [10]. The IAE, ISE, and ITAE were 41%, 50%, and 56% smaller than those in [10].Table 2
Comparison of the performance index measures.
Performance measure Method Improvement [%] SMC [10] ADRC Settling time 113.1 58.2 48  Rise time (s) 52.1 37.8 27  IAE 114.5 67.86 41  ISE 254.8 126.8 50  ITAE 2690 1190 56As a second test, we tested the ADRC in a tracking test. The set point tracking test consisted of successively changing the set point during the operation (Figure6). The set point change was performed at 200 s by a magnitude of 6 cm height in the water level. Consequently, the ADRC method accurately tracked the set point changes in the water level. The same parameters were used for the ADRC for the tracking experiment.Figure 6
Set point tracking performance of the system.As a third test, we checked the ADRC performance against the input disturbance. An external flow rate of 60 cm3/s that started at 150 s and ended at 200 s was applied. Figure 7 illustrates the closed-loop response of the ADRC control and shows how fast the controller response was to the disturbance and corrected it.Figure 7
Closed-loop response of the system against the input disturbance.


## 4. Conclusions

In this study, the ADRC approach was successfully implemented with the design tested by a simulation to control the water level in the second tank of a coupled-tank system. The effectiveness of the ADRC method was verified through computer simulations. The results showed that this control method can control a nonlinear system at all possible operating points. The designed ADRC achieved the desired transient response with small rise and settling times. The advantages of the ADRC are as follows: (a) easiness and simplicity in design; (b) nonrequirement of a mathematical model of the plant; and (c) robustness against uncertainty and disturbance. Further work is anticipated in the practical implementation of the proposed ADRC technique.



---

*Source: 7494085-2018-07-08.xml*