Multi-component fluid flow - lattice Boltzmann method
N-components fluid
Introduction
Having implemented the binary RK model, it is straightforward to implement the model to N fluids by replacing any reference to red and blue by red, blue, pink, yellow. This would be very fastidious and the limit of the total named colours would be reach fairly quickly, without mentioning that the computer needs (memory and time) would rise linearly with the number of fluids. Going from two to N fluids is therefore a more computational (or coding) issue than algorithmic. A way to avoid having to deal with enormous computational demands is to choose to define the fluids only where they exist. This later statement appears to be trivial but is actually not at all. However, the local property of the RK model eases a lot the coding and algorithm by defining all fluids in the whole space at any time (via the trick of a null density of probability).
Associating labels to each density of momentum (defining the colour of this fluid) reduces considerably the requirements that now depend only upon the number of fluid occupying a node. The needs are not anymore linear with the number of fluids, which enables to model any number of fluid (literally) maintaining reasonable requirements.
Non-coalescence
Controlling coalescence is crucial in the attempt to handle more than two different fluids in this project. We use a generalised formula from the original work from Rothman-Keller to find the interface between any couple of fluid and set the algorithm to segregate them fully (it should be noted at this point that no significant diffusion has been observed and if any, it falls in the discretisation error of the computer and hence reaches the order of the binary Rothman-Keller model).
The following simulation shows five different fluids (red, orange, green, yellow and blue) each of which cannot only coalesce with itself. Note that in this simulation, there is an equal surface tension between any of the possible couple.
Liquid-liquid wetting
We saw in part IIIa. and IIIb. how to apply an interfacial surface tension in the RK model. In the case of more than two fluids, the procedure is follows the same steps, modifying however slightly the definition of the colour field. For example, we need to be able to resolve the following situation
Therefore, any couple of fluid has to have a given surface tension, which can be represented by the following 'surface tension matrix'
This matrix is obviously symmetric and the diagonal is never addressed. It defines the targeted surface tension for any couple of fluid. For convenient reasons, let's now consider the couple {A,B}. On any node that contain fluid A and fluid B, we perturb its densities again accordingly to the rule
A good illustration of this property is the behaviour that would have two blood cells when pushed towards each other. In the following simulation, one of the drop is pushed upwards while the other is pushed downwards. The surface tensions are set as such that the affinity between any of theses two drop and the surrounding fluid is much bigger than their affinity for each other. This enables bubbles to go past each other without sticking. Note that lubrication forces are emerging from the technique (by the explicitly resolved layer of surrounding fluid between the two drops) and as a result, do not have to be forced into the simulation as most CFD solvers do.
Parameters degree of freedom
Viscosity, interfacial surface tension, wall wetting and 'gravity' can be set dynamically in the programme. That is to say really complicated situation could be handled where the simulation space is not only a square with identical walls. This is thanks to its local perturbation that modifying any parameter is easy and straight forward, offering to this method a big advantage over other.
Simulations
Below is a small video showing 84 droplets slipping one with each other and with the wall. The viscosity of the droplets is the same for all of them and is the same as the surrounding fluid. Immediate application would be sludge transport or biological flow. Note also that gravity is put on the system via a uniformly impressed bodyforce acting downwards which, under the Stokes conditions, is equivalent to a real difference of density. This video illustrates the wetting properties described above: the wetting between each 'cell' has to be controlled to ensure they flow, the wall-wetting ensures that the cells flows along the walls.
Note that the 'trace' observed at near the top wall are pure artefact of the low-quality animated gif format.
Rayleigh-Taylor instability with deformable droplets
Taking 261 different fluids, that cannot coalesce, that have much more affinity with the surrounding (white) fluid than with any of the other fluids (droplets) and being subjected to gravity (but the surrounding fluid) gives rise to what could be seen as the Rayleigh-Taylor instability in classic binary fluid dynamics (also known as density fingering). It should be noted also that the droplets have a strong repulsion with the walls, which prevent them from sticking to it.