8.0
general documentation
cs_gwf_two_phase_t Struct Reference

Structure to handle the modelling of miscible or immiscible two-phase flows in a porous media. More...

#include <cs_gwf_priv.h>

+ Collaboration diagram for cs_gwf_two_phase_t:

Data Fields

Equations and system of equations
cs_equation_twl_eq
 
cs_equation_thg_eq
 
cs_equation_param_twg_eqp
 
cs_equation_param_thl_eqp
 
cs_equation_system_tsystem
 
Darcy (advection) fields
cs_gwf_darcy_flux_tl_darcy
 
cs_gwf_darcy_flux_tg_darcy
 
Properties related to the model
cs_property_ttime_wl_pty
 
cs_property_tdiff_wl_pty
 
cs_property_ttime_wg_pty
 
cs_property_ttime_hg_pty
 
cs_property_tdiff_hg_pty
 
cs_property_treac_hg_pty
 
cs_property_ttime_hl_pty
 
cs_property_tdiff_hl_pty
 
Additional fields
cs_field_tl_saturation
 
cs_field_tc_pressure
 
cs_field_tl_pressure
 
cs_field_tg_pressure
 
Additional arrays
cs_real_ttime_wl_array
 
cs_real_tdiff_wl_array
 
cs_real_tsrct_wl_array
 
cs_real_ttime_wg_array
 
cs_real_ttime_hg_array
 
cs_real_tdiff_hg_array
 
cs_real_treac_hg_array
 
cs_real_tsrct_hg_array
 
cs_real_ttime_hl_array
 
cs_real_tdiff_hl_array
 
cs_real_tl_rel_permeability
 
cs_real_tg_rel_permeability
 
cs_real_tl_capacity
 
cs_real_tcapillarity_cell_pressure
 
cs_real_tg_cell_pressure
 
cs_real_tl_saturation_submesh
 
cs_real_tl_saturation_submesh_pre
 
Physical model parameters
cs_real_t l_mass_density
 
cs_real_t l_viscosity
 
cs_real_t g_viscosity
 
cs_real_t l_diffusivity_h
 
cs_real_t w_molar_mass
 
cs_real_t h_molar_mass
 
cs_real_t ref_temperature
 
cs_real_t henry_constant
 
Numerical parameters
bool use_coupled_solver
 When a model relies on several coupled equations, there are two main options to build and solve the system of equations. Either use a coupled solver (and thus build a coupled system) or use a segregated approach and an associated strategy to solve the sequence of equations and apply sub-iterations. The latter case (segregated solver) corresponds to the default choice. true if a coupled solver is used. Otherwise a segregated solver is considered. More...
 
bool use_incremental_solver
 When a model includes non-linearities it can be useful to formulate the problem using increment and to iterate on the non-linear process (for instance whith a Picard or Anderson acceleration) More...
 
bool use_properties_on_submesh
 Consider a submesh to define the liquid saturation. More...
 
bool use_explicit_dsldt_liquid
 Consider an explicit treatment of the time derivative of the liquid saturation in the mass conservation for the water equation. More...
 
cs_param_nl_algo_t nl_algo_type
 
cs_param_sles_cvg_t nl_algo_cvg
 
cs_iter_algo_param_aa_t anderson_param
 
cs_iter_algo_tnl_algo
 

Detailed Description

Structure to handle the modelling of miscible or immiscible two-phase flows in a porous media.

The model follows what is depicted in "Finite volume approximation of a diffusion-dissolution model and application to nuclear waste storage" O. Angelini, C. Chavant, E. Chénier, R. Eymard and S. Granet in Mathematics and Computers in Simulation (2011), 81 (10), pp. 2001–2017

Main assumptions are:

  • No water in the gaseous phase
  • Incompressibility of the liquid phase
  • Hydrogen pressure is given by the "perfect gas" law in the gas phase and the Henry's law in the liquid phase

