programmer's documentation
cs_cdofb_priv.h
Go to the documentation of this file.
1 #ifndef __CS_CDOFB_PRIV_H__
2 #define __CS_CDOFB_PRIV_H__
3 
4 /*============================================================================
5  * Definition of cs_cdofb_scaleq_t and cs_cdofb_vecteq structures
6  *============================================================================*/
7 
8 /*
9  This file is part of Code_Saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2018 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_defs.h"
33 #include "cs_hodge.h"
34 #include "cs_cdo_diffusion.h"
35 #include "cs_cdo_advection.h"
36 #include "cs_cdo_time.h"
37 
38 /*----------------------------------------------------------------------------*/
39 
41 
42 /*============================================================================
43  * Macro definitions
44  *============================================================================*/
45 
46 /*============================================================================
47  * Type definitions
48  *============================================================================*/
49 
50 /* Algebraic system for CDO face-based discretization */
51 struct _cs_cdofb_t {
52 
53  /* System size (n_faces + n_cells) */
55 
56  /* Solution of the algebraic system at the last iteration
57  DoF unknowns (x) + BCs */
59 
60  /* Members related to the static condensation */
61  cs_real_t *rc_tilda; /* Acc^-1 * RHS_cell */
62  cs_real_t *acf_tilda; /* Acc^-1 * Acf
63  Cell-faces lower-left block of the full matrix
64  Access to the values thanks to the c2f
65  connectivity */
66 
67  /* Array storing the value arising from the contribution of all source
68  terms (only allocated to n_cells) */
70 
71  /* Pointer of function to build the diffusion term */
76 
77  /* Pointer of function to build the advection term */
80 
81  /* Pointer of function to apply the time scheme */
83 
84 };
85 
86 /*============================================================================
87  * Public function prototypes
88  *============================================================================*/
89 
90 /*----------------------------------------------------------------------------*/
91 
93 
94 #endif /* __CS_CDOFB_PRIV_H__ */
cs_cdo_advection_t * get_advection_matrix
Definition: cs_cdofb_priv.h:78
cs_cdo_time_scheme_t * apply_time_scheme
Definition: cs_cdofb_priv.h:82
cs_real_t * rc_tilda
Definition: cs_cdofb_priv.h:61
#define BEGIN_C_DECLS
Definition: cs_defs.h:461
cs_cdo_diffusion_enforce_dir_t * enforce_dirichlet
Definition: cs_cdofb_priv.h:74
void() cs_cdo_advection_t(const cs_equation_param_t *eqp, const cs_cell_mesh_t *cm, cs_face_mesh_t *fm, cs_cell_builder_t *cb)
Compute the convection operator attached to a cell with a CDO vertex-based scheme. The local matrix related ti this operator is stored in cb->loc.
Definition: cs_cdo_advection.h:67
double cs_real_t
Floating-point value.
Definition: cs_defs.h:297
cs_cdo_advection_bc_t * add_advection_bc
Definition: cs_cdofb_priv.h:79
cs_real_t * source_terms
Definition: cs_cdofb_priv.h:69
cs_lnum_t n_dofs
Definition: cs_cdofb_priv.h:54
cs_cdo_diffusion_flux_trace_t * boundary_flux_op
Definition: cs_cdofb_priv.h:75
cs_real_t * acf_tilda
Definition: cs_cdofb_priv.h:62
cs_hodge_t * get_stiffness_matrix
Definition: cs_cdofb_priv.h:72
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:293
void() cs_cdo_diffusion_enforce_dir_t(const cs_param_hodge_t h_info, const cs_cell_mesh_t *cm, cs_cdo_diffusion_flux_trace_t *flux_op, cs_face_mesh_t *fm, cs_cell_builder_t *cb, cs_cell_sys_t *csys)
Take into account Dirichlet BCs by a weak enforcement using Nitsche technique (symmetrized or not) or...
Definition: cs_cdo_diffusion.h:108
void() cs_hodge_t(const cs_param_hodge_t h_info, const cs_cell_mesh_t *cm, cs_cell_builder_t *cb)
Build a local operator for a given cell (stored in cb->hdg for a discrete Hodge operator or in cb->lo...
Definition: cs_hodge.h:63
#define END_C_DECLS
Definition: cs_defs.h:462
cs_hodge_t * get_diffusion_hodge
Definition: cs_cdofb_priv.h:73
Definition: cs_cdofb_priv.h:51
void() cs_cdo_diffusion_flux_trace_t(const cs_face_mesh_t *fm, const cs_cell_mesh_t *cm, const cs_real_3_t mnu, double beta, cs_cell_builder_t *cb, cs_sdm_t *ntrgrd)
Compute the diffusion flux operator which corresponds to the normal trace operator for a given border...
Definition: cs_cdo_diffusion.h:69
void() cs_cdo_time_scheme_t(const cs_equation_param_t *eqp, const double tpty_val, const cs_sdm_t *mass_mat, const cs_flag_t system_flag, cs_cell_builder_t *cb, cs_cell_sys_t *csys)
Apply the time discretization to a local system.
Definition: cs_cdo_time.h:65
cs_real_t * face_values
Definition: cs_cdofb_priv.h:58
void() cs_cdo_advection_bc_t(const cs_cell_mesh_t *cm, const cs_equation_param_t *eqp, cs_face_mesh_t *fm, cs_cell_builder_t *cb, cs_cell_sys_t *csys)
Compute the BC contribution for the advection operator.
Definition: cs_cdo_advection.h:86