## 1. Introduction

Industrial processes show some characteristics that make difficult their regulation, for instance multivariable interactions between controlled and manipulated variables, non-measurable state variables, non-measurable disturbances, uncertain and time-varying parameters, restrictions in manipulated variables and nonlinearities, among others [

1,

2,

3]. Modern control strategies involve the use of compensators that comprise a state feedback and an observer [

4]. Observers are used to reconstruct the unmeasured state variables, since they are either unmeasurable (e.g., when they have no physical sense) or there is no technical and/or economical viability to use high-priced sensors, from the input–output behavior [

5,

6].

State observers and soft sensors are being used more often nowadays in control systems to achieve different objectives in several industries. For instance, Liu [

7] presented a robust adaptive observer for multiple-input multiple-output nonlinear systems with unknown parameters, uncertain nonlinearities, disturbances and unmodeled dynamics; Ciccio et al. [

8] proposed a new nonlinear observer-based controller for time-delay nonlinear systems; Fernandes et al. [

9] proposed a motion control system for a underwater vehicle using a MIMO PID controller aided by a high-gain observer; Turki et al. [

10] developed a backstepping control for a tank process based on adaptive observers; Aguilar-Garnica et al. [

11] designed and applied a reset observer in order to provide on-line estimation of the concentration of Free Fatty Acids from temperature measurements within a continuous stirred tank reactor; Eleiwi and Laleg-Kirati [

12] presented a nonlinear observer-based Lyapunov control for a membrane distillation process; Kleindienst et al. [

13] used the measurement of temperature at one single point of a silicon wafer to estimate the remaining wafer temperature profile using a state observer; and Lisci et al. [

14] developed a geometric observer to design a model-based soft sensor for the estimation of quality indexes in a bioreactor. Sheng et al. [

15] went further and showed how smart soft sensors can be combined with machine learning techniques to significantly save human resources and improve performance under complex industrial conditions. Although there are several estimation techniques, as stated in [

16], it is difficult to select the proper one for specific applications; hence, the authors performed a review of observers recently used in process control and classified them into six classes.

Several studies for control systems have been performed using tanks because of their reconfiguration possibilities and easiness to visualize variables [

17,

18]. Hou et al. [

19] provided a method for designing nonlinear state observers that can be used to design observers for models of induction motors and three-tank systems. Hou et al. [

20] performed the observability analysis and observer synthesis for a three-tank water process taking into account singularities of nonlinear observers. Pan et al. [

21] addressed the nonlinear control design problem for a state-coupled two-tank liquid level system. Korbicz and Witczak [

22] designed a bank of extended unknown input observers for fault diagnosis of a two-tank system. Zhou et al. [

23] designed three receding horizon predictive control strategies for a three-tank system based on the structural characteristics of a hybrid pseudo-linear RBF-ARX model. Prajapati and Roy [

24] used unknown input observers for fault detection and isolation in a three-coupled tank system. Li et al. [

25] proposed and evaluated an energy-efficient data transmission scheme for remote state estimation in a two-tank system. More recently, Arasu and Prakash [

26] designed and implemented predictor-corrector based control schemes for a single input-single output nonlinear lab-scale conical tank system. Patel and Shah [

27] developed a fault-tolerant controller for nonlinear systems that was implemented and validated on a computer model of a three interconnected conical tank system. Zhao and Zhang [

28] proposed an inverse tangent functional nonlinear feedback control and carried out a case study related to the water tank level control system. Most of the referenced works rely on two types of tanks: cascade tanks, where the input flow goes into the first tank, and the level of each tank depends on the level of the previous tank, such as the benchmark quadruple tank system [

29,

30,

31], and interacting tanks, where the input flow additionally depends on the current level [

32,

33].

High-gain observers have been considered to estimate the state in processes with nonlinear dynamics because they have robust estimation properties and disturbance rejection capabilities [

34,

35,

36,

37,

38]. Regarding process control using HGOs, some works have been reported in literature. For instance, Lafont et al. [

39] designed an adaptive high-gain observer for wastewater treatment systems. Turki et al. [

40] introduced an output-feedback control scheme that combines nonlinear backstepping control with an adaptive high-gain observer in a two-tank process. Banerjee and Jana [

41] synthesized an estimator-based hybrid control scheme that consists of a high gain nonlinear observer and the extended generic model controller and tested it in reactive distillation column. Gouta et al. [

42] reported the nonlinear control design for a state coupled two-tank liquid level system which combines a nonlinear generalized predictive controller with a high-gain observer. Ayadi et al. [

43] implemented a high-gain observer which provides a full state estimation (position, velocity, temperatures and pressures) in an electropneumatic system. Wang et al. [

44] proposed a sliding-mode dynamic surface control strategy based on a high-gain observer for glue mixing and dosing control in the particleboard process.

