8.1
general documentation
cs_function_default.h
Go to the documentation of this file.
1 #ifndef __CS_FUNCTION_DEFAULT_H__
2 #define __CS_FUNCTION_DEFAULT_H__
3 
4 /*============================================================================
5  * Base predefined function objects.
6  *============================================================================*/
7 
8 /*
9  This file is part of code_saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2023 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_defs.h"
35 #include "cs_function.h"
36 
37 /*----------------------------------------------------------------------------*/
38 
40 
41 /*=============================================================================
42  * Macro definitions
43  *============================================================================*/
44 
45 /*============================================================================
46  * Type definitions
47  *============================================================================*/
48 
51 typedef enum {
52 
57 
58 /*============================================================================
59  * Global variables
60  *============================================================================*/
61 
62 /*=============================================================================
63  * Public function prototypes
64  *============================================================================*/
65 
66 /*----------------------------------------------------------------------------*/
70 /*----------------------------------------------------------------------------*/
71 
72 void
74 
75 /*----------------------------------------------------------------------------*/
84 /*----------------------------------------------------------------------------*/
85 
88 
89 /*----------------------------------------------------------------------------*/
99 /*----------------------------------------------------------------------------*/
100 
103 
104 /*----------------------------------------------------------------------------*/
111 /*----------------------------------------------------------------------------*/
112 
115 
116 /*----------------------------------------------------------------------------*/
123 /*----------------------------------------------------------------------------*/
124 
127 
128 /*----------------------------------------------------------------------------*/
135 /*----------------------------------------------------------------------------*/
136 
139 
140 /*----------------------------------------------------------------------------*/
147 /*----------------------------------------------------------------------------*/
148 
151 
152 /*----------------------------------------------------------------------------*/
159 /*----------------------------------------------------------------------------*/
160 
163 
164 /*----------------------------------------------------------------------------*/
183 /*----------------------------------------------------------------------------*/
184 
185 void
186 cs_function_class_or_zone_id(int location_id,
187  cs_lnum_t n_elts,
188  const cs_lnum_t *elt_ids,
189  void *input,
190  void *vals);
191 
192 /*----------------------------------------------------------------------------*/
206 /*----------------------------------------------------------------------------*/
207 
208 void
209 cs_function_field_boundary_nr(int location_id,
210  cs_lnum_t n_elts,
211  const cs_lnum_t *elt_ids,
212  void *input,
213  void *vals);
214 
215 /*----------------------------------------------------------------------------*/
229 /*----------------------------------------------------------------------------*/
230 
231 void
232 cs_function_boundary_stress(int location_id,
233  cs_lnum_t n_elts,
234  const cs_lnum_t *elt_ids,
235  void *input,
236  void *vals);
237 
238 /*----------------------------------------------------------------------------*/
252 /*----------------------------------------------------------------------------*/
253 
254 void
255 cs_function_boundary_stress_normal(int location_id,
256  cs_lnum_t n_elts,
257  const cs_lnum_t *elt_ids,
258  void *input,
259  void *vals);
260 
261 /*----------------------------------------------------------------------------*/
275 /*----------------------------------------------------------------------------*/
276 
277 void
279  cs_lnum_t n_elts,
280  const cs_lnum_t *elt_ids,
281  void *input,
282  void *vals);
283 
284 /*----------------------------------------------------------------------------*/
291 /*----------------------------------------------------------------------------*/
292 
295 
296 /*----------------------------------------------------------------------------*/
310 /*----------------------------------------------------------------------------*/
311 
312 void
313 cs_function_boundary_thermal_flux(int location_id,
314  cs_lnum_t n_elts,
315  const cs_lnum_t *elt_ids,
316  void *input,
317  void *vals);
318 
319 /*----------------------------------------------------------------------------*/
333 /*----------------------------------------------------------------------------*/
334 
335 void
336 cs_function_boundary_nusselt(int location_id,
337  cs_lnum_t n_elts,
338  const cs_lnum_t *elt_ids,
339  void *input,
340  void *vals);
341 
342 /*----------------------------------------------------------------------------*/
365 /*----------------------------------------------------------------------------*/
366 
367 void
368 cs_function_q_criterion(int location_id,
369  cs_lnum_t n_elts,
370  const cs_lnum_t *elt_ids,
371  void *input,
372  void *vals);
373 
374 /*----------------------------------------------------------------------------*/
375 
377 
378 #endif /* __CS_FUNCTION_DEFAULT_H__ */
#define BEGIN_C_DECLS
Definition: cs_defs.h:514
#define END_C_DECLS
Definition: cs_defs.h:515
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:313
void cs_function_default_define(void)
Define functions based on code_saturne case setup.
Definition: cs_function_default.c:592
cs_function_t * cs_function_define_boundary_stress(void)
Define function object for computation of boundary stress.
Definition: cs_function_default.c:749
void cs_function_q_criterion(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute the Q-criterion from Hunt et. al over each cell of a specified volume region.
Definition: cs_function_default.c:1673
void cs_function_boundary_stress_normal(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute normal stress at boundary.
Definition: cs_function_default.c:1260
cs_function_t * cs_function_define_mpi_rank_id(cs_mesh_location_type_t location_id)
Create or access a function for evaluation of element's MPI rank id.
Definition: cs_function_default.c:631
void cs_function_boundary_thermal_flux(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute thermal flux at boundary (in ),.
Definition: cs_function_default.c:1380
cs_function_t * cs_function_define_boundary_stress_normal(void)
Define function object for computation of normal boundary stress.
Definition: cs_function_default.c:783
cs_function_t * cs_function_define_boundary_stress_tangential(void)
Define function object for computation of tangential boundary stress.
Definition: cs_function_default.c:817
void cs_function_class_or_zone_id(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Extract optional boundary face class of element zone id.
Definition: cs_function_default.c:1007
cs_function_t * cs_function_define_boundary_thermal_flux(void)
Define function object for computation of boundary thermal flux.
Definition: cs_function_default.c:851
void cs_function_boundary_stress(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute stress at boundary.
Definition: cs_function_default.c:1207
cs_function_t * cs_function_define_refinement_generation(cs_mesh_location_type_t location_id)
Create or access a function for evaluation of mesh element's refinement generation (i....
Definition: cs_function_default.c:694
cs_function_t * cs_function_define_boundary_nusselt(void)
Define function for computation of boundary layer Nusselt.
Definition: cs_function_default.c:905
void cs_function_field_boundary_nr(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute non-reconstructed cell-based field values at boundary.
Definition: cs_function_default.c:1057
cs_function_predefined_t
Definition: cs_function_default.h:51
@ CS_FUNCTION_CELL_RANK_ID
Definition: cs_function_default.h:53
@ CS_FUNCTION_B_FACE_RANK_ID
Definition: cs_function_default.h:54
cs_function_t * cs_function_define_q_criterion(void)
Define function for computation of cell Q criterion.
Definition: cs_function_default.c:965
void cs_function_boundary_nusselt(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute local Nusselt number near boundary.
Definition: cs_function_default.c:1449
void cs_function_boundary_stress_tangential(int location_id, cs_lnum_t n_elts, const cs_lnum_t *elt_ids, void *input, void *vals)
Compute tangential stress at boundary.
Definition: cs_function_default.c:1317
cs_mesh_location_type_t
Definition: cs_mesh_location.h:60
Definition: cs_function.h:121