Mobile Monitoring and Control Infrastructure Water Rig
July, 2002
Don't Panic!
This page briefly discusses the theory and concepts behind "twin tank
control". It does not present a single equation, let alone any calculus,
and does not end in "recommended exercises" or such. Anyway, you did
come here, so you must have some intrest.
The End
What you want to do is control the water level in the second tank.
The Means
The way you can control the water level in the second tank is by
controlling the water level in the first tank. This works because the
first tank is linked to the second. The way you control the water level
in the first tank is by turning the four valves on and off, via the
SCADA system.
The Control Valves
The four control valves are in series (in line) with flow restriction
valves, which have been set up such that each has a flow rate twice that
of the valve on it's right. This means that, if the rightmost valve has
a flow rate of x, then the centre - right valve's flow rate is 2x, then
4x and the leftmost valve's flow rate is 8x. Nerds amongst us will note
that this is equivalent to four bit binary, which means that by using
the sixteen different combinations of valves turned on or off, sixteen
different flow rates (where no flow is counted as a flow rate) can be
achieved. The table below illustrates this.....
Valve 1 (flow rate 8)
|
Valve 2 (flow rate 4)
|
Valve 3 (flow rate 2)
|
Valve 4 (flow rate 1)
|
Total Flow Rate
|
Left
|
Centre Left
|
Centre Right
|
Right
|
(no particular units)
|
Off
|
Off
|
Off
|
Off
|
0
|
Off
|
Off
|
Off
|
On
|
1
|
Off
|
Off
|
On
|
Off
|
2
|
Off
|
Off
|
On
|
On
|
3
|
Off
|
On
|
Off
|
Off
|
4
|
Off
|
On
|
Off
|
On
|
5
|
Off
|
On
|
On
|
Off
|
6
|
Off
|
On
|
On
|
On
|
7
|
On
|
Off
|
Off
|
Off
|
8
|
On
|
Off
|
Off
|
On
|
9
|
On
|
Off
|
On
|
Off
|
10
|
On
|
Off
|
On
|
On
|
11
|
On
|
On
|
Off
|
Off
|
12
|
On
|
On
|
Off
|
On
|
13
|
On
|
On
|
On
|
Off
|
14
|
On
|
On
|
On
|
On
|
15 |
Drains
Both of the tanks have drains in the bottom, which also affects the
water level in the tanks. These drains also have restriction valves
attatched to them, so that they can (manually, not by SCADA) be adjusted
to set the drain flow rate.
Pressures
To make life difficult, the amount of water that flows through a hole
(pipe) is related to (among other things) the height of the water above
that hole. The more water there is above the hole, the more pressure (or
"head") there is on the water at the hole, which means the water flows
out the hole faster. For this model, the consequences are that the more
you fill a tank, the faster it drains. In the case of the first tank,
this means that water will also flow into the second tank faster,
provided that the water level in the second tank is lower than that in
the first tank (if that were not the case, the water would flow from the
second tank back into the first tank).
Delays
The final phenomenon that plays a significant part for the demonstration
system is delays. There are several delays built into the system:
- The pipe funnel. The second horizontal tube is a funnel that
channels the water from the four control valves into the top of the
first tank. Because the water takes time to flow through the funnel
before it gets to the top tank, this is a delay - there is a "non-zero"
amount of time between you turning a valve on or off and the
corresponding change in flow into the first tank.
- Tank 1 to tank 2. Water takes time to flow between these, thus
changing the water level in tank 1 will not immediately affect the water
level in tank 2. It can be argued that this is not the case if the
joining pipe is full of water when the change happens.....
The overall result is that doing something to tank 1 will only have
an effect on tank 2 after some time. This leads to the main point for
this page.....
The Point
If you put a whole lot of water into tank 1, tank 2's water level will
rise. When you stop putting water into tank 1, tank 2's water level will
continue to rise for some time. The point, therefor, is that if you
want to get the water level in tank 2 to to some fixed level above it's
current level, you will have to put more water into tank one, but will
have to stop doing so before tank 2's level reaches it's target.
Conversely, to reduce the water level in tank 2, the flow into tank 1
will have to be reduced until some time before tank 2's water level
reaches it's target. Don't forget, however, to keep putting some water
in, or it will all drain out. Overall, this behaviour means that the
tanks system is a second order system with delay. If you want to know
what that means, find a book on control theory.