Although some reported works in the literature about observer design show plant tests in fixed lab rigs, just a few provide either the complete observability analysis or the use of robust industrial instruments. This work addresses the complete observability analysis, in the Herman–Krener sense, for a three-tank process that combines tanks in series, interaction and nonlinear weirs and the design and implementation of a high-gain observer that guarantees convergence of the state estimation. The validation and comparison to the Extended Kalman Filter, of this observer, was performed using both simulations and real tests in a multipurpose experimental station that uses industrial instrumentation and provides flexibility to change dynamics and nonlinear behavior, as briefly addressed in [

18].

The organization of the paper is as follows. In

Section 2, the plant is described and a state–space model is analyzed.

Section 3 shows the observability analysis of the set-up using the notions in [

45].

Section 4 contains the design of the high-gain observer. Numerical simulations are provided in

Section 5. The experimental results for the multipurpose station are presented in

Section 6. Finally, conclusions are presented in

Section 7.

## 2. Process Modeling

As addressed in [

18], the process comprises three tanks arranged as shown in

Figure 1. The system consists of three tanks,

${T}_{1}$,

${T}_{2}$, and

${T}_{3}$, and each tank is equipped with a real level transmitter (LT). The two interacting Tanks

${T}_{1}$ and

${T}_{2}$ are connected in series with the third Tank

${T}_{3}$. An electrical pump (P-1) is used to provide water supply into the system through two different branches, namely main and secondary, and, to measure the flow through the branches, each branch is equipped with an electromagnetic flow transmitter (FIT). Flow regulation in the main branch is achieved with the help of a control valve (UV-UY), which allows the manipulation of input flow to Tank

${T}_{1}$. Using a manual valve (HV) located in the secondary branch, disturbances to the system are injected at Tank

${T}_{3}$. In this paper, the input to the system is the flow regulated by the control valve, whereas the output of the system is the level in Tank

${T}_{3}$ (see [

46,

47,

48] for further details about the process).

The mathematical model can be obtained performing a mass balance in each tank, which is given by [

18]

where

${\dot{m}}_{\mathrm{in}}$ and

${\dot{m}}_{\mathrm{out}}$ are the input and output mass flows, respectively, and

$\dot{m}$ denotes the accumulation of mass in the tank. Assuming environment conditions, the density of water (the fluid process) is constant; therefore, Equation (

1) becomes

where

${q}_{\mathrm{in}}$ and

${q}_{\mathrm{out}}$ are the input and output volumetric flows, respectively,

A is the cross-section area and

$\dot{h}$ is the level variation in that tank.

Applying Equation (

2) for Tanks

${T}_{1}$,

${T}_{2}$, and

${T}_{3}$ yields

with

${q}_{\mathrm{in}}$ the input flow to Tank

${T}_{1}$ and

${q}_{i}\left({h}_{i}\right)$ the output flow from Tank

${T}_{i}$,

$i\in \{2,3\}$, where

${A}_{j}>0$ and

${h}_{j}$ are the cross-section areas and water levels of Tank

${T}_{j}$,

$j\in \{1,2,3\}$, respectively, and

${k}_{12}>0$ is the coupling orifice constant. In Equation (

3),

$\left|\phantom{\rule{0.166667em}{0ex}}\xb7\phantom{\rule{0.166667em}{0ex}}\right|:\mathbb{R}\to [0,\infty )$ is the absolute value function and

$sgn:\mathbb{R}\to \mathbb{R}$ is the sign function, that is,

and

The output flow from Tank

${T}_{2}$ to Tank

${T}_{3}$ can be chosen according to the sharp crested weir type. The general formula for the weir [

49] can be written as

where

${k}_{j}$ is the coefficient of the weir for Tank

${T}_{j}$ and

${\mathrm{lb}}_{j}$ is the distance from the bottom of the tank to the crest of the weir in Tank

