1 #ifndef __CS_NAVSTO_PARAM_H__
2 #define __CS_NAVSTO_PARAM_H__
51 #define CS_NAVSTO_STREAM_EQNAME "streamfunction_eq"
1047 const char *keyval);
#define BEGIN_C_DECLS
Definition: cs_defs.h:492
double cs_real_t
Floating-point value.
Definition: cs_defs.h:304
#define END_C_DECLS
Definition: cs_defs.h:493
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:298
unsigned short int cs_flag_t
Definition: cs_defs.h:306
Structure and routines handling the specific settings related to a cs_equation_t structure.
void cs_navsto_param_transfer(const cs_navsto_param_t *nsp, cs_equation_param_t *eqp)
Apply the numerical settings defined for the Navier-Stokes system to an equation related to this syst...
Definition: cs_navsto_param.c:1145
void cs_navsto_set_fixed_walls(cs_navsto_param_t *nsp)
Add the definition of boundary conditions related to a fixed wall into the set of parameters for the ...
Definition: cs_navsto_param.c:1700
cs_navsto_sles_t
High-level information about the way of settings the SLES for solving the Navier-Stokes system....
Definition: cs_navsto_param.h:334
@ CS_NAVSTO_SLES_EQ_WITHOUT_BLOCK
Definition: cs_navsto_param.h:340
@ CS_NAVSTO_SLES_BLOCK_MULTIGRID_CG
Definition: cs_navsto_param.h:337
@ CS_NAVSTO_SLES_N_TYPES
Definition: cs_navsto_param.h:350
@ CS_NAVSTO_SLES_GKB_GMRES
Definition: cs_navsto_param.h:342
@ CS_NAVSTO_SLES_UZAWA_CG
Definition: cs_navsto_param.h:348
@ CS_NAVSTO_SLES_GKB_PETSC
Definition: cs_navsto_param.h:341
@ CS_NAVSTO_SLES_MUMPS
Definition: cs_navsto_param.h:345
@ CS_NAVSTO_SLES_GKB_SATURNE
Definition: cs_navsto_param.h:343
@ CS_NAVSTO_SLES_DIAG_SCHUR_GMRES
Definition: cs_navsto_param.h:339
@ CS_NAVSTO_SLES_UZAWA_AL
Definition: cs_navsto_param.h:347
@ CS_NAVSTO_SLES_BY_BLOCKS
Definition: cs_navsto_param.h:338
@ CS_NAVSTO_SLES_UPPER_SCHUR_GMRES
Definition: cs_navsto_param.h:346
@ CS_NAVSTO_SLES_MULTIPLICATIVE_GMRES_BY_BLOCK
Definition: cs_navsto_param.h:344
@ CS_NAVSTO_SLES_ADDITIVE_GMRES_BY_BLOCK
Definition: cs_navsto_param.h:336
void cs_navsto_set_symmetries(cs_navsto_param_t *nsp)
Add the definition of boundary conditions related to a symmetry into the set of parameters for the ma...
Definition: cs_navsto_param.c:1748
cs_xdef_t * cs_navsto_add_velocity_ic_by_analytic(cs_navsto_param_t *nsp, const char *z_name, cs_analytic_func_t *analytic, void *input)
Define the initial condition for the velocity unknowns. This definition can be done on a specified me...
Definition: cs_navsto_param.c:1529
cs_flag_t cs_navsto_param_post_flag_t
Definition: cs_navsto_param.h:58
cs_xdef_t * cs_navsto_set_velocity_inlet_by_array(cs_navsto_param_t *nsp, const char *z_name, cs_flag_t loc, cs_real_t *array, bool is_owner, cs_lnum_t *index)
Define the velocity field for an inlet boundary using an array of values.
Definition: cs_navsto_param.c:2134
void cs_navsto_set_reference_pressure(cs_navsto_param_t *nsp, cs_real_t pref)
Set the value to consider for the reference pressure.
Definition: cs_navsto_param.c:1440
cs_navsto_param_t * cs_navsto_param_create(const cs_boundary_t *boundaries, cs_navsto_param_model_t model, cs_navsto_param_model_flag_t model_flag, cs_navsto_param_coupling_t algo_coupling, cs_navsto_param_post_flag_t post_flag)
Create a new structure to store all numerical parameters related to the resolution of the Navier-Stok...
Definition: cs_navsto_param.c:494
cs_xdef_t * cs_navsto_set_velocity_inlet_by_value(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *values)
Define the velocity field for an inlet boundary using a uniform value.
Definition: cs_navsto_param.c:1998
cs_xdef_t * cs_navsto_set_velocity_inlet_by_analytic(cs_navsto_param_t *nsp, const char *z_name, cs_analytic_func_t *ana, void *input)
Define the velocity field for an inlet boundary using an analytical function.
Definition: cs_navsto_param.c:2060
cs_navsto_key_t
List of available keys for setting the parameters of the Navier-Stokes system.
Definition: cs_navsto_param.h:934
@ CS_NSKEY_MAX_OUTER_ITER
Definition: cs_navsto_param.h:948
@ CS_NSKEY_IL_ALGO_ATOL
Definition: cs_navsto_param.h:942
@ CS_NSKEY_SLES_STRATEGY
Definition: cs_navsto_param.h:956
@ CS_NSKEY_TIME_SCHEME
Definition: cs_navsto_param.h:959
@ CS_NSKEY_NL_ALGO_RTOL
Definition: cs_navsto_param.h:952
@ CS_NSKEY_DOF_REDUCTION
Definition: cs_navsto_param.h:940
@ CS_NSKEY_THERMAL_TOLERANCE
Definition: cs_navsto_param.h:958
@ CS_NSKEY_TIME_THETA
Definition: cs_navsto_param.h:960
@ CS_NSKEY_NL_ALGO_ATOL
Definition: cs_navsto_param.h:950
@ CS_NSKEY_ADVECTION_FORMULATION
Definition: cs_navsto_param.h:937
@ CS_NSKEY_N_KEYS
Definition: cs_navsto_param.h:963
@ CS_NSKEY_ADVECTION_SCHEME
Definition: cs_navsto_param.h:938
@ CS_NSKEY_ADVECTION_STRATEGY
Definition: cs_navsto_param.h:939
@ CS_NSKEY_IL_ALGO_DTOL
Definition: cs_navsto_param.h:943
@ CS_NSKEY_GD_SCALE_COEF
Definition: cs_navsto_param.h:941
@ CS_NSKEY_NL_ALGO
Definition: cs_navsto_param.h:949
@ CS_NSKEY_IL_ALGO_VERBOSITY
Definition: cs_navsto_param.h:945
@ CS_NSKEY_SPACE_SCHEME
Definition: cs_navsto_param.h:957
@ CS_NSKEY_QUADRATURE
Definition: cs_navsto_param.h:954
@ CS_NSKEY_MAX_NL_ALGO_ITER
Definition: cs_navsto_param.h:947
@ CS_NSKEY_MAX_IL_ALGO_ITER
Definition: cs_navsto_param.h:946
@ CS_NSKEY_NL_ALGO_VERBOSITY
Definition: cs_navsto_param.h:953
@ CS_NSKEY_VERBOSITY
Definition: cs_navsto_param.h:961
@ CS_NSKEY_SCHUR_STRATEGY
Definition: cs_navsto_param.h:955
@ CS_NSKEY_IL_ALGO_RTOL
Definition: cs_navsto_param.h:944
@ CS_NSKEY_NL_ALGO_DTOL
Definition: cs_navsto_param.h:951
@ CS_NSKEY_ADVECTION_EXTRAPOL
Definition: cs_navsto_param.h:936
void cs_navsto_add_oseen_field(cs_navsto_param_t *nsp, cs_adv_field_t *adv_fld)
Add a advection field for the Oseen problem.
Definition: cs_navsto_param.c:2364
cs_xdef_t * cs_navsto_add_velocity_ic_by_value(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *val)
Define the initial condition for the velocity unknowns. This definition can be done on a specified me...
Definition: cs_navsto_param.c:1466
const char * cs_navsto_param_get_model_name(cs_navsto_param_model_t model)
Retrieve the name of the model system of equations.
Definition: cs_navsto_param.c:1383
void cs_navsto_param_log(const cs_navsto_param_t *nsp)
Summary of the main cs_navsto_param_t structure.
Definition: cs_navsto_param.c:1204
cs_xdef_t * cs_navsto_add_pressure_ic_by_analytic(cs_navsto_param_t *nsp, const char *z_name, cs_analytic_func_t *analytic, void *input)
Define the initial condition for the pressure unknowns. This definition can be done on a specified me...
Definition: cs_navsto_param.c:1649
cs_navsto_param_t * cs_navsto_param_free(cs_navsto_param_t *param)
Free a cs_navsto_param_t structure.
Definition: cs_navsto_param.c:655
cs_navsto_schur_approx_t
Strategy to build the Schur complement approximation. This appears in block preconditioning or uzawa ...
Definition: cs_navsto_param.h:373
@ CS_NAVSTO_SCHUR_DIAG_INVERSE
Definition: cs_navsto_param.h:375
@ CS_NAVSTO_SCHUR_LUMPED_INVERSE
Definition: cs_navsto_param.h:376
@ CS_NAVSTO_N_SCHUR_APPROX
Definition: cs_navsto_param.h:378
cs_xdef_t * cs_navsto_add_source_term_by_val(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *val)
Define a new source term structure defined by a constant value.
Definition: cs_navsto_param.c:2308
const char * cs_navsto_param_get_coupling_name(cs_navsto_param_coupling_t coupling)
Retrieve the name of the coupling algorithm.
Definition: cs_navsto_param.c:1412
cs_xdef_t * cs_navsto_set_velocity_wall_by_value(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *values)
Define the velocity field for a sliding wall boundary using a uniform value.
Definition: cs_navsto_param.c:1938
cs_xdef_t * cs_navsto_set_pressure_bc_by_value(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *values)
Set the pressure field on a boundary using a uniform value.
Definition: cs_navsto_param.c:1852
cs_xdef_t * cs_navsto_add_pressure_ic_by_value(cs_navsto_param_t *nsp, const char *z_name, cs_real_t *val)
Define the initial condition for the pressure unknowns. This definition can be done on a specified me...
Definition: cs_navsto_param.c:1600
cs_navsto_param_coupling_t
Choice of algorithm for solving the system.
Definition: cs_navsto_param.h:525
@ CS_NAVSTO_N_COUPLINGS
Definition: cs_navsto_param.h:531
@ CS_NAVSTO_COUPLING_ARTIFICIAL_COMPRESSIBILITY
Definition: cs_navsto_param.h:527
@ CS_NAVSTO_COUPLING_PROJECTION
Definition: cs_navsto_param.h:529
@ CS_NAVSTO_COUPLING_MONOLITHIC
Definition: cs_navsto_param.h:528
cs_xdef_t * cs_navsto_set_velocity_inlet_by_dof_func(cs_navsto_param_t *nsp, const char *z_name, cs_dof_func_t *func, void *func_input)
Define the velocity field for an inlet boundary using a DoF function.
Definition: cs_navsto_param.c:2204
cs_navsto_param_model_t
Describe the system of equations related to the Navier-Stokes to be solved.
Definition: cs_navsto_param.h:81
@ CS_NAVSTO_MODEL_STOKES
Definition: cs_navsto_param.h:83
@ CS_NAVSTO_MODEL_OSEEN
Definition: cs_navsto_param.h:84
@ CS_NAVSTO_MODEL_INCOMPRESSIBLE_NAVIER_STOKES
Definition: cs_navsto_param.h:85
@ CS_NAVSTO_N_MODELS
Definition: cs_navsto_param.h:87
cs_flag_t cs_navsto_param_model_flag_t
Definition: cs_navsto_param.h:57
cs_xdef_t * cs_navsto_add_source_term_by_analytic(cs_navsto_param_t *nsp, const char *z_name, cs_analytic_func_t *ana, void *input)
Define a new source term structure defined by an analytical function.
Definition: cs_navsto_param.c:2274
cs_navsto_param_post_bit_t
Bit values for additional generic postprocessing related to the Navier-Stokes module....
Definition: cs_navsto_param.h:174
@ CS_NAVSTO_POST_VELOCITY_DIVERGENCE
Definition: cs_navsto_param.h:176
@ CS_NAVSTO_POST_KINETIC_ENERGY
Definition: cs_navsto_param.h:177
@ CS_NAVSTO_POST_HELICITY
Definition: cs_navsto_param.h:181
@ CS_NAVSTO_POST_STREAM_FUNCTION
Definition: cs_navsto_param.h:180
@ CS_NAVSTO_POST_VELOCITY_GRADIENT
Definition: cs_navsto_param.h:179
@ CS_NAVSTO_POST_ENSTROPHY
Definition: cs_navsto_param.h:182
@ CS_NAVSTO_POST_VORTICITY
Definition: cs_navsto_param.h:178
cs_xdef_t * cs_navsto_add_source_term_by_array(cs_navsto_param_t *nsp, const char *z_name, cs_flag_t loc, cs_real_t *array, bool is_owner, cs_lnum_t *index)
Define a new source term structure defined by an array.
Definition: cs_navsto_param.c:2338
void cs_navsto_set_outlets(cs_navsto_param_t *nsp)
Add the definition of boundary conditions related to outlets into the set of parameters for the manag...
Definition: cs_navsto_param.c:1798
cs_equation_param_t * cs_navsto_param_get_velocity_param(const cs_navsto_param_t *nsp)
Retrieve the cs_equation_param_t structure related to the velocity equation (momentum equation in mos...
Definition: cs_navsto_param.c:1347
void cs_navsto_param_set(cs_navsto_param_t *nsp, cs_navsto_key_t key, const char *keyval)
Set a parameter attached to a keyname in a cs_navsto_param_t structure.
Definition: cs_navsto_param.c:737
cs_navsto_nl_algo_t
Type of algorithm used to tackle the non-linearity arising from the Navier-Stokes system.
Definition: cs_navsto_param.h:393
@ CS_NAVSTO_NL_PICARD_ALGO
Definition: cs_navsto_param.h:395
@ CS_NAVSTO_NL_ALGO_TYPES
Definition: cs_navsto_param.h:397
cs_navsto_param_model_bit_t
Bit values for additional physical modelling related to the Navier-Stokes system of equations.
Definition: cs_navsto_param.h:132
@ CS_NAVSTO_MODEL_GRAVITY_EFFECTS
Definition: cs_navsto_param.h:135
@ CS_NAVSTO_MODEL_BOUSSINESQ
Definition: cs_navsto_param.h:138
@ CS_NAVSTO_MODEL_SOLIDIFICATION_BOUSSINESQ
Definition: cs_navsto_param.h:139
@ CS_NAVSTO_MODEL_PASSIVE_THERMAL_TRACER
Definition: cs_navsto_param.h:137
@ CS_NAVSTO_MODEL_CORIOLIS_EFFECTS
Definition: cs_navsto_param.h:136
@ CS_NAVSTO_MODEL_STEADY
Definition: cs_navsto_param.h:134
Structure and routines handling the SLES settings stored inside a cs_param_sles_t structure.
void() cs_dof_func_t(cs_lnum_t n_elts, const cs_lnum_t *elt_ids, bool dense_output, void *input, cs_real_t *retval)
Generic function pointer for computing a quantity at predefined locations such as degrees of freedom ...
Definition: cs_param_types.h:119
cs_param_space_scheme_t
Type of numerical scheme for the discretization in space.
Definition: cs_param_types.h:172
cs_param_advection_form_t
Definition: cs_param_types.h:267
void() cs_analytic_func_t(cs_real_t time, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, const cs_real_t *coords, bool dense_output, void *input, cs_real_t *retval)
Generic function pointer for an evaluation relying on an analytic function elt_ids is optional....
Definition: cs_param_types.h:94
cs_param_advection_extrapol_t
Choice of how to extrapolate the advection field in the advection term.
Definition: cs_param_types.h:378
cs_param_time_scheme_t
Definition: cs_param_types.h:234
cs_param_advection_scheme_t
Definition: cs_param_types.h:311
cs_param_dof_reduction_t
Definition: cs_param_types.h:199
cs_param_advection_strategy_t
Choice of how to handle the advection term in an equation.
Definition: cs_param_types.h:344
cs_quadrature_type_t
Definition: cs_quadrature.h:52
Definition: cs_advection_field.h:149
Structure storing information related to the "physical" boundaries associated with the computational ...
Definition: cs_boundary.h:155
Set of parameters to handle an unsteady convection-diffusion-reaction equation with term sources.
Definition: cs_equation_param.h:202
Structure storing the parameters for solving the Navier-Stokes system.
Definition: cs_navsto_param.h:405
cs_real_t il_algo_dtol
Definition: cs_navsto_param.h:441
cs_param_sles_t * schur_sles_param
Definition: cs_navsto_param.h:505
int n_max_il_algo_iter
Definition: cs_navsto_param.h:446
cs_real_t nl_algo_rtol
Definition: cs_navsto_param.h:470
cs_real_t nl_algo_dtol
Definition: cs_navsto_param.h:482
int nl_algo_verbosity
Definition: cs_navsto_param.h:493
cs_navsto_schur_approx_t schur_approximation
Definition: cs_navsto_param.h:415
cs_real_t nl_algo_atol
Definition: cs_navsto_param.h:476
cs_real_t il_algo_atol
Definition: cs_navsto_param.h:435
cs_navsto_sles_t strategy
Definition: cs_navsto_param.h:410
int il_algo_verbosity
Definition: cs_navsto_param.h:451
cs_navsto_nl_algo_t nl_algo
Definition: cs_navsto_param.h:464
cs_real_t il_algo_rtol
Definition: cs_navsto_param.h:429
int n_max_nl_algo_iter
Definition: cs_navsto_param.h:488
Structure storing the parameters related to the resolution of the Navier-Stokes system.
Definition: cs_navsto_param.h:540
cs_property_t * lam_viscosity
Definition: cs_navsto_param.h:595
cs_property_t * mass_density
Definition: cs_navsto_param.h:581
cs_navsto_param_sles_t * sles_param
Definition: cs_navsto_param.h:662
cs_quadrature_type_t qtype
Definition: cs_navsto_param.h:657
int n_velocity_bc_defs
Definition: cs_navsto_param.h:770
cs_xdef_t ** velocity_ic_defs
Definition: cs_navsto_param.h:721
cs_physical_constants_t * phys_constants
Definition: cs_navsto_param.h:574
cs_param_advection_scheme_t adv_scheme
Definition: cs_navsto_param.h:649
cs_lnum_t * solid_cell_ids
Definition: cs_navsto_param.h:815
cs_param_time_scheme_t time_scheme
Definition: cs_navsto_param.h:628
cs_real_t gd_scale_coef
Definition: cs_navsto_param.h:619
bool pressure_ic_is_owner
Definition: cs_navsto_param.h:737
cs_navsto_param_model_t model
Definition: cs_navsto_param.h:552
int n_pressure_ic_defs
Definition: cs_navsto_param.h:738
cs_param_advection_strategy_t adv_strategy
Definition: cs_navsto_param.h:650
int n_pressure_bc_defs
Definition: cs_navsto_param.h:787
cs_xdef_t ** velocity_bc_defs
Definition: cs_navsto_param.h:771
cs_property_t * tot_viscosity
Definition: cs_navsto_param.h:589
cs_turbulence_param_t * turbulence
Definition: cs_navsto_param.h:563
cs_navsto_param_post_flag_t post_flag
Definition: cs_navsto_param.h:691
bool pressure_bc_is_owner
Definition: cs_navsto_param.h:786
cs_xdef_t ** pressure_bc_defs
Definition: cs_navsto_param.h:788
cs_navsto_param_model_flag_t model_flag
Definition: cs_navsto_param.h:557
cs_real_t reference_pressure
Definition: cs_navsto_param.h:800
cs_lnum_t n_solid_cells
Definition: cs_navsto_param.h:814
int verbosity
Definition: cs_navsto_param.h:686
bool velocity_bc_is_owner
Definition: cs_navsto_param.h:769
cs_param_dof_reduction_t dof_reduction_mode
Definition: cs_navsto_param.h:607
cs_real_t delta_thermal_tolerance
Definition: cs_navsto_param.h:668
int n_max_outer_iter
Definition: cs_navsto_param.h:676
cs_param_advection_form_t adv_form
Definition: cs_navsto_param.h:648
int n_velocity_ic_defs
Definition: cs_navsto_param.h:720
bool velocity_ic_is_owner
Definition: cs_navsto_param.h:719
cs_param_advection_extrapol_t adv_extrapol
Definition: cs_navsto_param.h:651
const cs_boundary_t * boundaries
Definition: cs_navsto_param.h:752
cs_real_t theta
Definition: cs_navsto_param.h:629
cs_xdef_t ** pressure_ic_defs
Definition: cs_navsto_param.h:739
cs_param_space_scheme_t space_scheme
Definition: cs_navsto_param.h:634
cs_navsto_param_coupling_t coupling
Definition: cs_navsto_param.h:612
Structure storing all metadata related to the resolution of a linear system with an iterative solver.
Definition: cs_param_sles.h:62
Physical constants descriptor.
Definition: cs_physical_constants.h:51
Structure associated to the definition of a property relying on the cs_xdef_t structure.
Structure storing the parameters related to the resolution of the tubulence modelling....
Definition: cs_cdo_turbulence.h:63
Structure storing medata for defining a quantity in a very flexible way.
Definition: cs_xdef.h:154