8.3
general documentation
cs_gwf_uspf.cpp File Reference

Main high-level functions dedicated to groundwater flows when using CDO schemes for single-phase flows in an unsaturated porous media. More...

#include "cs_defs.h"
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <bft_mem.h>
#include <bft_printf.h>
#include "cs_array.h"
#include "cs_equation_bc.h"
#include "cs_gwf_soil.h"
#include "cs_log.h"
#include "cs_mesh_location.h"
#include "cs_parall.h"
#include "cs_param_types.h"
#include "cs_post.h"
#include "cs_gwf_uspf.h"
+ Include dependency graph for cs_gwf_uspf.cpp:

Macros

#define CS_GWF_USPF_DBG   0
 

Functions

cs_gwf_uspf_tcs_gwf_uspf_create (void)
 Allocate and initialize the model context structure in case of single-phase flows in an unsaturated porous media. More...
 
void cs_gwf_uspf_free (cs_gwf_uspf_t **p_mc)
 Free the model context structure in case of unsaturated single-phase flows. More...
 
void cs_gwf_uspf_log_setup (cs_gwf_uspf_t *mc)
 Log the setup related to the model context of unsaturated single-phase flows in porous media. More...
 
void cs_gwf_uspf_init (cs_gwf_uspf_t *mc, cs_property_type_t perm_type)
 Initialize the model context according to the settings done inside the function cs_user_model() Case of an unsaturated single-phase flows model in porous media. More...
 
void cs_gwf_uspf_init_setup (cs_flag_t flag, cs_flag_t post_flag, int perm_dim, cs_gwf_uspf_t *mc)
 Initial setup stage for single-phase flows in an unsaturated porous media. At this stage, all soils have been defined and equation parameters are set. More...
 
void cs_gwf_uspf_finalize_setup (const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *cdoq, cs_flag_t flag, cs_gwf_uspf_t *mc)
 Last setup stage in the case of single-phase flows in an unsaturated porous media. More...
 
void cs_gwf_uspf_update (const cs_mesh_t *mesh, const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *cdoq, const cs_time_step_t *ts, cs_flag_t update_flag, cs_flag_t option_flag, cs_gwf_uspf_t *mc)
 Update quantities in the case of single-phase flows in an unsaturated porous media. More...
 
void cs_gwf_uspf_compute (const cs_mesh_t *mesh, const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *cdoq, const cs_time_step_t *time_step, cs_flag_t flag, cs_gwf_uspf_t *mc)
 Compute the new state for the groundwater flows module. Case of single-phase flows in an unstaturated porous media. More...
 
void cs_gwf_uspf_extra_op (const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *cdoq, cs_flag_t post_flag, cs_gwf_uspf_t *mc)
 Predefined extra-operations for the groundwater flow module in case of single phase flows in an unsaturated porous media. More...
 
void cs_gwf_uspf_extra_post (int mesh_id, cs_lnum_t n_cells, const cs_lnum_t cell_ids[], cs_flag_t post_flag, const cs_gwf_uspf_t *mc, const cs_time_step_t *time_step)
 Predefined post-processing output for the groundwater flow module in case of single-phase flows in an unsaturated porous media. More...
 

Detailed Description

Main high-level functions dedicated to groundwater flows when using CDO schemes for single-phase flows in an unsaturated porous media.

Macro Definition Documentation

◆ CS_GWF_USPF_DBG

#define CS_GWF_USPF_DBG   0

Function Documentation

◆ cs_gwf_uspf_compute()

void cs_gwf_uspf_compute ( const cs_mesh_t mesh,
const cs_cdo_connect_t connect,
const cs_cdo_quantities_t cdoq,
const cs_time_step_t time_step,
cs_flag_t  flag,
cs_gwf_uspf_t mc 
)

Compute the new state for the groundwater flows module. Case of single-phase flows in an unstaturated porous media.

Parameters
[in]meshpointer to a cs_mesh_t structure
[in]connectpointer to a cs_cdo_connect_t structure
[in]cdoqpointer to a cs_cdo_quantities_t structure
[in]time_steppointer to a cs_time_step_t structure
[in]flagoptional metadata for the module
[in,out]mcpointer to the model context structure

◆ cs_gwf_uspf_create()

cs_gwf_uspf_t * cs_gwf_uspf_create ( void  )