${T}_{j}$;

${n}_{j}$ is the order of the weir, which depends on the shape; and

$H\left(\phantom{\rule{0.166667em}{0ex}}\xb7\phantom{\rule{0.166667em}{0ex}}\right)$ is the Heaviside step function, that is,

In addition, since the zeros of the sensors can be calibrated to match the lower boundary of each weir and the working space is always above this level, for each

$j\in \{2,3\}$, Equation (

4) can be written as

${q}_{j}={k}_{j}{h}_{j}^{{n}_{j}},\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}{h}_{j}>0$.

To get a state–space realization of the system, let us define the state vector as

$x={[{x}_{1},{x}_{2},{x}_{3}]}^{\mathrm{T}}\stackrel{\mathrm{def}}{=}{[{h}_{1},{h}_{2},{h}_{3}]}^{\mathrm{T}},$ and define the function

$s\mapsto m\left(s\right)$ as

$m\left(s\right)\stackrel{\mathrm{def}}{=}\sqrt{\left|s\right|}sgn\left(s\right)$. The water level in the three tanks is non-negative, i.e.,

${h}_{i}\ge 0$,

$i\in \{1,2,3\}$. Then, the state–space representation of the plant is given by

where the state vector

$x\in {\mathbb{R}}_{\ge 0}^{3}$ and the scalar input

${u}_{1}>0$ is the input flow, i.e.,

${u}_{1}={q}_{\mathrm{in}}$. The drift and control vector fields are given by

with

$A\stackrel{\mathrm{def}}{=}\mathrm{diag}\left({A}_{1}^{-1},{A}_{2}^{-1},{A}_{3}^{-1}\right)$,

and

$x\mapsto \mu \left(x\right)$ is given by

where

${e}_{i}\in {\mathbb{R}}^{3}$,

$i\in \{1,2,3\}$, is the

ith column of the

$3\times 3$ identity matrix

${I}_{3}$. The output function is linear, that is,

$h\left(x\right)={c}^{\mathrm{T}}x$ with

$c\stackrel{\mathrm{def}}{=}{e}_{3}$. In addition, recall that

${A}_{1}$,

${A}_{2}$,

${A}_{3}$,

${k}_{12}$,

${k}_{2}$,

${k}_{3}$,

${n}_{2}$ and

${n}_{3}$ are all known, nonzero positive constants and hence

A and

K are nonsingular matrices. Consequently, from Equation (

6), the equilibrium points are given by those points where

$\mu \left(\phantom{\rule{0.166667em}{0ex}}\xb7\phantom{\rule{0.166667em}{0ex}}\right)$ vanishes, that is,

${X}_{e}\stackrel{\mathrm{def}}{=}\left\{x\in {\mathbb{R}}_{\ge 0}^{3}:\mu \left(x\right)=0\right\}$; from Equation (

8) it follows that

${X}_{e}=\left\{0\right\}$.

From

Figure 1, it can be noticed that the level in the third tank only depends on the output flow of the second Tank

${T}_{2}$. Therefore, the complete system can be seen as the interconnection of two systems in cascade: two interacting tanks and the lower tank. Hence, the phase portrait is used in order to analyze the behaviour of the two interacting Tanks

${T}_{1}$ and

${T}_{2}$. To this end,

${R}_{1}\stackrel{\mathrm{def}}{=}\{{[{x}_{1},{x}_{2},{x}_{3}]}^{\mathrm{T}}\in {\mathbb{R}}_{\ge 0}^{3}:{x}_{1}>{x}_{2}\}$,

${R}_{2}\stackrel{\mathrm{def}}{=}\{{[{x}_{1},{x}_{2},{x}_{3}]}^{\mathrm{T}}\in {\mathbb{R}}_{\ge 0}^{3}:{x}_{1}<{x}_{2}\}$, and

${R}_{3}\stackrel{\mathrm{def}}{=}\{{[{x}_{1},{x}_{2},{x}_{3}]}^{\mathrm{T}}\in {\mathbb{R}}_{\ge 0}^{3}:{x}_{1}={x}_{2}\}$. Referring to

Figure 2,

${R}_{1},{R}_{2}$ and

${R}_{3}$, respectively, denote regions where the level in

${T}_{1}$ is greater than that of

${T}_{2}$, the level in