The two primitive variables are the liquid and gas pressures with a specific treatment in the saturated case to handle the gas pressure (cf. the cited article or Angelini's PhD thesis)

Notations are the following :

  • Two phases: Liquid phase denoted by "l" and gaseous phase denoted by g
  • Two components: water denoted by w and a gaseous component (let's say hydrogen) denoted by h. The gaseous component is present in the two phases whereas water is only considered in the liquid phase.

The resulting linear algebraic system (one applies a linearization) is defined as follows:

                    liquid   gas

water conservation | M_wl | M_wg ||P_l| | b_w | |----—|---—||—| = |--—| hydrogen conservation | M_hl | M_hg ||P_g| | b_h |

This is coupled system. Coupling terms are collected inside M_wg and M_hl

Field Documentation

◆ anderson_param

anderson_param

Set of parameters to drive the Anderson acceleration (useful if the type of non-linear algorithm is set to the Anderson acceleration).

◆ c_pressure

c_pressure

Pointer to a cs_field_t structure named "capillarity_pressure". Capillarity pressure $ P_c = P_g - P_l $

◆ capillarity_cell_pressure

capillarity_cell_pressure

Values in each cell of the capillarity pressure. This quantity is the one used to update the variable related to a soil model such as the liquid and gaseous relative permeabilities or the liquid saturation.

◆ diff_hg_array

diff_hg_array

Values in each cell of the coefficient appearing in the diffusion term in the hydrogen conservation equation w.r.t. to the pressure in the gaseous phase. This array is linked to the diff_hg_pty (size = n_cells)

◆ diff_hg_pty

diff_hg_pty

Property related to the diffusion term of the hydrogen conservation equation w.r.t. the pressure in the gaseous phase

◆ diff_hl_array

diff_hl_array

Values in each cell of the coefficient appearing in the diffusion term in the hydrogen conservation equation w.r.t. the pressure in the liquid phase. This array is linked to the diff_hl_pty (size = n_cells)

◆ diff_hl_pty

diff_hl_pty

Property related to the diffusion term of the hydrogen conservation equation w.r.t. the pressure in the liquid phase

◆ diff_wl_array

diff_wl_array

Values in each cell of the coefficient appearing in the diffusion term in the water conservation equation. This array is linked to the diff_wl_pty (size = n_cells)

◆ diff_wl_pty

diff_wl_pty

Property related to the diffusion term of the water conservation equation w.r.t. the pressure in the liquid phase

◆ g_cell_pressure

g_cell_pressure

Values in each cell of the gas pressure. This quantity is the one used to update the unsteady/diffusion term coefficients in the conservation equation for the gas component. This quantity can also be useful for post-processing purposes.

◆ g_darcy

g_darcy

Pointer to a cs_gwf_darcy_flux_t structure. Darcy advective flux in the gas phase

◆ g_pressure

g_pressure

Pointer to a cs_field_t structure named "gas_pressure". Pressure in the gas phase is denoted by $ P_g $.

◆ g_rel_permeability

g_rel_permeability

Values in each cell of the relative permeability in the gas phase. This quantity is used either in the water conservation or in the hydrogen conservation. This enables also to recover the (full) permeability in the gas phase since permeability = abs_permeability * rel_l_permeability This quantity is defined by the soil model.

◆ g_viscosity

g_viscosity

Viscosity in the gas phase (assumed to be constant) in Pa.s

◆ h_molar_mass

h_molar_mass

Molar mass of the main component in the gas phase (e.g. hydrogen) in kg.mol^-1

◆ henry_constant

henry_constant

Value of the Henry constant used in the Henry's law. Setting a very low value for this constant enables the model to degenerate into an immiscible model.

◆ hg_eq

hg_eq

Equation of conservation for the (di)hydrogen. Hydrogen can be present in the liquid or in the gaseous phase. This corresponds to the block (1,1) in the system of equations, i.e. the M_hg block and the b_g right-hand side

◆ hl_eqp

hl_eqp

Parameters associated to the (h,l) block i.e. the (1,0) block in the system of equations. Conservation of the hydrogen w.r.t. the pressure in the liquid phase.

◆ l_capacity

l_capacity

Values in each cell of the soil capacity defined as $ \frac{\partial S_l}{\partial P_c} $ This quantity is defined by the soil model.

◆ l_darcy

l_darcy

Pointer to a cs_gwf_darcy_flux_t structure. Darcy advective flux in the liquid phase

◆ l_diffusivity_h

l_diffusivity_h

Molecular diffusivity of the hydrogen in the liquid phase in m^2.s^-1

◆ l_mass_density

l_mass_density

Mass density in the liquid phase. With the model assumptions, this corresponds to the mass density of the main component in the liquid phase (e.g. water) in kg.m^-3

◆ l_pressure

l_pressure

Pointer to a cs_field_t structure named "liquid_pressure". Pressure in the liquid phase is denoted by $ P_l $.

◆ l_rel_permeability

l_rel_permeability

Values in each cell of the relative permeability in the liquid phase. This quantity is used either in the water conservation or in the hydrogen conservation. This enables also to recover the (full) permeability in the liquid phase since permeability = abs_permeability * rel_l_permeability This quantity is defined by the soil model.

◆ l_saturation

l_saturation

Pointer to a cs_field_t structure. Liquid saturation at cells. This quantity is denoted by $ S_l $ and is defined by the soil model

◆ l_saturation_submesh

l_saturation_submesh

Array storing the current values of the liquid saturation on a submesh. This submesh corresponds to the subdivision of the primal mesh by the dual mesh associated to each vertex (scanned this array with the c2v adjacency structure). This array is allocated only if the option CS_GWF_LIQUID_SATURATION_ON_SUBMESH is swicth on.

◆ l_saturation_submesh_pre

l_saturation_submesh_pre

Array storing the previous values of the liquid saturation on a submesh. This submesh corresponds to the subdivision of the primal mesh by the dual mesh associated to each vertex (scanned this array with the c2v adjacency structure). This array is allocated only if the option CS_GWF_LIQUID_SATURATION_ON_SUBMESH is swicth on.

◆ l_viscosity

l_viscosity

Viscosity in the liquid phase (assumed to be constant) in Pa.s

◆ nl_algo

nl_algo

Structure used to manage the non-linearities

◆ nl_algo_cvg

nl_algo_cvg

Set of parameters to drive the convergence of the non-linear solver

◆ nl_algo_type

nl_algo_type

Type of algorithm to solve the non-linearities

◆ reac_hg_array

reac_hg_array

Values in each cell of the coefficient appearing in the reaction term in the hydrogen conservation equation w.r.t. to the pressure in the gaseous phase. This array is linked to the reac_hg_pty (size = n_cells)

◆ reac_hg_pty

reac_hg_pty

Property related to the reaction term of the hydrogen conservation equation w.r.t. the pressure in the gaseous phase

◆ ref_temperature

ref_temperature

Reference temperature used in the "perfect gas" law (this is used when no thermal equation is solved). One expects a temperature in Kelvin.

◆ srct_hg_array

srct_hg_array

Values in each vertex of the source term corresponding to a quantity proportional to the time evolution of the unsteady term in the hg equation. This term is allocated only if the optional parameter use_properties_on_submesh is activated

◆ srct_wl_array

srct_wl_array

Values in each cell of the source term corresponding to a quantity proportional to the time evolution of the liquid saturation

◆ system

system

System of equations (wl_eq, hg_eq and the cross-term defined in the related cs_equation_param_t structures) used for the coupled approach

◆ time_hg_array

time_hg_array

Values in each cell of the coefficient appearing in front of the unsteady term in the hydrogen conservation equation w.r.t. the pressure in the gaseous phase. This array is linked to the time_hg_pty (size = n_cells)

◆ time_hg_pty

time_hg_pty

Property related to the unsteady term of the hydrogen conservation equation w.r.t. the pressure in the gaseous phase.

◆ time_hl_array

time_hl_array

Values in each cell of the coefficient appearing in front of the unsteady term in the hydrogen conservation equation w.r.t. the pressure in the liquid phase. This array is linked to the time_hl_pty (size = n_cells)

◆ time_hl_pty

time_hl_pty

Property related to the unsteady term of the hydrogen conservation equation w.r.t. the pressure in the liquid phase.

◆ time_wg_array

time_wg_array

Values in each cell of the coefficient appearing in front of the unsteady term in the water conservation equation w.r.t. the pressure in the gaseous phase. This array is linked to the time_wg_pty (size = n_cells)

◆ time_wg_pty

time_wg_pty

Property related to the unsteady term of the water conservation equation w.r.t. the pressure in the gaseous phase

◆ time_wl_array

time_wl_array

Values in each cell of the coefficient appearing in front of the unsteady term in the water conservation equation for the liquid phase. This array is linked to the time_wl_pty (size = n_cells)

◆ time_wl_pty

time_wl_pty

Property related to the unsteady term of the water conservation equation w.r.t. the pressure in the liquid phase

◆ use_coupled_solver

use_coupled_solver

When a model relies on several coupled equations, there are two main options to build and solve the system of equations. Either use a coupled solver (and thus build a coupled system) or use a segregated approach and an associated strategy to solve the sequence of equations and apply sub-iterations. The latter case (segregated solver) corresponds to the default choice. true if a coupled solver is used. Otherwise a segregated solver is considered.

◆ use_explicit_dsldt_liquid

use_explicit_dsldt_liquid

Consider an explicit treatment of the time derivative of the liquid saturation in the mass conservation for the water equation.

◆ use_incremental_solver

use_incremental_solver

When a model includes non-linearities it can be useful to formulate the problem using increment and to iterate on the non-linear process (for instance whith a Picard or Anderson acceleration)

◆ use_properties_on_submesh

use_properties_on_submesh

Consider a submesh to define the liquid saturation.

◆ w_molar_mass

w_molar_mass

Molar mass of the main component in the liquid phase (e.g. water) in kg.mol^-1

◆ wg_eqp

wg_eqp

Parameters associated to the M_wg block i.e. the (0,1) block in the system of equations. Water conservation w.r.t. the pressure in the gaseous phase.

◆ wl_eq

wl_eq

Equation of conservation for the water component. Only the liquid phase is considered. One assumes no water vapour in the gaseous phase. This corresponds to the M_wl block in the system of equations and to the b_w right-hand side.


The documentation for this struct was generated from the following file: