1 #ifndef __CS_SOURCE_TERM_H__ 2 #define __CS_SOURCE_TERM_H__ 50 #define CS_N_MAX_SOURCE_TERMS 8 // Max number of source terms in an equation 296 const int n_source_terms,
void() cs_analytic_func_t(cs_real_t time, cs_lnum_t n_points, const cs_real_t *xyz, cs_real_t *retval)
Generic analytic function.
Definition: cs_cdo.h:159
time step descriptor
Definition: cs_time_step.h:51
#define restrict
Definition: cs_defs.h:122
void cs_source_term_dcsd_q5o3_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1439
cs_param_def_type_t def_type
Definition: cs_source_term.h:64
void cs_source_term_compute(cs_desc_t dof_desc, const cs_source_term_t *source, double *p_values[])
Compute the contribution related to a source term.
Definition: cs_source_term.c:889
const void * struc
Definition: cs_source_term.h:70
#define BEGIN_C_DECLS
Definition: cs_defs.h:451
void cs_source_term_compute_cellwise(const int n_source_terms, const cs_source_term_t *source_terms, const cs_cell_mesh_t *cm, const cs_flag_t sys_flag, const cs_mask_t *source_mask, cs_source_term_cellwise_t *compute_source[], cs_cell_builder_t *cb, cs_cell_sys_t *csys)
Compute the local contributions of source terms in a cell.
Definition: cs_source_term.c:831
unsigned char cs_mask_t
Definition: cs_cdo.h:115
void cs_source_term_dcsd_q1o1_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1192
Definition: cs_cdo_local.h:132
void cs_source_term_dcsd_bary_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1110
void cs_source_term_set_reduction(cs_source_term_t *st, cs_flag_t flag)
Set advanced parameters which are defined by default in a source term structure.
Definition: cs_source_term.c:488
Definition: cs_cdo_connect.h:56
cs_real_t * array
Definition: cs_source_term.h:69
void cs_source_term_summary(const char *eqname, const cs_source_term_t *st)
Summarize the content of a cs_source_term_t structure.
Definition: cs_source_term.c:580
void cs_source_term_def_by_value(cs_source_term_t *st, int st_id, const char *name, cs_param_var_type_t var_type, int ml_id, cs_flag_t flag, const char *val)
Generic way to define a cs_source_term_t structure by value.
Definition: cs_source_term.c:228
double cs_real_t
Floating-point value.
Definition: cs_defs.h:297
Definition: cs_cdo_quantities.h:102
Definition: cs_cdo_local.h:90
void cs_source_term_vcsp_by_value(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1524
void cs_source_term_vcsp_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1569
cs_space_scheme_t
Definition: cs_cdo.h:137
void cs_source_term_set_shared_pointers(const cs_cdo_quantities_t *quant, const cs_cdo_connect_t *connect, const cs_time_step_t *time_step)
Set shared pointers to main domain members.
Definition: cs_source_term.c:168
cs_quadra_type_t quad_type
Definition: cs_source_term.h:63
cs_desc_t array_desc
Definition: cs_source_term.h:68
int ml_id
Definition: cs_source_term.h:59
void cs_source_term_dcsd_q10o2_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1264
const char * cs_source_term_get_name(const cs_source_term_t *st)
Get the name related to a cs_source_term_t structure.
Definition: cs_source_term.c:562
cs_flag_t cs_source_term_init(cs_space_scheme_t space_scheme, const int n_source_terms, const cs_source_term_t *source_terms, cs_source_term_cellwise_t *compute_source[], cs_flag_t *sys_flag, cs_mask_t *source_mask[])
Initialize data to build the source terms.
Definition: cs_source_term.c:624
void cs_source_term_def_by_array(cs_source_term_t *st, int st_id, const char *name, cs_param_var_type_t var_type, int ml_id, cs_flag_t flag, cs_desc_t desc, cs_real_t *array)
Define a cs_source_term_t structure thanks to an array of values.
Definition: cs_source_term.c:366
Definition: cs_cdo_local.h:67
void cs_source_term_set_quadrature(cs_source_term_t *st, cs_quadra_type_t quad_type)
Set the type of quadrature to use for computing the source term.
Definition: cs_source_term.c:429
cs_quadra_type_t
Definition: cs_quadrature.h:47
Definition: cs_param.h:72
void() cs_source_term_cellwise_t(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.h:87
cs_flag_t flag
Definition: cs_source_term.h:62
char *restrict name
Definition: cs_source_term.h:58
#define END_C_DECLS
Definition: cs_defs.h:452
unsigned short int cs_flag_t
Definition: cs_defs.h:299
void cs_source_term_dcsd_by_value(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1074
cs_def_t def
Definition: cs_source_term.h:65
cs_param_var_type_t
Definition: cs_param.h:120
cs_flag_t cs_source_term_set_default_flag(cs_space_scheme_t scheme)
Set the default flag related to a source term according to the numerical scheme chosen for discretizi...
Definition: cs_source_term.c:450
void cs_source_term_pvsp_by_value(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:988
cs_source_term_t * cs_source_term_destroy(int n_source_terms, cs_source_term_t *source_terms)
Destroy an array of cs_source_term_t structures.
Definition: cs_source_term.c:190
void cs_source_term_def_by_analytic(cs_source_term_t *st, int st_id, const char *name, cs_param_var_type_t var_type, int ml_id, cs_flag_t flag, cs_analytic_func_t *func)
Define a cs_source_term_t structure thanks to an analytic function.
Definition: cs_source_term.c:298
void cs_source_term_pvsp_by_analytic(const cs_source_term_t *source, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb, double *values)
Compute the contribution for a cell related to a source term and add it the given array of values...
Definition: cs_source_term.c:1033
cs_param_def_type_t
Definition: cs_param.h:94
Definition: cs_source_term.h:56
cs_flag_t cs_source_term_get_flag(const cs_source_term_t *st)
Get metadata related to the given source term structure.
Definition: cs_source_term.c:543