${T}_{1}$ is lower than in

${T}_{2}$ and the levels in Tanks

${T}_{1}$ and

${T}_{2}$ are equal.

Figure 3 shows the phase portrait of the levels in Tanks

${T}_{1}$ and

${T}_{2}$ without the input. As it is shown, trajectories starting from different initial conditions in the regions

${R}_{1}$ and

${R}_{2}$ approach the equilibrium point (origin). Nevertheless, this depends on the value of

${k}_{12}$, since a large value correspond to almost zero restriction between the two tanks, transforming the two tanks into a single one.

## 3. Observability Analysis

Consider a general nonlinear system

defined on

${\mathbb{R}}^{n}$, where

$f$ is a smooth and complete vector field on

${\mathbb{R}}^{n}$, the input vector

$u$ takes values in a compact subset

$\Omega $ of

${\mathbb{R}}^{r}$ containing zero in its interior and the output function

$h:{\mathbb{R}}^{n}\to {\mathbb{R}}^{m}$ has smooth components

${h}_{1},\dots ,{h}_{q}$.

Two states

${x}_{1},{x}_{2}\in {\mathbb{R}}^{n}$ are

indistinguishable for the system in Equation (

9) if, for every admissible input

$u\in \Omega $, the solutions of Equation (

9) satisfying the initial conditions

$x\left(0\right)={x}_{1}$ and

$x\left(0\right)={x}_{2}$ produce identical output-time histories. In other words,

${x}_{1},{x}_{2}\in {\mathbb{R}}^{n}$ are indistinguishable for the system in Equation (

9), if and only if

$h\left({\Phi}_{u}\left(t,{x}_{1}\right)\right)=h\left({\Phi}_{u}\left(t,{x}_{2}\right)\right)$ for every

$t\ge 0$ and input

$u$, where

${\Phi}_{u}(t,{x}_{0})$ denotes the solution of the system in Equation (

9) at time

t for the initial condition

${x}_{0}$ and the input

$u$. Given

${x}_{0}\in {\mathbb{R}}^{n}$, let us denote

$\mathcal{I}\left({x}_{0}\right)\subseteq {\mathbb{R}}^{n}$ as the set of all points that are indistinguishable from

${x}_{0}$ with respect to the system in Equation (

9).

The following definitions from [

45] are used. The system in Equation (

9) is

observable at ${x}_{0}\in {\mathbb{R}}^{n}$ if

$\mathcal{I}\left({x}_{0}\right)=\left\{{x}_{0}\right\}$, and it is

observable if

$\mathcal{I}\left({x}_{0}\right)=\left\{{x}_{0}\right\}$ for every

${x}_{0}$. The system in Equation (

9) is

weakly observable at ${x}_{0}\in {\mathbb{R}}^{n}$ if

${x}_{0}$ is an isolated point of

$\mathcal{I}\left({x}_{0}\right)$. The system in Equation (

9) is

weakly observable if it is weakly observable at every

${x}_{0}\in {\mathbb{R}}^{n}$. Clearly, observability implies weak observability.

The following assumptions are made:

**Assumption** **1.** Let us assume that the plant operates in the region **Assumption** **2.** The input flow${u}_{1}\in \mathbb{R}$is bounded (above and below), i.e.,$0\le {u}_{1}\le {u}_{\mathrm{max}}$and enters into the plant through Tank${T}_{1}$, where${u}_{\mathrm{max}}$is the maximum input flow.

The implications of Assumption 2 are the following. The maximum input flow

${u}_{\mathrm{max}}$ ensures no water overflow from the tanks, which is true since the plant was designed to avoid liquid overtopping the tank’s physical limit [

46,

47]. Additionally, water always flows from Tank

${T}_{1}$ to Tank

${T}_{2}$ and finally to Tank

${T}_{3}$. Then, it is assumed that there are no disturbances, i.e., the only water input into the system is located at the first tank. In addition, it ensures that the level in each tank is bounded, that is

${x}_{i}<{L}_{{i}_{\mathrm{max}}}$,

$i\in \{1,2,3\}$, where

${L}_{{i}_{\mathrm{max}}}$ is the maximum level in the

ith tank.

Given

${x}_{0}\in \chi $, let

${\mathcal{I}}_{0}\left({x}_{0}\right)$ denote the set of indistinguishable states from the initial condition

