9.0
general documentation
Loading...
Searching...
No Matches
cs_macfb_builder.h
Go to the documentation of this file.
1#ifndef __CS_MACFB_BUILDER_H__
2#define __CS_MACFB_BUILDER_H__
3
4/*============================================================================
5 * Low-level functions and structures used to build the algebraic system with
6 * a cellwise process when MAC-fb schemes are set for the space
7 * discretization
8 *============================================================================*/
9
10/*
11 This file is part of code_saturne, a general-purpose CFD tool.
12
13 Copyright (C) 1998-2025 EDF S.A.
14
15 This program is free software; you can redistribute it and/or modify it under
16 the terms of the GNU General Public License as published by the Free Software
17 Foundation; either version 2 of the License, or (at your option) any later
18 version.
19
20 This program is distributed in the hope that it will be useful, but WITHOUT
21 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
22 FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
23 details.
24
25 You should have received a copy of the GNU General Public License along with
26 this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
27 Street, Fifth Floor, Boston, MA 02110-1301, USA.
28*/
29
30/*----------------------------------------------------------------------------
31 * Local headers
32 *----------------------------------------------------------------------------*/
33
34#include "base/cs_base.h"
35#include "cdo/cs_cdo_connect.h"
36#include "cdo/cs_cdo_local.h"
37#include "cdo/cs_property.h"
38#include "cdo/cs_sdm.h"
39#include "cdo/cs_xdef.h"
40
41/*----------------------------------------------------------------------------*/
42
44
45/*============================================================================
46 * Macro definitions
47 *============================================================================*/
48
49/*============================================================================
50 * Type definitions
51 *============================================================================*/
52
53/* Cellwise builder for MAC-fb discretization */
54typedef struct {
55 /* Cell informations */
56
58
59 short int n_dofs;
60
61 short int n_max_dofs;
62
64
65 /* Face informations */
66
67 short int n_fc;
68
70
72 short int f_sgn_axis[6];
73
76 short int f_opp_idx[6];
78
79 short int f2f_idx[6][4];
83
88
89 short int f2fo_idx[6][4][2];
93
98
100
102
104
105/*============================================================================
106 * Global variables
107 *============================================================================*/
108
109/* Pointer of pointers to global structures */
110
112
113/*============================================================================
114 * Public function prototypes
115 *============================================================================*/
116
117/*----------------------------------------------------------------------------*/
121/*----------------------------------------------------------------------------*/
122
123void
125
126/*----------------------------------------------------------------------------*/
130/*----------------------------------------------------------------------------*/
131
132void
134
135/*----------------------------------------------------------------------------*/
143/*----------------------------------------------------------------------------*/
144
147
148/*----------------------------------------------------------------------------*/
154/*----------------------------------------------------------------------------*/
155
158
159/*----------------------------------------------------------------------------*/
165/*----------------------------------------------------------------------------*/
166
167void
169
170/*----------------------------------------------------------------------------*/
176/*----------------------------------------------------------------------------*/
177
178void
180
181/*----------------------------------------------------------------------------*/
190/*----------------------------------------------------------------------------*/
191
192void
194 const cs_cdo_connect_t *connect,
195 const cs_cdo_quantities_t *quant,
196 cs_macfb_builder_t *macb);
197
198/*----------------------------------------------------------------------------*/
204/*----------------------------------------------------------------------------*/
205
206void
208
209/*----------------------------------------------------------------------------*/
210
212
213#endif /* __CS_MACFB_BUILDER_H__ */
#define BEGIN_C_DECLS
Definition cs_defs.h:542
double cs_real_t
Floating-point value.
Definition cs_defs.h:342
#define END_C_DECLS
Definition cs_defs.h:543
int cs_lnum_t
local mesh entity id
Definition cs_defs.h:335
cs_flag_cartesian_axis_t
Definition cs_flag.h:307
cs_macfb_builder_t ** cs_mac_builders
Definition cs_macfb_builder.cpp:80
void cs_macfb_builder_free(cs_macfb_builder_t **p_builder)
Free a cs_macfb_builder_t structure.
Definition cs_macfb_builder.cpp:210
void cs_macfb_builder_dump(const cs_macfb_builder_t *macb)
Dump a cs_macfb_builder_t structure.
Definition cs_macfb_builder.cpp:532
void cs_macfb_builder_finalize(void)
Free global structures related to cs_macfb_builder_t.
Definition cs_macfb_builder.cpp:157
void cs_macfb_builder_initialize(void)
Allocate global structures used for MAC builder.
Definition cs_macfb_builder.cpp:107
void cs_macfb_builder_reset(cs_macfb_builder_t *macb)
Initialize to invalid values a cs_macfb_builder_t structure.
Definition cs_macfb_builder.cpp:232
cs_macfb_builder_t * cs_macfb_builder_create(void)
Allocate a cs_macfb_builder_t structure.
Definition cs_macfb_builder.cpp:190
void cs_macfb_builder_cellwise_setup(const cs_cell_mesh_t *cm, const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, cs_macfb_builder_t *macb)
Set-up face informations needed to build operators.
Definition cs_macfb_builder.cpp:297
cs_macfb_builder_t * cs_macfb_get_builder(int id)
Get a pointer to a cs_macfb_builder_t structure corresponding to id.
Definition cs_macfb_builder.cpp:275
Definition cs_cdo_connect.h:61
Definition cs_cdo_quantities.h:145
Set of local quantities and connectivities related to a mesh cell.
Definition cs_cdo_local.h:202
Definition cs_macfb_builder.h:54
short int n_dofs
Definition cs_macfb_builder.h:59
cs_real_t f2f_h[6][4]
Definition cs_macfb_builder.h:94
cs_real_t f2f_surf_cv_c[6][4]
Definition cs_macfb_builder.h:96
cs_flag_cartesian_axis_t f_axis[30]
Definition cs_macfb_builder.h:71
short int f_sgn_axis[6]
Definition cs_macfb_builder.h:72
cs_lnum_t dof_ids[30]
Definition cs_macfb_builder.h:63
short int f2f_idx[6][4]
Definition cs_macfb_builder.h:79
cs_lnum_t c_id
Definition cs_macfb_builder.h:57
cs_lnum_t f_ids[30]
Definition cs_macfb_builder.h:69
cs_real_t f_h_cv[6]
Definition cs_macfb_builder.h:75
cs_lnum_t f2f_ids[6][4]
Definition cs_macfb_builder.h:84
short int n_fc
Definition cs_macfb_builder.h:67
short int f_opp_idx[6]
Definition cs_macfb_builder.h:76
cs_lnum_t f2e_ids[6][4]
Definition cs_macfb_builder.h:99
cs_real_t f_vol_cv[6]
Definition cs_macfb_builder.h:74
cs_real_t dir_values[6][4]
Definition cs_macfb_builder.h:101
short int n_max_dofs
Definition cs_macfb_builder.h:61
short int f2fo_idx[6][4][2]
Definition cs_macfb_builder.h:89