Water Tank Level Control - Nonlinear Control Law

This example simulates two water tanks connected with output regulation using

QFIRE Studio

.

Introduction

Two water tanks connected can be described by the equation:

x˙1=x1+u+θx˙2=x2+x1\begin{align} \dot{x}_1&=-\sqrt{x_1}+u+\theta\\ \dot{x}_2&=-\sqrt{x_2}+\sqrt{x_1} \end{align}

Where,

  • x1x_1
    is the water level in tank 1.
  • x2x_2
    is the water level in tank 2.
  • uu
    is the control action of the water flow.
  • θ\theta
    is the pipe leakage.
Simulation

The following control law is able to stabilize the water level in these tanks:

u=r+b(rx1)+ax1+r(rx2)u=\sqrt{r}+b(r-x_1)+\frac{a}{\sqrt{x_1}+\sqrt{r}}(r-x_2)

Using the parameters a=1 and b=0.5, the closed-loop system can be modeled as in Figure 1.

Figure 1 - Controller and two tanks system

The controller and the system are contained in the Subsystems shown in Figure 1. The diagrams of each subsystem are shown in Figure 2 and Figure 3.

Figure 2 - Water tanks connected system

Figure 3 - Controller diagram

Using 100s simulation, the time response of the tanks are described by Figure 4 and Figure 5.

Figure 4 - Level of Tank 1

Figure 5 - Level of Tank 2

Bibliographic References

[1] Ola Härkegårds,  

BACKSTEPPING AND CONTROL ALLOCATION WITH APPLICATIONS TO FLIGHT CONTROL

,  2003.

About MWF

MWF is a traditional Brazilian company that provides a wide range of electronic and mechatronic products for industry sectors such as automotive, agricultural machinery and aerospace.

Contact Us

Rua Doutor Siqueira, 139 / Sala 804 Campos dos Goytacazes - RJ, Brasil

contact@mwf-technologies.com

© 2018-2026 MWF. All rights reserved.