Allocate and initialize the model context structure in case of single-phase flows in an unsaturated porous media.

Returns
a pointer to a new allocated structure

◆ cs_gwf_uspf_extra_op()

void cs_gwf_uspf_extra_op ( const cs_cdo_connect_t connect,
const cs_cdo_quantities_t cdoq,
cs_flag_t  post_flag,
cs_gwf_uspf_t mc 
)

Predefined extra-operations for the groundwater flow module in case of single phase flows in an unsaturated porous media.

Parameters
[in]connectpointer to a cs_cdo_connect_t structure
[in]cdoqpointer to a cs_cdo_quantities_t structure
[in]post_flagrequested quantities to be postprocessed
[in,out]mcpointer to the casted model context

◆ cs_gwf_uspf_extra_post()

void cs_gwf_uspf_extra_post ( int  mesh_id,
cs_lnum_t  n_cells,
const cs_lnum_t  cell_ids[],
cs_flag_t  post_flag,
const cs_gwf_uspf_t mc,
const cs_time_step_t time_step 
)

Predefined post-processing output for the groundwater flow module in case of single-phase flows in an unsaturated porous media.

Parameters
[in]mesh_idid of the output mesh for the current call
[in]n_cellslocal number of cells of post_mesh
[in]cell_idslist of cells (0 to n-1)
[in]post_flagflag gathering quantities to postprocess
[in]mcpointer to the model context structure
[in]time_steppointer to a cs_time_step_t struct.

◆ cs_gwf_uspf_finalize_setup()

void cs_gwf_uspf_finalize_setup ( const cs_cdo_connect_t connect,
const cs_cdo_quantities_t cdoq,
cs_flag_t  flag,
cs_gwf_uspf_t mc 
)

Last setup stage in the case of single-phase flows in an unsaturated porous media.

Parameters
[in]connectpointer to a cs_cdo_connect_t structure
[in]cdoqpointer to a cs_cdo_quantities_t structure
[in]flagoptional settings for the module
[in,out]mcpointer to the model context structure

◆ cs_gwf_uspf_free()

void cs_gwf_uspf_free ( cs_gwf_uspf_t **  p_mc)

Free the model context structure in case of unsaturated single-phase flows.

Parameters
[in,out]p_mcpointer of pointer to the model context structure

◆ cs_gwf_uspf_init()

void cs_gwf_uspf_init ( cs_gwf_uspf_t mc,
cs_property_type_t  perm_type 
)

Initialize the model context according to the settings done inside the function cs_user_model() Case of an unsaturated single-phase flows model in porous media.

Parameters
[in,out]mcpointer to the model context structure
[in,out]perm_typetype of permeability to handle

◆ cs_gwf_uspf_init_setup()

void cs_gwf_uspf_init_setup ( cs_flag_t  flag,
cs_flag_t  post_flag,
int  perm_dim,
cs_gwf_uspf_t mc 
)

Initial setup stage for single-phase flows in an unsaturated porous media. At this stage, all soils have been defined and equation parameters are set.

Parameters
[in]flagoptional settings for the module
[in]post_flagoptional postprocessing request(s)
[in]perm_dimdimension of the permeability (scalar, etc.)
[in,out]mcpointer to the model context structure

◆ cs_gwf_uspf_log_setup()

void cs_gwf_uspf_log_setup ( cs_gwf_uspf_t mc)

Log the setup related to the model context of unsaturated single-phase flows in porous media.

Parameters
[in]mcpointer to the model context structure

◆ cs_gwf_uspf_update()

void cs_gwf_uspf_update ( const cs_mesh_t mesh,
const cs_cdo_connect_t connect,
const cs_cdo_quantities_t cdoq,
const cs_time_step_t ts,
cs_flag_t  update_flag,
cs_flag_t  option_flag,
cs_gwf_uspf_t mc 
)

Update quantities in the case of single-phase flows in an unsaturated porous media.

Parameters
[in]meshpointer to a cs_mesh_t structure
[in]connectpointer to a cs_cdo_connect_t structure
[in]cdoqpointer to a cs_cdo_quantities_t structure
[in]tspointer to a cs_time_step_t structure
[in]update_flagmetadata associated to type of operation to do
[in]option_flagcalculation option related to the GWF module
[in,out]mcpointer to the casted model context