programmer's documentation
cs_gui_specific_physics.h
Go to the documentation of this file.
1 #ifndef __CS_GUI_SPECIFIC_PHYSICS_H__
2 #define __CS_GUI_SPECIFIC_PHYSICS_H__
3 
4 /*============================================================================
5  * Management of the GUI parameters file: specific physics
6  *============================================================================*/
7 
8 /*
9  This file is part of Code_Saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2016 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 
30 /*----------------------------------------------------------------------------
31  * Local headers
32  *----------------------------------------------------------------------------*/
33 
34 #include "cs_base.h"
35 
36 /*----------------------------------------------------------------------------*/
37 
39 
40 /*============================================================================
41  * Type definitions
42  *============================================================================*/
43 
44 /*============================================================================
45  * Public Fortran function prototypes
46  *============================================================================*/
47 
48 /*----------------------------------------------------------------------------
49  * Density under relaxation
50  *
51  * Fortran Interface:
52  *
53  * SUBROUTINE UICPI1 (SRROM)
54  * *****************
55  * DOUBLE PRECISION SRROM <-- density relaxation
56  * DOUBLE PRECISION DIFTL0 <-- dynamic diffusion
57  *----------------------------------------------------------------------------*/
58 
59 void CS_PROCF (uicpi1, UICPI1) (double *const srrom,
60  double *const diftl0);
61 
62 /*----------------------------------------------------------------------------
63  * Temperature for D3P Gas Combustion
64  *
65  * Fortran Interface:
66  *
67  * SUBROUTINE UICPI2 (SRROM)
68  * *****************
69  * DOUBLE PRECISION Toxy <-- Oxydant temperature
70  * DOUBLE PRECISION Tfuel <-- Fuel temperature
71  *----------------------------------------------------------------------------*/
72 
73 void CS_PROCF (uicpi2, UICPI2) (double *const toxy,
74  double *const tfuel);
75 
76 /*----------------------------------------------------------------------------
77  * Atmospheric flows: read of meteorological file of data
78  *
79  * Fortran Interface:
80  *
81  * subroutine uiati1
82  * *****************
83  * integer imeteo <-- on/off index
84  * char(*) fmeteo <-- meteo file name
85  * int len <-- meteo file name destination string length
86  *----------------------------------------------------------------------------*/
87 
88 void CS_PROCF (uiati1, UIATI1) (int *imeteo,
89  char *fmeteo,
90  int *len
92 
93 
94 /*----------------------------------------------------------------------------
95  * Indirection between the solver numbering and the XML one
96  * for physical properties of the activated specific physics (pulverized solid fuels)
97  *----------------------------------------------------------------------------*/
98 
99 void CS_PROCF (uisofu, UISOFU) (const int *const iirayo,
100  const int *const iihmpr,
101  const int *const ncharm,
102  int *const ncharb,
103  int *const nclpch,
104  int *const nclacp,
105  const int *const ncpcmx,
106  int *const ichcor,
107  double *const diam20,
108  double *const cch,
109  double *const hch,
110  double *const och,
111  double *const nch,
112  double *const sch,
113  int *const ipci,
114  double *const pcich,
115  double *const cp2ch,
116  double *const rho0ch,
117  double *const thcdch,
118  double *const cck,
119  double *const hck,
120  double *const ock,
121  double *const nck,
122  double *const sck,
123  double *const xashch,
124  double *const xashsec,
125  double *const xwatch,
126  double *const h0ashc,
127  double *const cpashc,
128  int *const iy1ch,
129  double *const y1ch,
130  int *const iy2ch,
131  double *const y2ch,
132  double *const a1ch,
133  double *const a2ch,
134  double *const e1ch,
135  double *const e2ch,
136  double *const crepn1,
137  double *const crepn2,
138  double *const ahetch,
139  double *const ehetch,
140  int *const iochet,
141  double *const ahetc2,
142  double *const ehetc2,
143  int *const ioetc2,
144  double *const ahetwt,
145  double *const ehetwt,
146  int *const ioetwt,
147  int *const ieqnox,
148  int *const imdnox,
149  int *const irb,
150  int *const ihtco2,
151  int *const ihth2o,
152  double *const qpr,
153  double *const fn,
154  double *const ckabs1,
155  int *const noxyd,
156  double *const oxyo2,
157  double *const oxyn2,
158  double *const oxyh2o,
159  double *const oxyco2,
160  double *const repnck,
161  double *const repnle,
162  double *const repnlo);
163 
164 /*----------------------------------------------------------------------------
165  * Copy name of thermophysical data file from C to Fortran
166  *----------------------------------------------------------------------------*/
167 
168 void CS_PROCF(cfnmtd, CFNMTD) (char *fstr, /* --> Fortran string */
169  int *len /* --> String Length */
171 
172 
173 /*----------------------------------------------------------------------------
174  * groundwater model : read parameters
175  *
176  * Fortran Interface:
177  *
178  * subroutine uidai1
179  * *****************
180  * integer permeability <-- permeability type
181  * integer dispersion <-- dispersion type
182  * integer unsteady <-- steady flow
183  * integer gravity <-- check if gravity is taken into account
184  *----------------------------------------------------------------------------*/
185 
186 void CS_PROCF (uidai1, UIDAI1) (int *const permeability,
187  int *const dispersion,
188  int *const unsteady,
189  int *const gravity);
190 
191 
192 /*=============================================================================
193  * Public function prototypes
194  *============================================================================*/
195 
196 /*-----------------------------------------------------------------------------
197  * Activate specific physical models based on XML settings.
198  *
199  * parameters:
200  * ieos --> compressible
201  * ieqco2 --> CO2 massic fraction transport (for combustion only)
202  *----------------------------------------------------------------------------*/
203 
204 void
206  cs_int_t *ieqco2);
207 
208 /*----------------------------------------------------------------------------
209  * Electrical model: read parameters
210  *----------------------------------------------------------------------------*/
211 
212 void
213 cs_gui_elec_model(void);
214 
215 /*----------------------------------------------------------------------------
216  * Electrical model: define plane for elreca
217  *----------------------------------------------------------------------------*/
218 
219 void
221 
222 /*-----------------------------------------------------------------------------
223  * Return the name of a thermophysical model.
224  *
225  * parameter:
226  * model_thermo --> thermophysical model
227  *----------------------------------------------------------------------------*/
228 
229 char *
230 cs_gui_get_thermophysical_model(const char *const model_thermo);
231 
232 /*-----------------------------------------------------------------------------
233  * Modify double numerical parameters.
234  *
235  * parameters:
236  * param --> label of the numerical parameter
237  * keyword <--> value of the numerical parameter
238  *----------------------------------------------------------------------------*/
239 
240 void
241 cs_gui_numerical_double_parameters(const char *const param,
242  double *const keyword);
243 
244 /*-----------------------------------------------------------------------------
245  * Return if a predifined physics model is activated.
246  *----------------------------------------------------------------------------*/
247 
248 int
250 
251 /*------------------------------------------------------------------------------
252  * Set GUI-defined labels for the atmospheric module
253  *----------------------------------------------------------------------------*/
254 
255 void
257 
258 /*------------------------------------------------------------------------------
259  * Set GUI-defined labels for the coal combustion module
260  *
261  * parameters:
262  * n_coals <-- number of coals
263  * n_classes <-- number of coal classes
264  *----------------------------------------------------------------------------*/
265 
266 void
268  int n_classes);
269 
270 /*------------------------------------------------------------------------------
271  * Set GUI-defined labels for the electric arcs module
272  *
273  * parameters:
274  * n_gasses <-- number of constituent gasses
275  *----------------------------------------------------------------------------*/
276 
277 void
278 cs_gui_labels_electric_arcs(int n_gasses);
279 
280 /*------------------------------------------------------------------------------
281  * Set GUI-defined labels for the gas combustion variables
282  *----------------------------------------------------------------------------*/
283 
284 void
286 
287 /*------------------------------------------------------------------------------
288  * Set GUI-defined labels for the compressible model variables
289  *----------------------------------------------------------------------------*/
290 
291 void
293 
294 /*----------------------------------------------------------------------------*/
295 
297 
298 #endif /* __CS_GUI_SPECIFIC_PHYSICS_H__ */
void uiati1(int *imeteo, char *fmeteo, int *len CS_ARGF_SUPP_CHAINE)
Definition: cs_gui_specific_physics.c:1598
double precision, dimension(ncharm), save thcdch
Definition: cpincl.f90:99
integer ncharm
maximum number of coals
Definition: ppppar.f90:55
integer, dimension(ncharm), save iy2ch
Definition: cpincl.f90:150
integer, dimension(ncharm), save nclpch
Number of classes per coal.
Definition: cpincl.f90:58
void cs_gui_physical_model_select(cs_int_t *ieos, cs_int_t *ieqco2)
Definition: cs_gui_specific_physics.c:2194
void uisofu(const int *const iirayo, const int *const iihmpr, const int *const ncharm, int *const ncharb, int *const nclpch, int *const nclacp, const int *const ncpcmx, int *const ichcor, double *const diam20, double *const cch, double *const hch, double *const och, double *const nch, double *const sch, int *const ipci, double *const pcich, double *const cp2ch, double *const rho0ch, double *const thcdch, double *const cck, double *const hck, double *const ock, double *const nck, double *const sck, double *const xashch, double *const xashsec, double *const xwatch, double *const h0ashc, double *const cpashc, int *const iy1ch, double *const y1ch, int *const iy2ch, double *const y2ch, double *const a1ch, double *const a2ch, double *const e1ch, double *const e2ch, double *const crepn1, double *const crepn2, double *const ahetch, double *const ehetch, int *const iochet, double *const ahetc2, double *const ehetc2, int *const ioetc2, double *const ahetwt, double *const ehetwt, int *const ioetwt, int *const ieqnox, int *const imdnox, int *const irb, int *const ihtco2, int *const ihth2o, double *const qpr, double *const fn, double *const ckabs1, int *const noxyd, double *const oxyo2, double *const oxyn2, double *const oxyh2o, double *const oxyco2, double *const repnck, double *const repnle, double *const repnlo)
Definition: cs_gui_specific_physics.c:1668
double precision, dimension(ncharm), save cck
Definition: cpincl.f90:99
void cs_gui_elec_model_rec(void)
Definition: cs_gui_specific_physics.c:2494
double precision, dimension(ncharm), save xashsec
Definition: cs_coal_incl.f90:42
double precision, dimension(ncharm), save ahetc2
Definition: cpincl.f90:152
size_t len
Definition: mei_scanner.c:600
double precision, dimension(ncharm), save ehetc2
Definition: cpincl.f90:152
double precision, dimension(ncharm), save ahetwt
Definition: cpincl.f90:152
integer, save ieqco2
Definition: ppcpfu.f90:60
#define BEGIN_C_DECLS
Definition: cs_defs.h:448
double precision, dimension(ncharm), save e1ch
Definition: cpincl.f90:152
int cs_int_t
Fortran-compatible integer.
Definition: cs_defs.h:295
double precision, dimension(ncharm), save a1ch
Definition: cpincl.f90:152
double precision, dimension(ncharm), save h0ashc
Definition: cpincl.f90:99
double precision, dimension(ncharm), save sch
Definition: cpincl.f90:99
double precision, dimension(3), save oxyn2
Definition: ppcpfu.f90:168
void cs_gui_labels_gas_combustion(void)
Definition: cs_gui_specific_physics.c:2827
double precision, dimension(ncharm), save hck
Definition: cpincl.f90:99
double precision, dimension(3), save oxyo2
Definition: ppcpfu.f90:168
double precision, dimension(ncharm), save hch
Definition: cpincl.f90:99
double precision, dimension(3), save oxyco2
Definition: ppcpfu.f90:168
double precision, dimension(ncharm), save cp2ch
Definition: cpincl.f90:99
double precision, dimension(ncharm), save sck
Definition: cpincl.f90:99
#define CS_ARGF_SUPP_CHAINE
Definition: cs_defs.h:487
integer(c_int), pointer, save iirayo
Activation of the radiative transfer module:
Definition: radiat.f90:45
double precision, dimension(ncharm), save e2ch
Definition: cpincl.f90:152
integer(c_int), dimension(:), pointer, save ichcor
Definition: cpincl.f90:195
double precision, dimension(ncharm), save y2ch
Definition: cpincl.f90:152
void cs_gui_labels_compressible(void)
Definition: cs_gui_specific_physics.c:2769
double precision, dimension(ncharm), save nch
Definition: cpincl.f90:99
void cs_gui_elec_model(void)
Definition: cs_gui_specific_physics.c:2334
integer(c_int), pointer, save nclacp
Definition: cpincl.f90:183
integer, save ieqnox
Definition: ppcpfu.f90:95
double precision, dimension(ncharm), save cpashc
Definition: cpincl.f90:99
integer, save ncharb
Number of coals.
Definition: cpincl.f90:51
double precision, dimension(ncharm), save och
Definition: cpincl.f90:99
double precision, dimension(ncharm), save repnck
Definition: cs_coal_incl.f90:79
double precision, dimension(ncharm), save y1ch
Definition: cpincl.f90:152
void uidai1(int *const permeability, int *const dispersion, int *const unsteady, int *const gravity)
Definition: cs_gui_specific_physics.c:2105
real(c_double), pointer, save ckabs1
Absorption coefficient of gas mixture.
Definition: ppthch.f90:150
double precision, dimension(ncharm), save fn
Definition: cs_coal_incl.f90:42
double precision, dimension(ncharm), save cch
Definition: cpincl.f90:99
double precision, dimension(ncharm), save pcich
Definition: cpincl.f90:99
char * cs_gui_get_thermophysical_model(const char *const model_thermo)
Definition: cs_gui_specific_physics.c:2547
void cs_gui_labels_coal_combustion(int n_coals, int n_classes)
Definition: cs_gui_specific_physics.c:2648
void cs_gui_labels_atmospheric(void)
Definition: cs_gui_specific_physics.c:2622
integer ncpcmx
maximum number of coals classes
Definition: ppppar.f90:57
double precision, save diftl0
molecular diffusivity for the enthalpy ( ) for gas or coal combustion (the code then automatically se...
Definition: ppthch.f90:158
integer, dimension(ncharm), save ioetwt
Definition: cpincl.f90:151
integer, save iihmpr
indicator of the use of the GUI (We could avoid this module by querying a C structure) ...
Definition: ihmpre.f90:44
integer, dimension(ncharm), save ioetc2
Definition: cpincl.f90:151
double precision, dimension(2, ncharm), save crepn1
Definition: cpincl.f90:99
integer, save imeteo
imeteo –> flag for reading the meteo input file
Definition: atincl.f90:114
void cfnmtd(char *fstr, int *len CS_ARGF_SUPP_CHAINE)
Definition: cs_gui_specific_physics.c:2047
double precision, dimension(ncharm), save nck
Definition: cpincl.f90:99
double precision, dimension(ncharm), save ock
Definition: cpincl.f90:99
double precision, dimension(ncharm), save ahetch
Definition: cpincl.f90:152
double precision, dimension(ncharm), save repnle
Definition: cs_coal_incl.f90:79
integer, save noxyd
Definition: ppcpfu.f90:161
integer, dimension(ncharm), save ipci
Definition: cs_coal_incl.f90:36
double precision, dimension(ncharm), save xwatch
Definition: cpincl.f90:99
integer, dimension(ncharm), save iochet
Definition: cpincl.f90:151
real(c_double), dimension(:), pointer, save xashch
Definition: cpincl.f90:115
double precision, save srrom
with gas combustion, pulverised coal or the electric module, srrom is the sub-relaxation coefficient ...
Definition: ppincl.f90:701
#define END_C_DECLS
Definition: cs_defs.h:449
integer, save ihtco2
Definition: ppcpfu.f90:64
void cs_gui_numerical_double_parameters(const char *const param, double *const keyword)
Definition: cs_gui.c:5729
#define CS_PROCF(x, y)
Definition: cs_defs.h:472
double precision, dimension(ncharm), save a2ch
Definition: cpincl.f90:152
double precision, dimension(2, ncharm), save crepn2
Definition: cpincl.f90:99
void uicpi2(double *const toxy, double *const tfuel)
Definition: cs_gui_specific_physics.c:1573
integer(c_int), pointer, save ieos
indicates the equation of state for compressible module. Only perfect gas with a constant adiabatic c...
Definition: cstphy.f90:86
double precision, dimension(ncharm), save ehetch
Definition: cpincl.f90:152
integer, dimension(ncharm), save iy1ch
Definition: cpincl.f90:150
void cs_gui_labels_electric_arcs(int n_gasses)
Definition: cs_gui_specific_physics.c:2791
void uicpi1(double *const srrom, double *const diftl0)
Definition: cs_gui_specific_physics.c:1541
integer, save imdnox
Definition: ppcpfu.f90:95
double precision, dimension(ncharm), save qpr
Definition: cs_coal_incl.f90:42
integer, save ihth2o
Definition: cs_coal_incl.f90:36
integer, save irb
Definition: ppcpfu.f90:95
int cs_gui_get_activ_thermophysical_model(void)
Definition: cs_gui_specific_physics.c:2574
double precision, dimension(3), save oxyh2o
Definition: ppcpfu.f90:168
double precision, dimension(ncharm), save ehetwt
Definition: cpincl.f90:152
double precision, dimension(ncharm), save rho0ch
Definition: cpincl.f90:99
double precision, dimension(ncharm), save repnlo
Definition: cs_coal_incl.f90:79
real(c_double), dimension(:), pointer, save diam20
Definition: cpincl.f90:196