9.1
general documentation
cs_porosity_from_scan.h
Go to the documentation of this file.
1#ifndef __CS_POROSITY_FROM_SCAN_H__
2#define __CS_POROSITY_FROM_SCAN_H__
3
4/*============================================================================
5 * Main for cooling towers related functions
6 *============================================================================*/
7
8/*
9 This file is part of code_saturne, a general-purpose CFD tool.
10
11 Copyright (C) 1998-2025 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 * PLE library headers
32 *----------------------------------------------------------------------------*/
33
34#include <ple_locator.h>
35
36/*----------------------------------------------------------------------------
37 * Local headers
38 *----------------------------------------------------------------------------*/
39
40#include "fvm/fvm_nodal.h"
41
42#include "base/cs_base.h"
43#include "base/cs_halo.h"
44#include "mesh/cs_mesh.h"
46#include "base/cs_restart.h"
47
48/*----------------------------------------------------------------------------*/
49
51
52/*============================================================================
53 * Local Macro definitions
54 *============================================================================*/
55
56/*============================================================================
57 * Type definitions
58 *============================================================================*/
59
60/*============================================================================
61 * Type definitions
62 *============================================================================*/
63
68/*----------------------------------------------------------------------------
69 * Porosity from scan model options descriptor
70 *----------------------------------------------------------------------------*/
71
72typedef enum {
73
77
79
80typedef enum {
81
84
86
87typedef struct {
92 char **headers;
123
124/*============================================================================
125 * Static global variables
126 *============================================================================*/
127
128/* Pointer to options structure */
130
131/*============================================================================
132 * Static global variables
133 *============================================================================*/
134
135/*============================================================================
136 * Public function definitions
137 *============================================================================*/
138
139/*----------------------------------------------------------------------------*/
146/*----------------------------------------------------------------------------*/
147
148void
149cs_porosity_from_scan_set_file_name(const char *file_name);
150
151/*----------------------------------------------------------------------------*/
157/*----------------------------------------------------------------------------*/
158
159void
160cs_porosity_from_scan_set_output_name(const char *output_name);
161
162/*----------------------------------------------------------------------------*/
169/*----------------------------------------------------------------------------*/
170
171void
173 bool transform);
174
175/*----------------------------------------------------------------------------*/
181/*----------------------------------------------------------------------------*/
182
183void
184cs_ibm_add_sources_by_file_name(const char *file_name);
185
186/*----------------------------------------------------------------------------*/
209/*----------------------------------------------------------------------------*/
210
211void
213
214/*----------------------------------------------------------------------------*/
215
216/*--------------------------------------------------------------------*/
217/*
218 * \brief Write the restart file of the ibm module
219 */
220/*--------------------------------------------------------------------*/
221
222void
224
225/*--------------------------------------------------------------------*/
226/*
227 * \brief Write the restart file of the ibm module
228 */
229/*--------------------------------------------------------------------*/
230
231void
233
234/*--------------------------------------------------------------------*/
235/*
236 * \brief Read the restart file of the ibm module
237 */
238/*--------------------------------------------------------------------*/
239
240void
242
243/*--------------------------------------------------------------------*/
244/*
245 * \brief Read the restart file of the ibm module
246 */
247/*--------------------------------------------------------------------*/
248
249void
251
252/*----------------------------------------------------------------------------*/
253
255
256#endif /* __CS_POROSITY_FROM_SCAN_H__ */
#define BEGIN_C_DECLS
Definition: cs_defs.h:554
double cs_real_t
Floating-point value.
Definition: cs_defs.h:357
cs_real_t cs_real_34_t[3][4]
Definition: cs_defs.h:389
cs_real_t cs_real_3_t[3]
vector of 3 floating-point values
Definition: cs_defs.h:374
#define END_C_DECLS
Definition: cs_defs.h:555
cs_real_t cs_real_33_t[3][3]
3x3 matrix of floating-point values
Definition: cs_defs.h:383
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:350
void cs_porous_model_restart_write_stage_1(void)
Write the restart file of the ibm module.
Definition: cs_porosity_from_scan.cpp:1785
cs_porosity_from_scan_opt_t * cs_glob_porosity_from_scan_opt
void cs_porosity_from_scan_set_output_name(const char *output_name)
Set the output name for the FVM writer of scan points.
Definition: cs_porosity_from_scan.cpp:1088
cs_ibm_cog_location_t
Definition: cs_porosity_from_scan.h:72
@ CS_COG_FROM_PYRAMID
Definition: cs_porosity_from_scan.h:75
@ CS_COG_WITHOUT_RECONSTRUCTION_FOR_IBM_PLANE
Definition: cs_porosity_from_scan.h:76
@ CS_COG_FROM_FLUID_FACES
Definition: cs_porosity_from_scan.h:74
void cs_porous_model_restart_read_stage_2(void)
Read the restart file of the ibm module.
Definition: cs_porosity_from_scan.cpp:1939
void cs_ibm_add_sources_by_file_name(const char *file_name)
Add the scanner sources from csv file to fill fluid space.
Definition: cs_porosity_from_scan.cpp:1155
void cs_porosity_from_scan_set_file_name(const char *file_name)
Set the file name of points for the computation of the porosity from scan.
Definition: cs_porosity_from_scan.cpp:1046
cs_fill_type_t
Definition: cs_porosity_from_scan.h:80
@ CS_FILL_DIRECTION
Definition: cs_porosity_from_scan.h:83
@ CS_FILL_RADIAL
Definition: cs_porosity_from_scan.h:82
void cs_porous_model_restart_write_stage_2(void)
Write the restart file of the ibm module for final disable_flag.
Definition: cs_porosity_from_scan.cpp:1828
void cs_porosity_from_scan_add_source(const cs_real_t source[3], bool transform)
Add a scanner source point.
Definition: cs_porosity_from_scan.cpp:1114
void cs_compute_porosity_from_scan(void)
Compute the porosity which is equal to one from a source, radiating sphericaly, and is 0 when touchin...
Definition: cs_porosity_from_scan.cpp:1221
void cs_porous_model_restart_read_stage_1(void)
Read the restart file of the ibm module.
Definition: cs_porosity_from_scan.cpp:1862
struct _cs_restart_t cs_restart_t
Definition: cs_restart.h:95
Definition: cs_porosity_from_scan.h:87
char ** headers
Definition: cs_porosity_from_scan.h:92
bool compute_porosity_from_scan
Definition: cs_porosity_from_scan.h:88
int n_classifications
Definition: cs_porosity_from_scan.h:119
cs_restart_t * restart
Definition: cs_porosity_from_scan.h:120
bool has_classification
Definition: cs_porosity_from_scan.h:116
cs_real_34_t transformation_matrix
Definition: cs_porosity_from_scan.h:99
bool postprocess_points
Definition: cs_porosity_from_scan.h:94
cs_real_3_t direction_vector
Definition: cs_porosity_from_scan.h:102
cs_real_33_t * mom_mat
Definition: cs_porosity_from_scan.h:115
int n_headers
Definition: cs_porosity_from_scan.h:90
bool remove_cells_on_restart
Definition: cs_porosity_from_scan.h:121
int * header_type
Definition: cs_porosity_from_scan.h:91
char * output_name
Definition: cs_porosity_from_scan.h:93
bool use_staircase
Definition: cs_porosity_from_scan.h:111
cs_ibm_cog_location_t cog_location
Definition: cs_porosity_from_scan.h:114
cs_lnum_t n_agglomeration
Definition: cs_porosity_from_scan.h:108
int nb_sources
Definition: cs_porosity_from_scan.h:104
float * classification_values
Definition: cs_porosity_from_scan.h:117
cs_real_t convection_porosity_threshold
Definition: cs_porosity_from_scan.h:110
cs_real_t eigenvalue_criteria
Definition: cs_porosity_from_scan.h:112
cs_lnum_t threshold
Definition: cs_porosity_from_scan.h:107
char * file_names
Definition: cs_porosity_from_scan.h:89
int use_restart
Definition: cs_porosity_from_scan.h:113
cs_real_t porosity_threshold
Definition: cs_porosity_from_scan.h:109
cs_lnum_t * source_c_ids
Definition: cs_porosity_from_scan.h:106
cs_real_3_t * sources
Definition: cs_porosity_from_scan.h:105
bool * class_used
Definition: cs_porosity_from_scan.h:118
cs_fill_type_t type_fill
Definition: cs_porosity_from_scan.h:103