6.2
general documentation
cs_equation_param.h
Go to the documentation of this file.
1 #ifndef __CS_EQUATION_PARAM_H__
2 #define __CS_EQUATION_PARAM_H__
3 
4 /*============================================================================
5  * Header to handle specific settings related to a cs_equation_t structure
6  *============================================================================*/
7 
8 /*
9  This file is part of Code_Saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2020 EDF S.A.
12 
13  This program is free software; you can redistribute it and/or modify it under
14  the terms of the GNU General Public License as published by the Free Software
15  Foundation; either version 2 of the License, or (at your option) any later
16  version.
17 
18  This program is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
20  FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
21  details.
22 
23  You should have received a copy of the GNU General Public License along with
24  this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
25  Street, Fifth Floor, Boston, MA 02110-1301, USA.
26 */
27 
28 /*----------------------------------------------------------------------------
29  * Local headers
30  *----------------------------------------------------------------------------*/
31 
32 #include "cs_advection_field.h"
33 #include "cs_param_cdo.h"
34 #include "cs_hodge.h"
35 #include "cs_property.h"
36 #include "cs_xdef.h"
37 
38 /*----------------------------------------------------------------------------*/
39 
41 
50 /*============================================================================
51  * Macro definitions
52  *============================================================================*/
53 
91 #define CS_EQUATION_LOCKED (1 << 0) /* 1 */
92 #define CS_EQUATION_UNSTEADY (1 << 1) /* 2 */
93 #define CS_EQUATION_CONVECTION (1 << 2) /* 4 */
94 #define CS_EQUATION_DIFFUSION (1 << 3) /* 8 */
95 #define CS_EQUATION_CURLCURL (1 << 4) /* 16 */
96 #define CS_EQUATION_GRADDIV (1 << 5) /* 32 */
97 #define CS_EQUATION_REACTION (1 << 6) /* 64 */
98 #define CS_EQUATION_FORCE_VALUES (1 << 7) /* 128 */
99 #define CS_EQUATION_USER_HOOK (1 << 8) /* 256 */
100 
120 #define CS_EQUATION_POST_BALANCE (1 << 0) /* 1 */
121 #define CS_EQUATION_POST_PECLET (1 << 1) /* 2 */
122 #define CS_EQUATION_POST_UPWIND_COEF (1 << 2) /* 4 */
123 #define CS_EQUATION_POST_NORMAL_FLUX (1 << 3) /* 8 */
124 
142 #define CS_EQUATION_ENFORCE_BY_CELLS (1 << 0) /* 1 */
143 #define CS_EQUATION_ENFORCE_BY_DOFS (1 << 1) /* 2 */
144 #define CS_EQUATION_ENFORCE_BY_REFERENCE_VALUE (1 << 2) /* 4 */
145 
148 /*============================================================================
149  * Type definitions
150  *============================================================================*/
151 
180 typedef enum {
181 
189 
191 
193 
194 /*----------------------------------------------------------------------------*/
195 
201 typedef struct {
202 
207  char *restrict name;
209  int dim;
219  union {
221  int iwarni;
222  };
223 
229 
235 
236  /* Numerical settings */
244 
463  int iconv;
464  int istat;
465  int idircl;
466  int ndircl;
467  int idiff;
468  int idifft;
469  int idften;
470  int iswdyn;
471  int ischcv;
472  int ibdtso;
473  int isstpc;
474  int nswrgr;
475  int nswrsm;
476  int imrgra;
477  int imligr;
478  int ircflu;
479  int iwgrec;
480  int icoupl;
481  double thetav; /* TODO: merge with theta */
482  double blencv;
483  double blend_st;
484  double epsilo;
485  double epsrsm;
486  double epsrgr;
487  double climgr;
488  double extrag;
489  double relaxv;
490 
529 
533 
548 
562 
583 
598 
614 
630 
666 
689 
706 
726 
769 
773 
777 
791 
802 
806 
807 /*----------------------------------------------------------------------------*/
808 
1052 typedef enum {
1053 
1081 
1083 
1085 
1086 /*============================================================================
1087  * Static inline public function prototypes
1088  *============================================================================*/
1089 
1090 /*----------------------------------------------------------------------------*/
1097 /*----------------------------------------------------------------------------*/
1098 
1099 static inline void
1100 cs_equation_param_set_flag(cs_equation_param_t *eqp,
1101  cs_flag_t flag)
1102 {
1103  assert(eqp != NULL);
1104  eqp->flag |= flag;
1105 }
1106 
1107 /*----------------------------------------------------------------------------*/
1115 /*----------------------------------------------------------------------------*/
1116 
1117 static inline bool
1118 cs_equation_param_has_diffusion(const cs_equation_param_t *eqp)
1119 {
1120  assert(eqp != NULL);
1121  if (eqp->flag & CS_EQUATION_DIFFUSION)
1122  return true;
1123  else
1124  return false;
1125 }
1126 
1127 /*----------------------------------------------------------------------------*/
1135 /*----------------------------------------------------------------------------*/
1136 
1137 static inline bool
1138 cs_equation_param_has_curlcurl(const cs_equation_param_t *eqp)
1139 {
1140  assert(eqp != NULL);
1141  if (eqp->flag & CS_EQUATION_CURLCURL)
1142  return true;
1143  else
1144  return false;
1145 }
1146 
1147 /*----------------------------------------------------------------------------*/
1155 /*----------------------------------------------------------------------------*/
1156 
1157 static inline bool
1158 cs_equation_param_has_graddiv(const cs_equation_param_t *eqp)
1159 {
1160  assert(eqp != NULL);
1161  if (eqp->flag & CS_EQUATION_GRADDIV)
1162  return true;
1163  else
1164  return false;
1165 }
1166 
1167 /*----------------------------------------------------------------------------*/
1175 /*----------------------------------------------------------------------------*/
1176 
1177 static inline bool
1178 cs_equation_param_has_convection(const cs_equation_param_t *eqp)
1179 {
1180  assert(eqp != NULL);
1181  if (eqp->flag & CS_EQUATION_CONVECTION)
1182  return true;
1183  else
1184  return false;
1185 }
1186 
1187 /*----------------------------------------------------------------------------*/
1195 /*----------------------------------------------------------------------------*/
1196 
1197 static inline bool
1198 cs_equation_param_has_reaction(const cs_equation_param_t *eqp)
1199 {
1200  assert(eqp != NULL);
1201  if (eqp->flag & CS_EQUATION_REACTION)
1202  return true;
1203  else
1204  return false;
1205 }
1206 
1207 /*----------------------------------------------------------------------------*/
1215 /*----------------------------------------------------------------------------*/
1216 
1217 static inline bool
1218 cs_equation_param_has_time(const cs_equation_param_t *eqp)
1219 {
1220  assert(eqp != NULL);
1221  if (eqp->flag & CS_EQUATION_UNSTEADY)
1222  return true;
1223  else
1224  return false;
1225 }
1226 
1227 /*----------------------------------------------------------------------------*/
1235 /*----------------------------------------------------------------------------*/
1236 
1237 static inline bool
1238 cs_equation_param_has_sourceterm(const cs_equation_param_t *eqp)
1239 {
1240  assert(eqp != NULL);
1241  if (eqp->n_source_terms > 0)
1242  return true;
1243  else
1244  return false;
1245 }
1246 
1247 /*----------------------------------------------------------------------------*/
1256 /*----------------------------------------------------------------------------*/
1257 
1258 static inline bool
1259 cs_equation_param_has_internal_enforcement(const cs_equation_param_t *eqp)
1260 {
1261  assert(eqp != NULL);
1262  if (eqp->flag & CS_EQUATION_FORCE_VALUES)
1263  return true;
1264  else
1265  return false;
1266 }
1267 
1268 /*----------------------------------------------------------------------------*/
1277 /*----------------------------------------------------------------------------*/
1278 
1279 static inline bool
1280 cs_equation_param_has_user_hook(const cs_equation_param_t *eqp)
1281 {
1282  assert(eqp != NULL);
1283  if (eqp->flag & CS_EQUATION_USER_HOOK)
1284  return true;
1285  else
1286  return false;
1287 }
1288 
1289 /*----------------------------------------------------------------------------*/
1300 /*----------------------------------------------------------------------------*/
1301 
1302 static inline bool
1303 cs_equation_param_has_name(cs_equation_param_t *eqp,
1304  const char *name)
1305 {
1306  if (eqp == NULL)
1307  return false;
1308  if (eqp->name == NULL)
1309  return false;
1310  if (strcmp(eqp->name, name) == 0)
1311  return true;
1312  else
1313  return false;
1314 }
1315 
1316 /*============================================================================
1317  * Public function prototypes
1318  *============================================================================*/
1319 
1320 /*----------------------------------------------------------------------------*/
1331 /*----------------------------------------------------------------------------*/
1332 
1334 cs_equation_create_param(const char *name,
1335  cs_equation_type_t type,
1336  int dim,
1337  cs_param_bc_type_t default_bc);
1338 
1339 /*----------------------------------------------------------------------------*/
1347 /*----------------------------------------------------------------------------*/
1348 
1349 void
1351  cs_equation_param_t *dst);
1352 
1353 /*----------------------------------------------------------------------------*/
1365 /*----------------------------------------------------------------------------*/
1366 
1367 void
1369 
1370 /*----------------------------------------------------------------------------*/
1378 /*----------------------------------------------------------------------------*/
1379 
1382 
1383 /*----------------------------------------------------------------------------*/
1392 /*----------------------------------------------------------------------------*/
1393 
1394 void
1396  cs_equation_key_t key,
1397  const char *keyval);
1398 
1399 /*----------------------------------------------------------------------------*/
1407 /*----------------------------------------------------------------------------*/
1408 
1409 void
1411 
1412 /*----------------------------------------------------------------------------*/
1419 /*----------------------------------------------------------------------------*/
1420 
1421 void
1423 
1424 /*----------------------------------------------------------------------------*/
1430 /*----------------------------------------------------------------------------*/
1431 
1432 void
1434 
1435 /*----------------------------------------------------------------------------*/
1444 /*----------------------------------------------------------------------------*/
1445 
1446 bool
1448 
1449 /*----------------------------------------------------------------------------*/
1464 /*----------------------------------------------------------------------------*/
1465 
1466 cs_xdef_t *
1468  const char *z_name,
1469  cs_real_t *val);
1470 
1471 /*----------------------------------------------------------------------------*/
1487 /*----------------------------------------------------------------------------*/
1488 
1489 cs_xdef_t *
1491  const char *z_name,
1492  double quantity);
1493 
1494 /*----------------------------------------------------------------------------*/
1509 /*----------------------------------------------------------------------------*/
1510 
1511 cs_xdef_t *
1513  const char *z_name,
1514  cs_analytic_func_t *analytic,
1515  void *input);
1516 
1517 /*----------------------------------------------------------------------------*/
1526 /*----------------------------------------------------------------------------*/
1527 
1528 void
1530  cs_xdef_t *xdef);
1531 
1532 /*----------------------------------------------------------------------------*/
1545 /*----------------------------------------------------------------------------*/
1546 
1547 cs_xdef_t *
1549  const cs_param_bc_type_t bc_type,
1550  const char *z_name,
1551  cs_real_t *values);
1552 
1553 /*----------------------------------------------------------------------------*/
1570 /*----------------------------------------------------------------------------*/
1571 
1572 cs_xdef_t *
1574  const cs_param_bc_type_t bc_type,
1575  const char *z_name,
1576  cs_flag_t loc,
1577  cs_real_t *array,
1578  bool is_owner,
1579  cs_lnum_t *index);
1580 
1581 /*----------------------------------------------------------------------------*/
1596 /*----------------------------------------------------------------------------*/
1597 
1598 cs_xdef_t *
1600  const cs_param_bc_type_t bc_type,
1601  const char *z_name,
1602  cs_analytic_func_t *analytic,
1603  void *input);
1604 
1605 /*----------------------------------------------------------------------------*/
1614 /*----------------------------------------------------------------------------*/
1615 
1616 void
1618  const char *z_name);
1619 
1620 /*----------------------------------------------------------------------------*/
1630 /*----------------------------------------------------------------------------*/
1631 
1632 void
1634  cs_property_t *property);
1635 
1636 /*----------------------------------------------------------------------------*/
1645 /*----------------------------------------------------------------------------*/
1646 
1647 void
1649  cs_property_t *property,
1650  int inversion);
1651 
1652 /*----------------------------------------------------------------------------*/
1660 /*----------------------------------------------------------------------------*/
1661 
1662 void
1664  cs_property_t *property);
1665 
1666 /*----------------------------------------------------------------------------*/
1675 /*----------------------------------------------------------------------------*/
1676 
1677 void
1679  cs_property_t *property);
1680 
1681 /*----------------------------------------------------------------------------*/
1689 /*----------------------------------------------------------------------------*/
1690 
1691 void
1693  cs_adv_field_t *adv_field);
1694 
1695 /*----------------------------------------------------------------------------*/
1702 /*----------------------------------------------------------------------------*/
1703 
1704 void
1706  cs_property_t *property);
1707 
1708 /*----------------------------------------------------------------------------*/
1718 /*----------------------------------------------------------------------------*/
1719 
1720 int
1722  cs_property_t *property);
1723 
1724 /*----------------------------------------------------------------------------*/
1736 /*----------------------------------------------------------------------------*/
1737 
1738 cs_xdef_t *
1740  const char *z_name,
1741  cs_real_t *val);
1742 
1743 /*----------------------------------------------------------------------------*/
1756 /*----------------------------------------------------------------------------*/
1757 
1758 cs_xdef_t *
1760  const char *z_name,
1761  cs_analytic_func_t *func,
1762  void *input);
1763 
1764 /*----------------------------------------------------------------------------*/
1778 /*----------------------------------------------------------------------------*/
1779 
1780 cs_xdef_t *
1782  const char *z_name,
1783  cs_flag_t loc_flag,
1784  cs_dof_func_t *func,
1785  void *input);
1786 
1787 /*----------------------------------------------------------------------------*/
1803 /*----------------------------------------------------------------------------*/
1804 
1805 cs_xdef_t *
1807  const char *z_name,
1808  cs_flag_t loc,
1809  cs_real_t *array,
1810  bool is_owner,
1811  cs_lnum_t *index);
1812 
1813 /*----------------------------------------------------------------------------*/
1825 /*----------------------------------------------------------------------------*/
1826 
1827 cs_xdef_t *
1829  const char *z_name,
1830  double *val);
1831 
1832 /*----------------------------------------------------------------------------*/
1845 /*----------------------------------------------------------------------------*/
1846 
1847 cs_xdef_t *
1849  const char *z_name,
1850  double *quantity);
1851 
1852 /*----------------------------------------------------------------------------*/
1865 /*----------------------------------------------------------------------------*/
1866 
1867 cs_xdef_t *
1869  const char *z_name,
1870  cs_analytic_func_t *func,
1871  void *input);
1872 
1873 /*----------------------------------------------------------------------------*/
1890 /*----------------------------------------------------------------------------*/
1891 
1892 void
1894  cs_lnum_t n_elts,
1895  const cs_lnum_t elt_ids[],
1896  const cs_real_t ref_value[],
1897  const cs_real_t elt_values[]);
1898 
1899 /*----------------------------------------------------------------------------*/
1914 /*----------------------------------------------------------------------------*/
1915 
1916 void
1918  cs_lnum_t n_elts,
1919  const cs_lnum_t elt_ids[],
1920  const cs_real_t ref_value[],
1921  const cs_real_t elt_values[]);
1922 
1923 /*----------------------------------------------------------------------------*/
1924 
1926 
1927 #endif /* __CS_EQUATION_PARAM_H__ */
cs_real_t * enforced_dof_values
Definition: cs_equation_param.h:776
void cs_equation_summary_param(const cs_equation_param_t *eqp)
Summary of a cs_equation_param_t structure.
Definition: cs_equation_param.c:2471
Definition: cs_equation_param.h:1066
cs_hodge_param_t graddiv_hodgep
Definition: cs_equation_param.h:628
cs_adv_field_t * adv_field
Definition: cs_equation_param.h:664
#define restrict
Definition: cs_defs.h:127
int imligr
Definition: cs_equation_param.h:477
Definition: cs_equation_param.h:1055
cs_real_t theta
Definition: cs_equation_param.h:582
Definition: cs_equation_param.h:1071
cs_xdef_t * cs_equation_add_volume_mass_injection_by_qov(cs_equation_param_t *eqp, const char *z_name, double *quantity)
Add a new volume mass injection definition source term by initializing a cs_xdef_t structure...
Definition: cs_equation_param.c:3712
int iwgrec
Definition: cs_equation_param.h:479
Definition: cs_advection_field.h:149
cs_flag_t flag
Definition: cs_equation_param.h:228
int ndircl
Definition: cs_equation_param.h:466
Definition: cs_equation_param.h:1073
cs_flag_t process_flag
Definition: cs_equation_param.h:234
cs_xdef_t ** ic_defs
Definition: cs_equation_param.h:547
cs_param_advection_form_t adv_formulation
Definition: cs_equation_param.h:661
int verbosity
Definition: cs_equation_param.h:220
cs_param_assemble_omp_strategy_t
Definition: cs_param_cdo.h:92
Set of parameters to handle an unsteady convection-diffusion-reaction equation with term sources...
Definition: cs_equation_param.h:201
Definition: cs_equation_param.h:1056
cs_equation_type_t type
Definition: cs_equation_param.h:208
Definition: cs_equation_param.h:1082
#define CS_EQUATION_CURLCURL
The term related to the curl-curl operator is needed.
Definition: cs_equation_param.h:95
cs_xdef_t * cs_equation_add_ic_by_value(cs_equation_param_t *eqp, const char *z_name, cs_real_t *val)
Define the initial condition for the unknown related to this equation This definition can be done on ...
Definition: cs_equation_param.c:2839
cs_param_dof_reduction_t dof_reduction
Definition: cs_equation_param.h:238
Definition: cs_equation_param.h:187
cs_param_bc_enforce_t
Definition: cs_param_types.h:408
cs_param_space_scheme_t space_scheme
Definition: cs_equation_param.h:237
#define BEGIN_C_DECLS
Definition: cs_defs.h:495
cs_real_t * enforcement_ref_value
Definition: cs_equation_param.h:768
cs_real_t upwind_portion
Definition: cs_equation_param.h:663
void cs_equation_enforce_vertex_dofs(cs_equation_param_t *eqp, cs_lnum_t n_elts, const cs_lnum_t elt_ids[], const cs_real_t ref_value[], const cs_real_t elt_values[])
Add an enforcement of the value of degrees of freedom located at mesh vertices. The spatial discretiz...
Definition: cs_equation_param.c:3814
double epsilo
Definition: cs_equation_param.h:484
double epsrgr
Definition: cs_equation_param.h:486
int istat
Definition: cs_equation_param.h:464
int space_poly_degree
Definition: cs_equation_param.h:243
cs_property_t ** reaction_properties
Definition: cs_equation_param.h:688
cs_xdef_t ** volume_mass_injections
Definition: cs_equation_param.h:725
void cs_equation_add_curlcurl(cs_equation_param_t *eqp, cs_property_t *property, int inversion)
Associate a new term related to the curl-curl operator for the equation associated to the given cs_eq...
Definition: cs_equation_param.c:3270
Definition: cs_equation_param.h:1063
int imrgra
Definition: cs_equation_param.h:476
cs_real_t strong_pena_bc_coeff
Definition: cs_equation_param.h:531
Definition: cs_equation_param.h:1061
cs_property_t * curlcurl_property
Definition: cs_equation_param.h:613
cs_xdef_t * cs_equation_add_bc_by_value(cs_equation_param_t *eqp, const cs_param_bc_type_t bc_type, const char *z_name, cs_real_t *values)
Define and initialize a new structure to set a boundary condition related to the given equation struc...
Definition: cs_equation_param.c:3006
Definition: cs_equation_param.h:1059
cs_xdef_t * cs_equation_add_source_term_by_val(cs_equation_param_t *eqp, const char *z_name, cs_real_t *val)
Add a new source term by initializing a cs_xdef_t structure. Case of a definition by a constant value...
Definition: cs_equation_param.c:3440
cs_param_time_scheme_t time_scheme
Definition: cs_equation_param.h:581
#define CS_EQUATION_USER_HOOK
Activate a user hook to get a fine control of the discretization process during the cellwise building...
Definition: cs_equation_param.h:99
Definition: cs_equation_param.h:1067
cs_xdef_t * cs_equation_add_bc_by_array(cs_equation_param_t *eqp, const cs_param_bc_type_t bc_type, const char *z_name, cs_flag_t loc, cs_real_t *array, bool is_owner, cs_lnum_t *index)
Define and initialize a new structure to set a boundary condition related to the given equation struc...
Definition: cs_equation_param.c:3066
double cs_real_t
Floating-point value.
Definition: cs_defs.h:307
#define CS_EQUATION_UNSTEADY
Unsteady term is needed.
Definition: cs_equation_param.h:92
Definition: cs_equation_param.h:1077
cs_property_t * time_property
Definition: cs_equation_param.h:580
cs_real_t weak_pena_bc_coeff
Definition: cs_equation_param.h:532
cs_flag_t enforcement_type
Definition: cs_equation_param.h:767
void cs_equation_param_set_sles(cs_equation_param_t *eqp)
Set parameters for initializing SLES structures used for the resolution of the linear system...
Definition: cs_equation_param.c:2321
Definition: cs_equation_param.h:1079
void cs_equation_add_sliding_condition(cs_equation_param_t *eqp, const char *z_name)
Define and initialize a new structure to set a sliding boundary condition related to the given equati...
Definition: cs_equation_param.c:3203
Definition: cs_equation_param.h:186
void cs_equation_param_clear(cs_equation_param_t *eqp)
Free the contents of a cs_equation_param_t.
Definition: cs_equation_param.c:2181
void cs_equation_param_update_from(const cs_equation_param_t *ref, cs_equation_param_t *dst)
Copy the settings from one cs_equation_param_t structure to another one.
Definition: cs_equation_param.c:2001
Definition: cs_equation_param.h:1080
Definition: cs_equation_param.h:184
cs_param_space_scheme_t
Type of numerical scheme for the discretization in space.
Definition: cs_param_types.h:178
cs_lnum_t * enforced_cell_ids
Definition: cs_equation_param.h:771
bool cs_equation_param_has_robin_bc(const cs_equation_param_t *eqp)
Ask if the parameter settings of the equation has requested the treatment of Robin boundary condition...
Definition: cs_equation_param.c:2808
cs_xdef_t ** source_terms
Definition: cs_equation_param.h:705
int icoupl
Definition: cs_equation_param.h:480
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 compact, void *input, cs_real_t *retval)
Generic function pointer for an analytic function elt_ids is optional. If not NULL, it enables to access in coords at the right location and the same thing to fill retval if compact is set to false.
Definition: cs_param_types.h:93
int n_volume_mass_injections
Definition: cs_equation_param.h:724
#define CS_EQUATION_CONVECTION
Convection term is needed.
Definition: cs_equation_param.h:93
Definition: cs_equation_param.h:1078
cs_real_t * enforced_cell_values
Definition: cs_equation_param.h:772
int iconv
Definition: cs_equation_param.h:463
Definition: cs_equation_param.h:1058
double climgr
Definition: cs_equation_param.h:487
void() cs_dof_func_t(cs_lnum_t n_elts, const cs_lnum_t *elt_ids, bool compact, void *input, cs_real_t *retval)
Generic function pointer for defining a quantity at known locations (cells, faces, edges or vertices) with a function. elt_ids is optional. If not NULL, the function works on a sub-list of elements. Moreover, it enables to fill retval with an indirection if compact is set to false.
Definition: cs_param_types.h:118
double thetav
Definition: cs_equation_param.h:481
int cs_equation_add_reaction(cs_equation_param_t *eqp, cs_property_t *property)
Associate a new term related to the reaction operator for the equation associated to the given cs_equ...
Definition: cs_equation_param.c:3402
cs_lnum_t * enforced_dof_ids
Definition: cs_equation_param.h:775
Definition: cs_equation_param.h:1064
double blend_st
Definition: cs_equation_param.h:483
cs_xdef_t * cs_equation_add_source_term_by_dof_func(cs_equation_param_t *eqp, const char *z_name, cs_flag_t loc_flag, cs_dof_func_t *func, void *input)
Add a new source term by initializing a cs_xdef_t structure. Case of a definition by a DoF function...
Definition: cs_equation_param.c:3543
cs_param_assemble_omp_strategy_t omp_assembly_choice
Definition: cs_equation_param.h:801
Definition: cs_equation_param.h:1069
int dim
Definition: cs_equation_param.h:209
Definition: cs_equation_param.h:1075
Definition: cs_equation_param.h:1054
Definition: cs_equation_param.h:1060
int ircflu
Definition: cs_equation_param.h:478
cs_xdef_t * cs_equation_add_bc_by_analytic(cs_equation_param_t *eqp, const cs_param_bc_type_t bc_type, const char *z_name, cs_analytic_func_t *analytic, void *input)
Define and initialize a new structure to set a boundary condition related to the given equation param...
Definition: cs_equation_param.c:3139
cs_property_t * diffusion_property
Definition: cs_equation_param.h:597
Definition: cs_equation_param.h:1070
double blencv
Definition: cs_equation_param.h:482
int idften
Definition: cs_equation_param.h:469
Definition: cs_equation_param.h:1057
char *restrict name
Definition: cs_equation_param.h:207
cs_property_t * adv_scaling_property
Definition: cs_equation_param.h:665
Definition: cs_equation_param.h:1065
Definition: cs_equation_param.h:1072
cs_xdef_t * cs_equation_add_source_term_by_array(cs_equation_param_t *eqp, const char *z_name, cs_flag_t loc, cs_real_t *array, bool is_owner, cs_lnum_t *index)
Add a new source term by initializing a cs_xdef_t structure. Case of a definition by an array...
Definition: cs_equation_param.c:3603
void cs_equation_add_xdef_bc(cs_equation_param_t *eqp, cs_xdef_t *xdef)
Set a boundary condition from an existing cs_xdef_t structure The lifecycle of the cs_xdef_t structur...
Definition: cs_equation_param.c:2978
int n_ic_defs
Definition: cs_equation_param.h:546
Definition: cs_equation_param.h:183
cs_xdef_t * cs_equation_add_ic_by_qov(cs_equation_param_t *eqp, const char *z_name, double quantity)
Define the initial condition for the unknown related to this equation This definition can be done on ...
Definition: cs_equation_param.c:2887
Structure storing medata for defining a quantity in a very flexible way.
Definition: cs_xdef.h:136
int ischcv
Definition: cs_equation_param.h:471
#define CS_EQUATION_GRADDIV
The term related to the grad-div operator is needed.
Definition: cs_equation_param.h:96
int n_source_terms
Definition: cs_equation_param.h:704
#define CS_EQUATION_FORCE_VALUES
Add an algebraic manipulation to set the value of a given set of interior degrees of freedom...
Definition: cs_equation_param.h:98
int nswrgr
Definition: cs_equation_param.h:474
cs_property_t * graddiv_property
Definition: cs_equation_param.h:629
cs_hodge_param_t curlcurl_hodgep
Definition: cs_equation_param.h:612
int iwarni
Definition: cs_equation_param.h:221
cs_equation_key_t
List of available keys for setting the parameters of an equation.
Definition: cs_equation_param.h:1052
Definition: cs_equation_param.h:182
int idircl
Definition: cs_equation_param.h:465
cs_equation_type_t
Type of equations managed by the solver.
Definition: cs_equation_param.h:180
cs_param_sles_t sles_param
Definition: cs_equation_param.h:790
void cs_equation_add_time(cs_equation_param_t *eqp, cs_property_t *property)
Associate a new term related to the time derivative operator for the equation associated to the given...
Definition: cs_equation_param.c:3327
int isstpc
Definition: cs_equation_param.h:473
void cs_equation_add_advection(cs_equation_param_t *eqp, cs_adv_field_t *adv_field)
Associate a new term related to the advection operator for the equation associated to the given cs_eq...
Definition: cs_equation_param.c:3352
int nswrsm
Definition: cs_equation_param.h:475
Definition: cs_equation_param.h:188
cs_param_bc_enforce_t default_enforcement
Definition: cs_equation_param.h:530
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:301
int n_reaction_terms
Definition: cs_equation_param.h:687
cs_param_advection_scheme_t adv_scheme
Definition: cs_equation_param.h:662
cs_lnum_t n_enforced_dofs
Definition: cs_equation_param.h:774
int iswdyn
Definition: cs_equation_param.h:470
int n_bc_defs
Definition: cs_equation_param.h:527
int ibdtso
Definition: cs_equation_param.h:472
cs_lnum_t n_enforced_cells
Definition: cs_equation_param.h:770
Definition: cs_equation_param.h:190
#define END_C_DECLS
Definition: cs_defs.h:496
cs_xdef_t * cs_equation_add_source_term_by_analytic(cs_equation_param_t *eqp, const char *z_name, cs_analytic_func_t *func, void *input)
Add a new source term by initializing a cs_xdef_t structure. Case of a definition by an analytical fu...
Definition: cs_equation_param.c:3489
unsigned short int cs_flag_t
Definition: cs_defs.h:309
cs_param_dof_reduction_t
Definition: cs_param_types.h:205
cs_param_bc_type_t
Definition: cs_param_types.h:365
double relaxv
Definition: cs_equation_param.h:489
int idifft
Definition: cs_equation_param.h:468
cs_xdef_t * cs_equation_add_ic_by_analytic(cs_equation_param_t *eqp, const char *z_name, cs_analytic_func_t *analytic, void *input)
Define the initial condition for the unknown related to this equation. This definition can be done on...
Definition: cs_equation_param.c:2934
void cs_equation_set_param(cs_equation_param_t *eqp, cs_equation_key_t key, const char *keyval)
Set a parameter attached to a keyname in a cs_equation_param_t structure.
Definition: cs_equation_param.c:2285
cs_xdef_t * cs_equation_add_volume_mass_injection_by_analytic(cs_equation_param_t *eqp, const char *z_name, cs_analytic_func_t *func, void *input)
Add a new volume mass injection definition source term by initializing a cs_xdef_t structure...
Definition: cs_equation_param.c:3760
bool do_lumping
Definition: cs_equation_param.h:561
cs_param_bc_type_t default_bc
Definition: cs_equation_param.h:526
cs_hodge_param_t reaction_hodgep
Definition: cs_equation_param.h:686
cs_xdef_t ** bc_defs
Definition: cs_equation_param.h:528
cs_param_advection_scheme_t
Definition: cs_param_types.h:313
Definition: cs_equation_param.h:1068
cs_equation_param_t * cs_equation_free_param(cs_equation_param_t *eqp)
Free a cs_equation_param_t.
Definition: cs_equation_param.c:2261
Definition: cs_equation_param.h:1076
Definition: cs_equation_param.h:1062
#define CS_EQUATION_REACTION
Reaction term is needed.
Definition: cs_equation_param.h:97
cs_hodge_param_t diffusion_hodgep
Definition: cs_equation_param.h:596
void cs_equation_add_advection_scaling_property(cs_equation_param_t *eqp, cs_property_t *property)
Associate a scaling property to the advection.
Definition: cs_equation_param.c:3376
#define CS_EQUATION_DIFFUSION
Diffusion term is needed. A scalar-/vector-valued Laplacian with div .grad.
Definition: cs_equation_param.h:94
int idiff
Definition: cs_equation_param.h:467
double extrag
Definition: cs_equation_param.h:488
cs_param_time_scheme_t
Definition: cs_param_types.h:237
Definition: cs_equation_param.h:1074
cs_equation_param_t * cs_equation_create_param(const char *name, cs_equation_type_t type, int dim, cs_param_bc_type_t default_bc)
Create a cs_equation_param_t structure.
Definition: cs_equation_param.c:1813
cs_param_advection_form_t
Definition: cs_param_types.h:269
Structure associated to the definition of a property relying on the cs_xdef_t structure.
void cs_equation_param_last_stage(cs_equation_param_t *eqp)
Last modification of the cs_equation_param_t structure before launching the computation.
Definition: cs_equation_param.c:2439
cs_hodge_param_t time_hodgep
Definition: cs_equation_param.h:579
Structure storing all metadata/parameters related to the usage of a discrete Hodge operator...
Definition: cs_hodge.h:165
cs_xdef_t * cs_equation_add_volume_mass_injection_by_value(cs_equation_param_t *eqp, const char *z_name, double *val)
Add a new volume mass injection definition source term by initializing a cs_xdef_t structure...
Definition: cs_equation_param.c:3664
Structure storing all metadata related to the resolution of a linear system with an iterative solver...
Definition: cs_param_types.h:675
void cs_equation_add_diffusion(cs_equation_param_t *eqp, cs_property_t *property)
Associate a new term related to the Laplacian operator for the equation associated to the given cs_eq...
Definition: cs_equation_param.c:3244
double epsrsm
Definition: cs_equation_param.h:485
void cs_equation_add_graddiv(cs_equation_param_t *eqp, cs_property_t *property)
Associate a new term related to the grad-div operator for the equation associated to the given cs_equ...
Definition: cs_equation_param.c:3301
Definition: cs_equation_param.h:185
void cs_equation_enforce_by_cell_selection(cs_equation_param_t *eqp, cs_lnum_t n_elts, const cs_lnum_t elt_ids[], const cs_real_t ref_value[], const cs_real_t elt_values[])
Add an enforcement of the value related to the degrees of freedom associated to the list of selected ...
Definition: cs_equation_param.c:3893