${x}_{0}$ for the unactuated system in Equation (

9). Our next result characterizes this set.

**Proposition** **1.** For the unactuated system in Equation (9),

${\mathcal{I}}_{0}\left({x}_{0}\right)=\left\{{x}_{0}\right\}$for every${x}_{0}\in \chi $.

**Proof.** First, observe that, in this case,

$u\equiv 0$. Consider

${x}_{0}=\left({x}_{10},{x}_{20},{x}_{30}\right)\ne 0\in \chi $ and let

${\overline{x}}_{0}:=\left({\overline{x}}_{10},{\overline{x}}_{20},{\overline{x}}_{30}\right)\ne {x}_{0}$ be such that

${\overline{x}}_{0}\in {\mathcal{I}}_{0}\left({x}_{0}\right)$. Then,

$h\left({\Phi}_{u}(t,{\overline{x}}_{0})\right)=h\left({\Phi}_{u}(t,{x}_{0})\right)$ for all

$t\in [0,{t}_{f})$, which implies that

${\overline{x}}_{30}={x}_{30}$. Now,

$h\left({\Phi}_{u}(t,{\overline{x}}_{0})\right)=h\left({\Phi}_{u}(t,{x}_{0})\right)$ for all

$t\in [0,{t}_{f})$ also implies that

${L}_{f}^{j}h\left({\overline{x}}_{0}\right)={L}_{f}^{j}h\left({x}_{0}\right),\phantom{\rule{0.166667em}{0ex}}\forall \phantom{\rule{0.166667em}{0ex}}j>0$, where

${L}_{f}h$ is the Lie-derivative of the function

h along the vector field

$f$. Recall that

${L}_{f}h\left(x\right)=\nabla h{\left(x\right)}^{\mathrm{T}}f\left(x\right)$, where ∇ is the gradient operator. Using this, we have

Hence,

${L}_{f}h\left({\overline{x}}_{0}\right)={L}_{f}h\left({x}_{0}\right)$ yields

Since ${A}_{3}>0$, the last equation implies that ${k}_{2}{\overline{x}}_{20}^{{n}_{2}}-{k}_{3}{\overline{x}}_{30}^{{n}_{3}}={k}_{2}{x}_{20}^{{n}_{2}}-{k}_{3}{x}_{30}^{{n}_{3}}$, and substituting ${\overline{x}}_{30}={x}_{30}$ immediately implies that ${\overline{x}}_{20}={x}_{20}$.

Next,

${L}_{f}^{2}h\left({\overline{x}}_{0}\right)={L}_{f}{h}^{2}\left({x}_{0}\right)$ yields

Since

${\overline{x}}_{20}={x}_{20}$ and

${\overline{x}}_{30}={x}_{30}$, the last equation becomes

Simplifying yields ${x}_{20}^{{n}_{2}-1}\sqrt{{\overline{x}}_{10}-{x}_{20}}={x}_{20}^{{n}_{2}-1}\sqrt{{x}_{10}-{x}_{20}}$. This implies that $\sqrt{{\overline{x}}_{10}-{\overline{x}}_{20}}=\sqrt{{x}_{10}-{x}_{20}}$, and hence ${\overline{x}}_{10}={x}_{10}$. Thus, it has been shown that ${\overline{x}}_{0}\in {\mathcal{I}}_{0}\left({x}_{0}\right)$ implies that ${\overline{x}}_{0}={x}_{0}$. In other words, ${\mathcal{I}}_{0}\left({x}_{0}\right)\subseteq \left\{{x}_{0}\right\}$. This completes the proof. □

Proposition 1 implies that the unactuated system in Equation (

9) is observable in the Herman–Krener sense. Given

${x}_{0}\in \chi $, let

${\mathcal{I}}_{1}\left({x}_{0}\right)$ denote the set of indistinguishable states from the initial condition

${x}_{0}$ for the actuated system in Equation (

9). Clearly,

${\mathcal{I}}_{1}\left({x}_{0}\right)\subseteq {\mathcal{I}}_{0}\left({x}_{0}\right)=\left\{{x}_{0}\right\}$. Consequently,

${\mathcal{I}}_{1}\left({x}_{0}\right)=\left\{{x}_{0}\right\}$, and hence the actuated system in Equation (

9) is also observable in the sense of Herman–Krener. Thus, it has been shown that the three-tank system with the knowledge of the input and the water level in Tank

