Volume-of-Fluid method using Piecewise Linear Interface Construction of the interface and lagrangien advection. More...
Functions | |
subroutine | mod_vof2d::vof2d (volume_fraction, vof_bc, time_step, velocity) |
Compute 2D VOF-PLIC. | |
subroutine | mod_vof2d_compute_normal::vof2d_compute_normal (volume_fraction, celli, cellj, normalx, normaly) |
Compute the interface normal in a given cell. | |
subroutine | mod_vof2d_compute_radius::vof2d_compute_radius (normalx, normaly, cx, cy, vof, vof_case, radius) |
Compute radius in reference configuration. | |
subroutine | mod_vof2d_compute_volume::vof2d_compute_volume (normalx, normaly, radius, cx, cy, vof_case, volume) |
Compute the volume of fluid in a given cell. | |
subroutine | mod_vof2d_conservative::vof2d_conservative (volume_fraction, vof_bc, time_step, velocity) |
Compute 2D VOF-PLIC. | |
subroutine | mod_vof2d_get_reference::vof2d_get_reference (normalx, normaly, cx, cy, vof, vof_case) |
Transform the normal and the cell into the reference configuration. | |
subroutine | mod_vof3d::vof3d (volume_fraction, vof_bc, time_step, velocity) |
Compute 3D VOF-PLIC. | |
subroutine | mod_vof3d_compute_normal::vof3d_compute_normal (volume_fraction, celli, cellj, cellk, normalx, normaly, normalz) |
Compute the interface normal in a given cell. | |
subroutine | mod_vof3d_compute_radius::vof3d_compute_radius (normalx, normaly, normalz, cx, cy, cz, vof, vof_case, radius) |
Compute radius in reference configuration. | |
subroutine | mod_vof3d_compute_volume::vof3d_compute_volume (normalx, normaly, normalz, radius, cx, cy, cz, radius_case, vof_case, volume) |
Compute the volume of fluid in a given cell. | |
subroutine | mod_vof3d_conservative::vof3d_conservative (volume_fraction, vof_bc, time_step, velocity) |
Compute 3D VOF-PLIC. | |
subroutine | mod_vof3d_get_reference::vof3d_get_reference (normalx, normaly, normalz, cx, cy, cz, vof, radius_case, vof_case) |
Transform the normal and the cell into the reference configuration. | |
subroutine | mod_vof3d_transform_radius::vof3d_transform_radius (normalx, normaly, normalz, cx, cy, cz, radius, radius_case) |
Transform the radius back to the normal configuration. | |
subroutine | mod_vof_apply_boundary_conditions::vof_apply_boundary_conditions (volume_fraction, vof_bc) |
Apply boundary conditions for 2D/3D VOF-PLIC. | |
subroutine, public | mod_vof_cfl::vof_cfl (volume_fraction, velocity, phase_advection_time_step, nb_time_step, time_step, nb_substeps) |
Compute time step that fulfill the CFL for 2D/3D VOF PLIC non fully conservative algorithm. | |
subroutine, public | mod_vof_cfl::conservative_vof_cfl (volume_fraction, velocity, phase_advection_time_step, nb_time_step, time_step, nb_substeps) |
Compute time step that fulfill the CFL for 2D/3D VOF PLIC fully conservative algorithm (Weymouth). | |
subroutine | mod_solve_vof_plic::solve_vof_plic (volume_fraction, boundary_condition, time_step_n, time_step_np1, velocity_nm1, velocity_n, velocity_np1, dt) |
VOF-PLIC time loop. | |
Two VOF-PLIC methods are proposed ([1] and [2]).
[1] G.D. Weymouth, Dick K.-P. Yue *, Conservative Volume-of-Fluid method for free-surface simulations on Cartesian-grids, Journal of Computational Physics 229 (2010) 2853–2865
[2] Jérôme Breil, Modélisation du remplissage en propergol de moteur à propulsion solide, tel-01478691, https://tel.archives-ouvertes.fr/tel-01478691
subroutine, public mod_vof_cfl::conservative_vof_cfl | ( | double precision, dimension(nx,ny,nz), intent(in) | volume_fraction, |
type(t_face_field), intent(in) | velocity, | ||
double precision, intent(in) | phase_advection_time_step, | ||
integer, intent(out) | nb_time_step, | ||
double precision, intent(out) | time_step, | ||
integer, intent(in) | nb_substeps ) |
This routine computes the number of secondary time steps required to make a single advection time step phase_advection_time_step that satisfy the CFL.
[in] | volume_fraction | volume fraction. |
[in] | velocity | velocity vector components. |
[in] | phase_advection_time_step | time step associated to the advection equation |
[out] | nb_time_step | number of secondary time steps. |
[out] | time_step | length of secondary time steps. |
[in] | nb_substeps | number of substeps |
subroutine mod_solve_vof_plic::solve_vof_plic | ( | double precision, dimension(:,:,:), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | boundary_condition, | ||
double precision, intent(in) | time_step_n, | ||
double precision, intent(in) | time_step_np1, | ||
type(t_face_field), intent(in) | velocity_nm1, | ||
type(t_face_field), intent(in) | velocity_n, | ||
type(t_face_field), intent(in) | velocity_np1, | ||
double precision, intent(in) | dt ) |
[in,out] | volume_fraction | volume fraction which values belong to [0,1]. |
[in] | boundary_condition | boundary conditions. |
[in] | time_step_n | \(\Delta t^{n} = t^{n} - t^{n-1}\) |
[in] | time_step_np1 | \(\Delta t^{n+1} = t^{n+1} - t^{n}\) |
[in] | velocity_nm1 | velocity at time \(t^{n-1}\) |
[in] | velocity_n | velocity at time \(t^{n}\) |
[in] | velocity_np1 | velocity at time \(t^{n+1}\) |
[in] | dt | the time step over which to integrate (might be different from time_step_np1 if needed) |
subroutine mod_vof2d::vof2d | ( | double precision, dimension(nx,ny,nz), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | vof_bc, | ||
double precision, intent(in) | time_step, | ||
type(t_face_field), intent(in) | velocity ) |
The phase advection is split into advection along axis directions.
Pseudo algorithm of VOF-PLIC:
!! For each axis direction !! For each cells near the interface: !! 1- Compute the normal. !! 2- Transform the normal into the reference configuration. !! 3- Compute the radius in the reference configuration. !! 4- Transform the radius back to the real configuration. !! 5- Advect the normal and the radius. !! 6- Compute the volume entering the current cell. !! End !! End !!
volume_fraction | volume fraction which values belong to [0,1]. | |
[in] | vof_bc | boundary conditions. |
[in] | time_step | time step. |
[in] | velocity | velocity field. |
subroutine mod_vof2d_compute_normal::vof2d_compute_normal | ( | double precision, dimension(nx,ny,nz), intent(in) | volume_fraction, |
integer, intent(in) | celli, | ||
integer, intent(in) | cellj, | ||
double precision, intent(out) | normalx, | ||
double precision, intent(out) | normaly ) |
Compute the interface normal in a given cell based on the gradient of the volume fraction.
[in] | volume_fraction | volume fraction of fluid. |
[in] | celli,cellj | coordinates of the cell. |
[out] | normalx,normaly | normal components. |
subroutine mod_vof2d_compute_radius::vof2d_compute_radius | ( | double precision, intent(in) | normalx, |
double precision, intent(in) | normaly, | ||
double precision, intent(in) | cx, | ||
double precision, intent(in) | cy, | ||
double precision, intent(in) | vof, | ||
integer, intent(in) | vof_case, | ||
double precision, intent(out) | radius ) |
Compute radius
using normal, cell dimension, volume fraction and VOF configuration.
[in] | normalx,normaly | normal components. |
[in] | cx,cy | cell dimensions. |
[in] | vof | volume fraction. |
[in] | vof_case | VOF initial configuration. |
[out] | radius | radius. |
subroutine mod_vof2d_compute_volume::vof2d_compute_volume | ( | double precision, intent(in) | normalx, |
double precision, intent(in) | normaly, | ||
double precision, intent(in) | radius, | ||
double precision, intent(in) | cx, | ||
double precision, intent(in) | cy, | ||
integer, intent(in) | vof_case, | ||
double precision, intent(out) | volume ) |
Compute the volume of fluid using normal direction, radius and cell dimension. The parameters must be in the real configuration.
[in] | normalx,normaly | normal components. |
[in] | radius | radius. |
[in] | cx,cy | cell dimensions. |
[in] | vof_case | VOF initial configuration. |
[out] | volume | volume of fluid (not the volume fraction!). |
subroutine mod_vof2d_conservative::vof2d_conservative | ( | double precision, dimension(nx,ny,nz), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | vof_bc, | ||
double precision, intent(in) | time_step, | ||
type(t_face_field), intent(in) | velocity ) |
The phase advection is split into advection along axis directions.
Pseudo algorithm of VOF-PLIC:
!! For each axis direction !! For each cells near the interface: !! 1- Compute the normal. !! 2- Transform the normal into the reference configuration. !! 3- Compute the radius in the reference configuration. !! 4- Transform the radius back to the real configuration. !! 5- Advect the normal and the radius. !! 6- Compute the volume entering the current cell. !! End !! End !!
volume_fraction | volume fraction which values belong to [0,1]. | |
[in] | vof_bc | boundary conditions. |
[in] | time_step | time step. |
[in] | velocity | velocity field. |
subroutine mod_vof2d_get_reference::vof2d_get_reference | ( | double precision, intent(inout) | normalx, |
double precision, intent(inout) | normaly, | ||
double precision, intent(inout) | cx, | ||
double precision, intent(inout) | cy, | ||
double precision, intent(inout) | vof, | ||
integer, intent(out) | vof_case ) |
The reference configuration corresponds to the case 0 < normalx*cx <= normaly*cy where cx and cy are the cells dimensions.
The way the transformation is done is encoded in the vof_case variable. The value depends on the normal direction. Possible values for vof_case are:
!! 5 !! _____ !! 2 / \ 1 !! / \ !! 6 ( ) 8 !! \ / !! 3 \_____/ 4 !! !! 7 !!
For instance (-0.707,0.707) belongs to the case 2.
For cases {3,6,7}, the dual volume is returned in vof
.
normalx,normaly | normal components. | |
cx,cy | cell dimension. | |
vof | volume fraction. | |
[out] | vof_case | VOF initial configuration. |
subroutine mod_vof3d::vof3d | ( | double precision, dimension(nx,ny,nz), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | vof_bc, | ||
double precision, intent(in) | time_step, | ||
type(t_face_field), intent(in) | velocity ) |
The phase advection is split into advection along axis directions.
Pseudo algorithm of VOF-PLIC:
!! For each axis direction !! For each cells near the interface: !! 1- Compute the normal. !! 2- Transform the normal into the reference configuration. !! 3- Compute the radius in the reference configuration. !! 4- Transform the radius back to the real configuration. !! 5- Advect the normal and the radius. !! 6- Compute the volume entering the current cell. !! End !! End !!
[in,out] | volume_fraction | volume fraction which values belong to [0,1]. |
[in] | vof_bc | boundary conditions. |
[in] | time_step | time step. |
[in] | velocity | velocity field. |
subroutine mod_vof3d_compute_normal::vof3d_compute_normal | ( | double precision, dimension(nx,ny,nz), intent(in) | volume_fraction, |
integer, intent(in) | celli, | ||
integer, intent(in) | cellj, | ||
integer, intent(in) | cellk, | ||
double precision, intent(out) | normalx, | ||
double precision, intent(out) | normaly, | ||
double precision, intent(out) | normalz ) |
Compute the interface normal in a given cell based on the gradient of the volume fraction.
[in] | volume_fraction | volume fraction of fluid. |
[in] | celli,cellj,cellk | coordinates of the cell. |
[out] | normalx,normaly,normalz | normal components. |
subroutine mod_vof3d_compute_radius::vof3d_compute_radius | ( | double precision, intent(in) | normalx, |
double precision, intent(in) | normaly, | ||
double precision, intent(in) | normalz, | ||
double precision, intent(in) | cx, | ||
double precision, intent(in) | cy, | ||
double precision, intent(in) | cz, | ||
double precision, intent(in) | vof, | ||
integer, intent(in) | vof_case, | ||
double precision, intent(out) | radius ) |
Compute radius
using normal, cell dimension, volume fraction and VOF configuration.
[in] | normalx,normaly,normalz | normal components. |
[in] | cx,cy,cz | cell dimensions. |
[in] | vof | volume fraction. |
[in] | vof_case | VOF initial configuration. |
[out] | radius | radius. |
subroutine mod_vof3d_compute_volume::vof3d_compute_volume | ( | double precision, intent(in) | normalx, |
double precision, intent(in) | normaly, | ||
double precision, intent(in) | normalz, | ||
double precision, intent(in) | radius, | ||
double precision, intent(in) | cx, | ||
double precision, intent(in) | cy, | ||
double precision, intent(in) | cz, | ||
integer, intent(out) | radius_case, | ||
integer, intent(out) | vof_case, | ||
double precision, intent(out) | volume ) |
Compute the volume of fluid using normal direction, radius and cell dimension. The parameters must be in the real configuration.
[in] | normalx,normaly,normalz | normal components. |
[in] | radius | radius. |
[in] | cx,cy,cz | cell dimensions. |
[out] | radius_case | radius initial configuration. |
[out] | vof_case | VOF initial configuration. |
[out] | volume | volume of fluid (not the volume fraction!). |
subroutine mod_vof3d_conservative::vof3d_conservative | ( | double precision, dimension(nx,ny,nz), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | vof_bc, | ||
double precision, intent(in) | time_step, | ||
type(t_face_field), intent(in) | velocity ) |
The phase advection is split into advection along axis directions.
Pseudo algorithm of VOF-PLIC:
!! For each axis direction !! For each cells near the interface: !! 1- Compute the normal. !! 2- Transform the normal into the reference configuration. !! 3- Compute the radius in the reference configuration. !! 4- Transform the radius back to the real configuration. !! 5- Advect the normal and the radius. !! 6- Compute the volume entering the current cell. !! End !! End !!
[in,out] | volume_fraction | volume fraction which values belong to [0,1]. |
[in] | vof_bc | boundary conditions. |
[in] | time_step | time step. |
[in] | velocity | velocity field. |
subroutine mod_vof3d_get_reference::vof3d_get_reference | ( | double precision, intent(inout) | normalx, |
double precision, intent(inout) | normaly, | ||
double precision, intent(inout) | normalz, | ||
double precision, intent(inout) | cx, | ||
double precision, intent(inout) | cy, | ||
double precision, intent(inout) | cz, | ||
double precision, intent(inout) | vof, | ||
integer, intent(out) | radius_case, | ||
integer, intent(out) | vof_case ) |
The reference configuration corresponds to the case 0 < normalx*cx < normaly*cy < normalz*cz and normalx*cx + normaly*cy <= normalz*cz where cx, cy and cz are the cells dimensions.
The way the transformation is done is encoded in the vof_case variable. The value depends on the normal direction.
normalx,normaly,normalz | normal components. | |
cx,cy,cz | cell dimension. | |
vof | volume fraction. | |
[out] | radius_case | radius initial configuration. |
[out] | vof_case | VOF initial configuration. |
subroutine mod_vof3d_transform_radius::vof3d_transform_radius | ( | double precision, intent(in) | normalx, |
double precision, intent(in) | normaly, | ||
double precision, intent(in) | normalz, | ||
double precision, intent(in) | cx, | ||
double precision, intent(in) | cy, | ||
double precision, intent(in) | cz, | ||
double precision, intent(inout) | radius, | ||
integer, intent(in) | radius_case ) |
[in] | normalx,normaly,normalz | normal components. |
[in] | cx,cy,cz | cell dimension. |
[in,out] | radius | volume fraction. |
[in] | radius_case | radius initial configuration. |
subroutine mod_vof_apply_boundary_conditions::vof_apply_boundary_conditions | ( | double precision, dimension(:,:,:), intent(inout) | volume_fraction, |
type(t_boundary_condition), intent(in) | vof_bc ) |
[in,out] | volume_fraction | volume fraction. |
[in] | vof_bc | boundary conditions. |
subroutine, public mod_vof_cfl::vof_cfl | ( | double precision, dimension(nx,ny,nz), intent(in) | volume_fraction, |
type(t_face_field), intent(in) | velocity, | ||
double precision, intent(in) | phase_advection_time_step, | ||
integer, intent(out) | nb_time_step, | ||
double precision, intent(out) | time_step, | ||
integer, intent(in) | nb_substeps ) |
This routine computes the number of secondary time steps required to make a single advection time step phase_advection_time_step that satisfy the CFL.
[in] | volume_fraction | volume fraction. |
[in] | velocity | velocity vector components. |
[in] | phase_advection_time_step | time step associated to the advection equation |
[out] | nb_time_step | number of secondary time steps. |
[out] | time_step | length of secondary time steps. |
[in] | nb_substeps | number of sub-steps. |