# Multiphase-flow simulations

The numerical simulation of flows with interfaces is a vast and complex topic, with applications in domains as varied as environment, geophysics, engineering, and fundamental physics.

Indeed, phenomena considered often happen on scales of space and time where experimental visualizations are difficult or impossible. In such cases, numerical simulation may be a useful tool to validate the intuition of the physicist, the engineer, or the mathematician.

In our case, gas injections in the fracture/cave configuration has not been developped yet. Therefore, the simulations carried out in the BEI will help our industrial partner  to anticipate and to optimize futur gas injections in the reservoir.

Different numerical techniques exit to simulate three-phase flows. If most of them only allow low Reynolds or Weber numbers, the continuous improvement of computational power extends the range of affordable problems.

In the first part of the project, an analyze of different simulation methods based on Navier-Stokes equations is conducted. Understanding problems and limitations of each methods will allow us to choose the most appropriate method to our case and to be aware of its limitations.

Moreover, a comparative study of Jadim and Fluent, two CFD software, is conducted to know how they handle three-phase flow simulations.

# Methods for direct numerical simulation of multiphase flow

If numerical simulations of three-phase flow are still a challenge in the CFD field and the purpose of lots of research groups, differents methods already exist.

Three main classes of methods for direct numerical simulations of multiphase flow exists:

The Multiphase particle-in-cell method (mixed Eulerian-Lagrangian method)

lt is an hybrid method where individual particles in a Lagrangian frame are tracked in continuous phase space. This method solves Navier-Stokes equations (Eulerian) for the continuous phase and Lagrangian equation of motion for individual particles.
Interactions between particles are calculated on the Eulerian grid and convection algorithms are highly accurate (Lagrangian advection is non-diffusive)

However, this method has limitations:
• All particles are assumed to be spherical. If corrections for non-spherical particles can be included in particle drag model, true interactions may therefore not be well represented.
• The size of particles must be small compared to the Eulerian grid  for accurate interpolation.​
• The major problem of this method is that only a low volume fraction of the dispersed second phase is acceptable. This last consideration makes the model inappropriate for the modeling of liquid-liquid mixtures, fluidized beds, or any application where the volume fraction of the second phase is not negligible.

Moving grids methods (Lagragian methods)​

The interface is a boundary between two subdomains of the grid. ​The method is mainly used to follow the motion of a rising bubble, small amplitude waves or weakly deformed bubble. However, when the  points move simply in a Lagrangian way, the grid may deform considerably and in case of large deformations of the interface or topology changes, the grid has to be remeshed. This complex method is only sucessful and very accurate for small interface deformation, which is not the case here.

Fixed-grid methods (Eulerian methods)

These methods correspond to a predifined grid that does not move with the interface.
• The marker method
Tracers or marker particles moved in a Lagrangian way are used to locate the interface on a fixed grid.

The advantage of the method is that it allows the capture of details of interface motion on scales much smaller than the grid spacing  (Sub grid resolution) and a high degree of accuracy that may be achieved by representing the interface through high-order interpolation polynomials.

However, if surface markers are more accurate than volume markers, they cannot handle more than two phases and topology changes are difficult. Control the marker distribution is also problematic and it needs an important CPU time.

• The Level Set method
It is a numerical technique for tracking interfaces that can perform numerical computations on a fixed  grid without having to parameterize the interface. A new dimension is introduced to the case and defines the interface as a level set of function φ( x, y) which represents the minimum distance from each point to the interface.
This method tracks the evolution of φ and determines the zero level set thanks to the equation:

$\frac{\partial φ}{\partial t}+U. \Delta φ=0$

This method is a great tool for modeling time-varying objects and works in any dimension. Moreover, no special treatment is needed for topological changes ans the interface geometry reconstruction is simple.
However, this method has not yet produced wide range of results, especially in 3D compare to other methods and does not guarantee conservation of the volume.
• The VOF method (Volume of Fluid)
It is a surface-tracking technique applied to a fixed Eulerian mesh where Navier Stokes equations which describe the motion of the flow have to be solved separately.
The method is based on the solution of a transport equation for variable ‘C’ (often also referred as indicator or colour function) for the liquid phase.

$C_{ij}$ represents the portion of the area of the cell (i, j) filled with liquid phase  and the phase function χ :

where  0 < C < 1 in cells cut by the interface S and C = 0 or 1 away from it.

The VOF method doesn't explicitly track the interface, it reconstructs the interface based on calculation of the volume fraction of fluid . The Color Function also cannot be solved easily. Several methods for the reconstruction of the interface exist, the most popular being PLIC (Piecewise Linear Interface Calculate). In a 3D space, the interface can be described by

$$\vec{n_x}+\vec{n_y}+\vec{n_z}=\alpha$$

where n is the normal vector to the interface and $\alpha$ is a constant line.

$\alpha$  can be solved by root-finding method or analytical formulas $\alpha=\alpha(C)$ and  $\vec{n}$ has several approaches such as  Parker and Yong's method, Least-squarts method etc.

• Advantages of the VOF method

The VOF's use, reliability and effectiveness are widespread: the method has been known for several decades, has gone through a continuous process of improvement and is used by many commercially available software programs.

Moreover, the volume conservation is good and no special provision is necessary to perform reconnection or breakup of the interface  as the change of topology is implicit in the algorithm. The VOF method is easy to extend to 3D of space and simple to implement.

Applications of the VOF model include stratified flows or the steady or transient tracking of any liquid-gas interface, which correspond to our case.

• Limitations of the VOF method

The simplification of nonlinear terms and the fact that high order terms are omitted after discretization can lead to less accurate solutions in some cases. Moreover, C<0 or C>1 is possible, which is not relevant with the physic. Another limit of the method is the transitional region between the phases which has to be at least equal to the grid distance.

If the interface geometry reconstruction is challenging, normal interface movements are not straightforwards. Last but not the least, the VOF method involves massive calculations and data burden, which leads to important CPU times.

# CFD Softwares: Fluent versus Jadim

Two different software are used to simulate the gas injection: FLUENT and Jadim.

Fluent is a commercial CFD software which provide a wide range of multiphase flow models to model the behavior and interactions of a large number of phases. The user can not have access to the code; therefore, there are no possibilities to check equation implementation or to had function in the code.This software has been largely used in the industry for decades.

JADIM LES is a research code developped by Jacques Magnaudet and Dominique Legendre's team in the Interface group at IMFT(Institut de Mécanique des Fluides de Toulouse). The code permits to describe in an accurate way such physical mecanisms present
in multi-phase fows. It is especially  able to simulate two and three-phases flow with the VOF method without reconstruction of the interface. Jadim resolves Navier-Stokes equations in 3D for incompressible fluids and instationnarities.
A second order space and time finite volum method with a structured mesh is used (third order Runge-Kutta scheme for non-linear term resolution coupled with a Crank-Nicolson scheme for the semi-implicit part). This code can only be used with structured mesh.

The table below compare  the main caracteristics of Jadim and Fluent:

It is important to be aware about the difference that exits between the two codes in order to understand simulations issues such as lack of convergence or simulations results such as differences in flow features.

http://cdlab2.fluid.tuwien.ac.at/LEHRE/TURB/Fluent.Inc/v140/flu_ug.pdf

https://www.imft.fr/

# Conclusion

The bibliography carried out leads us to conclusions developped in the table below:

Simulations will be carried out with the VOF method on both Jadim and Fluent codes and results will be compare. However, as the level set method is not available for three-phase flow on Jadim, this method will only be tested with Fluent.