My Project
programmer's documentation
|
#include "cs_defs.h"
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <bft_mem.h>
#include <bft_printf.h>
#include "cs_base.h"
#include "cs_equation.h"
#include "cs_log.h"
#include "cs_navsto_param.h"
Functions | |
cs_navsto_param_t * | cs_navsto_param_create (const cs_boundary_t *boundaries, cs_navsto_param_model_t model, cs_navsto_param_time_state_t time_state, cs_navsto_param_coupling_t algo_coupling) |
Create a new structure to store all numerical parameters related to the resolution of the Navier-Stokes (NS) system. More... | |
cs_navsto_param_t * | cs_navsto_param_free (cs_navsto_param_t *param) |
Free a cs_navsto_param_t structure. More... | |
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. More... | |
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 system. More... | |
void | cs_navsto_param_log (const cs_navsto_param_t *nsp) |
Summary of the main cs_navsto_param_t structure. More... | |
const char * | cs_navsto_param_get_coupling_name (cs_navsto_param_coupling_t coupling) |
Retrieve the name of the coupling algorithm. More... | |
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 mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set to a constant value. More... | |
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 unkowns. This definition can be done on a specified mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set according to an analytical function. More... | |
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 mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set to a constant value. More... | |
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 unkowns. This definition can be done on a specified mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set according to an analytical function. More... | |
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 management of the Navier-Stokes system of equations. More... | |
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 management of the Navier-Stokes system of equations. More... | |
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 management of the Navier-Stokes system of equations. More... | |
void | cs_navsto_set_pressure_bc_by_value (cs_navsto_param_t *nsp, const char *z_name, cs_real_t *values) |
Define the pressure field on a boundary using a uniform value. More... | |
void | 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. More... | |
void | 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. More... | |
void | 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. More... | |
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. More... | |
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. More... | |
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. More... | |
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. More... | |
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.
[in,out] | nsp | pointer to a cs_navsto_param_t |
[in,out] | adv_fld | pointer to a cs_adv_field_t |
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 unkowns. This definition can be done on a specified mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set according to an analytical function.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" if all cells are considered) |
[in] | analytic | pointer to an analytic function |
[in] | input | NULL or pointer to a structure cast on-the-fly |
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 mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set to a constant value.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" if all cells are considered) |
[in] | val | pointer to the value |
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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all cells are considered) |
[in] | ana | pointer to an analytical function |
[in] | input | NULL or pointer to a structure cast on-the-fly |
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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all cells are considered) |
[in] | loc | information to know where are located values |
[in] | array | pointer to an array |
[in] | is_owner | transfer the lifecycle to the cs_xdef_t structure (true or false) |
[in] | index | optional pointer to the array index |
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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all cells are considered) |
[in] | val | pointer to the value to set |
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 unkowns. This definition can be done on a specified mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set according to an analytical function.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" if all cells are considered) |
[in] | analytic | pointer to an analytic function |
[in] | input | NULL or pointer to a structure cast on-the-fly |
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 mesh location. By default, the unknown is set to zero everywhere. Here the initial value is set to a constant value.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" if all cells are considered) |
[in] | val | pointer to the value |
cs_navsto_param_t* cs_navsto_param_create | ( | const cs_boundary_t * | boundaries, |
cs_navsto_param_model_t | model, | ||
cs_navsto_param_time_state_t | time_state, | ||
cs_navsto_param_coupling_t | algo_coupling | ||
) |
Create a new structure to store all numerical parameters related to the resolution of the Navier-Stokes (NS) system.
[in] | boundaries | pointer to a cs_boundary_t structure |
[in] | model | model related to the NS system to solve |
[in] | time_state | state of the time for the NS equations |
[in] | algo_coupling | algorithm used for solving the NS system |
cs_navsto_param_t* cs_navsto_param_free | ( | cs_navsto_param_t * | param | ) |
Free a cs_navsto_param_t structure.
[in,out] | param | pointer to a cs_navsto_param_t structure |
const char* cs_navsto_param_get_coupling_name | ( | cs_navsto_param_coupling_t | coupling | ) |
Retrieve the name of the coupling algorithm.
[in] | coupling | a cs_navsto_param_coupling_t |
void cs_navsto_param_log | ( | const cs_navsto_param_t * | nsp | ) |
Summary of the main cs_navsto_param_t structure.
[in] | nsp | pointer to a cs_navsto_param_t structure |
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.
[in,out] | nsp | pointer to a cs_navsto_param_t structure to set |
[in] | key | key related to the member of eq to set |
[in] | keyval | accessor to the value to set |
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 system.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in,out] | eqp | pointer to a cs_equation_param_t structure |
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 management of the Navier-Stokes system of equations.
[in] | nsp | pointer to a cs_navsto_param_t structure |
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 management of the Navier-Stokes system of equations.
[in] | nsp | pointer to a cs_navsto_param_t structure |
void cs_navsto_set_pressure_bc_by_value | ( | cs_navsto_param_t * | nsp, |
const char * | z_name, | ||
cs_real_t * | values | ||
) |
Define the pressure field on a boundary using a uniform value.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all boundary faces are considered) |
[in] | value | value to set |
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 management of the Navier-Stokes system of equations.
[in] | nsp | pointer to a cs_navsto_param_t structure |
void 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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all boundary faces are considered) |
[in] | ana | pointer to an analytical function |
[in] | input | NULL or pointer to a structure cast on-the-fly |
void 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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all boundary faces are considered) |
[in] | values | array of three real values |
void 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.
[in] | nsp | pointer to a cs_navsto_param_t structure |
[in] | z_name | name of the associated zone (if NULL or "" all boundary faces are considered) |
[in] | values | array of three real values |