${T}_{3}$ is observable in the sense of Herman–Krener. A high-gain observer is proposed in the following section.

## 4. Observer Design

Consider the nonlinear system of the form

where

$x\in \mathcal{X}\subset {\mathbb{R}}^{n}$ denotes the state vector,

$u:[0,T]\to \mathcal{U}\subset {\mathbb{R}}^{r}$ is the input vector,

$y\in \mathcal{Y}\subset {\mathbb{R}}^{m}$ is the output vector,

and

$\phi :\mathcal{X}\times \mathcal{U}\to {\mathbb{R}}^{n}$ is of the form

which is a globally Lipschitz nonlinear function that contains the nonlinearities of the system.

Consider

$\theta >0$ and let

$\mathbf{k}\in {\mathbb{R}}^{n}$ be such that the matrix

$A-kC$ is Hurwitz. Referring to Besançon [

50], for the system in Equation (

10), the observer is given by

where

${\Delta}_{\theta}\stackrel{\mathrm{def}}{=}\mathrm{diag}(\theta ,\dots ,{\theta}^{n})\in {\mathbb{R}}^{n\times n}$. This form of observer is called

high-gain observer (HGO), and it has good robust estimation properties and disturbance rejection capabilities [

51]. The idea is to use a high-gain constant in order to generate a fast response in the observer and reduce the effect of the nonlinear error. Nevertheless, due to the high gain, the observer is very sensitive to noise and the transient response, when the estimation is far from the true value, can cause peaks in the prediction. However, this drawback can be solved by filtering the output signal or introducing a saturation function in the feedback control law [

52,

53], making them a good solution for state estimation.

To obtain an observer of the form of Equation (

11), the system in Equation (

5) must be transformed into its observability canonical form. According to Besançon [

54], any control affine system satisfying the observability rank condition can be turned into the form Equation (

10) using a diffeomorphism

$z:{\mathbb{R}}^{n}\to {\mathbb{R}}^{n}$ given by

where

${z}_{k}\left(x\right)={L}_{f}^{k-1}h\left(x\right),\phantom{\rule{0.166667em}{0ex}}\phantom{\rule{0.166667em}{0ex}}k=1,\dots ,n$, with

${L}_{f}^{0}h\stackrel{\mathrm{def}}{=}h$.

Thus, the control affine system is related to its observability canonical form. To design an observer for the original plant and to avoid the inverse transformation of the observer obtained for the canonical form, it is recalled the definition of system equivalence used in [

50].

**Definition** **1.** (System equivalence).For each$i\in \{1,2\}$,

consider the systemsdefined on${\mathbb{R}}^{{n}_{i}}$with input${u}_{i}\in {\mathbb{R}}^{{m}_{i}}$,

output${y}_{i}\in {\mathbb{R}}^{p}$and${f}_{i}$’s

are smooth vector fields.

The two systems${\sum}_{1}$and${\sum}_{2}$are (state–space) equivalent

if there exists a diffeomorphism $z:{\mathbb{R}}^{{n}_{1}}\to {\mathbb{R}}^{{n}_{2}}$ such that $({x}_{2},{u}_{2})=(z\left({x}_{1}\right),\left({u}_{1}\right))$.

In other words, if

$({x}_{1}\left(t\right),u\left(t\right))$ is a trajectory of

${\sum}_{1}$, then

$(z\left({x}_{1}\left(t\right)\right),u\left(t\right))$ is a trajectory of

${\sum}_{2}$, that is,

Consider the systems

${\sum}_{1}$ and

${\sum}_{2}$ and suppose

is an observer for the system

${\mathsf{\Sigma}}_{2}$. Then,

is an observer for the system

${\sum}_{1}$. Using the concept of system equivalence and by transforming the system into its observability canonical form, a HGO is proposed for the three-tank system.

**Proposition** **2.** Consider the three-tank system in Equation (5) and suppose that Assumption 1 holds. Define${\Delta}_{\theta}=\mathrm{diag}(\theta ,{\theta}^{2},{\theta}^{3})$with$\theta \in {\mathbb{R}}_{>0}$and let$k={[{k}_{1},{k}_{2},{k}_{3}]}^{\mathrm{T}}\in {\mathbb{R}}^{3}$be such that$A-k{c}^{\mathrm{T}}$is Hurwitz. Then is an asymptotic observer for the system in Equation (5), where **Proof.** To check the observability rank condition, the Jacobian matrix of

