# Analogies between physics and packet-switched networks

Suppose two entities in a communication networks (sender and receiver) are connected with a tube so that water can be pumped from the sender to the receiver. If we also assume that between sender and receiver there is a tank with some finite capacity and possibly a drop rate (the tank leaks under high flow conditions or similar) the systems becomes very similar, if not identical, to the leaky bucket model.

My question is this: if a communication system can be described with this model, is there anything from fluid dynamics or other areas of physics I can use to design an algorithm that adapts the rate of the flow (i.e., when the transmission rate is to high, the tank gets congested and drops packet). I am not a physicist, so I will list down the major assumptions:

1. feedback from receiver to sender exists and can be assumed error-free. Delay in feedback also exists, but it can be assumed constant, for simplicity.
2. the algorithm works with packets in discrete time and needs to be as simple as possible.
3. the receiver has a buffer that can store up to N packets (N is fixed).
4. the sender sends packets at a fixed rate. However, the rate can be changed, based on the feedback from the receiver, or the receiver may impose to reduce the transmission rate.
5. the preferred mode is that the receiver decides whether to change transmission rate and, if so, inform the sender via feedback.
-
Do you actually want to design a model capable of doing these things, without any active control? –  Bernhard May 3 '12 at 19:10
that's the whole purpose of control theory, isn't it? –  Bob May 4 '12 at 21:28
Maybe we have different interpretations of active control. Do you allow pumps, sensors etc, or is there only a fluid and gravity? –  Bernhard May 5 '12 at 6:51

Not really from physics per se, but does the receiver (or sender) have access to the number of packets in the buffer at a time? If so, the interval between sends ($t$) could be set to a function of the number of buffered packets ($M$). The simplest would be a linear multiple of M, but you'd really want $\lim_{M\to N}{t}=\infty$; perhaps something of the form $t = \frac{k}{N-M}$.

-

It is possible to model a flow of packets through a network as an incompressible fluid or even an compressible one if you assume that certain parameters of the network can be changed over time.

In the end you might achieve a good mathematical description of pipes, buckets and leaks which can be used as an analogy for a packet network. You can add some kind of PID controller or similar algorithms to fill and empty the buckets, etc.

But this just creates a lot of complications to your original problem. There is just no easy algorithm that physics provides to solve congestion and packet drops. Depending on your simulation the water molecules would just speed up because of high pressure, expand or burst the pipe or experience friction and turbulent flow. It seems to me that the water & bucket model is a good analogy, so are pipes with water a sometimes acceptable analogy for electrical current but it only carries so far.

-