$\Phi \left(x\right)$ must be full rank. The Jacobian is given by

where

Thus, ${J}_{\Phi}\left(x\right)$ is nonsingular if and only if ${\alpha}_{1}{\alpha}_{3}\ne 0$, which is true if and only if $0<{x}_{2}<{x}_{1}$. Under Assumption 1, it now follows that the Jacobian has full rank.

Applying the diffeomorphism

$z=\Phi \left(x\right)$ to the observer in Equation (

12) yields

where

${c}_{0}={e}_{1}$ and

${y}_{2}={c}_{0}^{\mathrm{T}}z$. According to Besançon [

54],

where

$\phi (\widehat{z},{u}_{1})={[0,0,\xi (\widehat{z},{u}_{1})]}^{\mathrm{T}}$ is Lipschitz with respect to

$\widehat{z}$, that is, there exists a

${L}_{\xi}>0$ such that

$|\xi ({\widehat{z}}_{1},{u}_{1})-\xi ({\widehat{z}}_{2},{u}_{1})|\le {L}_{\xi}\parallel {\widehat{z}}_{1}-{\widehat{z}}_{2}\parallel $ for all

${\widehat{z}}_{1},{\widehat{z}}_{2}$, and

Using Equation (

14) in Equation (

13) yields

Next, define

$\u03f5\stackrel{\mathrm{def}}{=}{\Delta}_{\theta}^{-1}(\widehat{z}-z)$. Then, the error dynamics is given by

where

$\tilde{\phi}(z,\widehat{z},{u}_{1})\stackrel{\mathrm{def}}{=}\phi (\widehat{z},{u}_{1})-\phi (z,{u}_{1})$. Inspired by the work of Hann et al. [

55], the following Lyapunov function is defined

where

$P={P}^{\mathrm{T}}\succ 0$ is such that

with

${I}_{n}$ being the identity matrix of size

$n$. This quadratic form was chosen in order to be positive definite and radially unbounded. Then,

Using Equation (

15) in Equation (

17) yields

while substituting Equation (

16) in the above yields

where

$\parallel \phantom{\rule{0.166667em}{0ex}}\xb7\phantom{\rule{0.166667em}{0ex}}\parallel $ is the Euclidean norm in

${\mathbb{R}}^{n}$. Since

$\phi (z,{u}_{1})$ is Lipschitz with respect to

$z$, it follows that

and hence

By selecting $\theta >2{L}_{\xi}\parallel P\parallel $, it follows that the $\dot{V}<0$. This completes the proof. □

## 5. Simulation Results

The first validation stage of the HGO was performed with simulations for full-state estimation in system. Such simulations were carried out using MATLAB

^{®}, which is a high-performance language developed by MathWorks

^{®}. To get similar behavior to the real plant, a sample period of

$0.2$ $\mathrm{s}$ was selected. Different nonlinearities were tested by selecting different kind of weirs that are available for the configuration of the plant: linear, v-notch, rectangular and circular (see

Figure 4).

Constant parameters were obtained measuring tanks’ areas and performing an open-loop test to get the coefficient and the exponential of Equation (

4) for each weir (

Table 1 and

Table 2). The input flow was set to a constant value of

${\overline{q}}_{\mathrm{in}}$, and levels were measured for each steady-state condition. Then, the weirs’ parameters were computed using the MATLAB

^{®} fitting toolbox,

Figure 5. For the simulation, sensor noise was implemented through a Gaussian distribution with

$0.5$ cm standard deviation. Additionally, a deviation of 5% in all the parameters of the system was taken into account.

Step inputs of 25% of the total flow capacity were simulated every 50s approximately. The gain $k={\left[0.8,0.17,0.01\right]}^{\mathrm{T}}$ was chosen such that ${A}_{0}-k{c}_{0}^{\mathrm{T}}$ is Hurwitz and $\theta =2$ as the high-gain observer parameter. Two different sets of weirs were used at the outputs of Tanks ${T}_{2}$ and ${T}_{3}$. The first set comprised a rectangular weir in the upper tank and a linear in the lower, and the second set comprised a v-notch weir in the upper tank and a circular in the lower.

Figure 6 shows the estimation of the level in each tank for the first set of weirs.

Figure 7 shows the estimation of the level in each tank for the second set of weirs. The same parameters were used in both simulations, but the observer’s parameters changed according to the exponential and coefficient of each weir. The observer converges slowly to the desired value, since poles were placed near to the imaginary axis. In both simulations, level estimations are affected by noise, as expected for a HGO.

## 6. Experimental Results

The second stage of validation of the HGO was performed through full-state estimation in the real process. The experimental set-up is shown in

Figure 8. This three-tank system has different control technologies: PLC, industrial controller and PC with LabVIEW

^{®}. In this case, the PLC controller was used as the DAQ system, and is connected through Ethernet to a LabVIEW

^{®} interface [

48], in which the compensator (controller+observer) was implemented.

Since the real plant is a complete experimental station, all variables were measured with real sensors, as indicated in

Figure 1; hence, the state estimation can be compared to real measurements of the levels in all the tanks. The sample time for the PLC and LabVIEW

^{®} program was set to

$0.2$ $\mathrm{s}$. As in simulations, step inputs of 25% of the total flow capacity were manually performed every 50

$\mathrm{s}$ approximately. The gain

$k\in {\mathbb{R}}^{3}$ was again chosen such that

${A}_{0}-k{c}_{0}^{\mathrm{T}}$ is Hurwitz and

$\theta =2$ as the high-gain observer parameter. Two different sets of weirs were used at the outputs of Tanks

${T}_{2}$ and

${T}_{3}$. The first set comprised a rectangular weir in the upper tank and a linear in the lower, and the second set comprised a v-notch weir in the upper tank and a circular in the lower one.

#### 6.1. High-Gain Observer Performance

Figure 9 and

Figure 10 show the estimation of the level in each tank for the first and second set of weirs, respectively. As can be noticed, the observer converges to the measurements. In both experiments, level estimations are affected by noise, but the level estimation for Tank

${T}_{3}$, considered as the output (controlled variable) behaves very similar to the real measurement. Noise in the real process is mainly caused by the configuration of the system, in which several waves are produced by the input flow (see

Figure 8). Two more experiments were conducted using an HGO with higher gain,

$k={\left[1.2,0.5,0.1\right]}^{\mathrm{T}}$.

Figure 11 and

Figure 12 show how the state estimation is affected in a more noticeable way.

After $t=200\mathrm{s}$, the system enters into an unobservable zone of the state space, and the estimation provided by the HGO diverges. This happens because the level in Tank ${T}_{2}$ goes below the minimum height of the weir, and, therefore, there is not flow from Tank ${T}_{2}$ to Tank ${T}_{3}$. A faster observer response can be achieved by increasing the gain $k$, which can result in a noisy estimation of the state, but it can still perform well when used in a complete compensator that includes the state feedback.

#### 6.2. Robustness Analysis

To test the robustness of the observer, two different experiments were carried out. In the first experiment, a variation of 30% of all parameters was made (tanks areas and weir constants). In this scenario, the HGO was compared to the well-known Luenberger observer [

56] and the Extended Kalman Filter (EKF) [

57].

Table 3 shows the mean squared error for the three observers; as can be noticed, the HGO obtained the best performance in the real process for the complete range of the tank levels despite the 30% variation in the model parameters.

Figure 13,

Figure 14 and

Figure 15 show the estimation for all levels with each observer. The HGO shows better performance and robustness than the other two observers. For instance, it can be seen how, for the low-level section, the estimation provided by the HGO converges in less than 2 s while Luenberger and EKF estimations are deviated from the measurement and converge after more than 20 s. It is important to point out that asymptotic estimation has been proved for the HGO, which is not the case for the EKF.

In the second experiment, an unmeasured temporary input flow went into the first and second tanks.

Figure 16 and

Figure 17 show the estimation of the level in each tank for a temporary input flow to the first and second tank, respectively. As was expected, the output of the system changed (level in Tank 3), and therefore the estimation should change. Recall that the level of tank

i depends on the inflow of the previous tank, which depends on the level of such tank. Therefore, it can been seen in

Figure 16 that the estimated level in Tank 2 is similar to the actual value, but higher for Tank 1. Now, when the perturbation was introduced in Tank 1, as was expected, the estimation converges to the real values of all levels (see

Figure 17).