programmer's documentation
cs_reco.h
Go to the documentation of this file.
1 #ifndef __CS_RECO_H__
2 #define __CS_RECO_H__
3 
4 /*============================================================================
5  * Routines to handle the reconstruction of fields
6  *============================================================================*/
7 
8 /*
9  This file is part of Code_Saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2015 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_cdo_quantities.h"
35 #include "cs_cdo_connect.h"
36 
37 /*----------------------------------------------------------------------------*/
38 
40 
41 /*============================================================================
42  * Macro definitions
43  *============================================================================*/
44 
45 /*============================================================================
46  * Type definitions
47  *============================================================================*/
48 
49 /*============================================================================
50  * Public function prototypes
51  *============================================================================*/
52 
53 /*----------------------------------------------------------------------------*/
65 /*----------------------------------------------------------------------------*/
66 
67 void
69  const cs_cdo_quantities_t *quant,
70  const double *dof,
71  double *p_crec[],
72  double *p_frec[]);
73 
74 /*----------------------------------------------------------------------------*/
84 /*----------------------------------------------------------------------------*/
85 
86 void
87 cs_reco_conf_grdc(const cs_cdo_connect_t *connect,
88  const cs_cdo_quantities_t *quant,
89  cs_lnum_t c_id,
90  cs_real_3_t *grdc);
91 
92 /*----------------------------------------------------------------------------*/
103 /*----------------------------------------------------------------------------*/
104 
105 void
107  const cs_connect_index_t *c2v,
108  const cs_cdo_quantities_t *quant,
109  const double *array,
110  cs_real_t *val_xc);
111 
112 /*----------------------------------------------------------------------------*/
124 /*----------------------------------------------------------------------------*/
125 
126 void
128  const cs_connect_index_t *c2e,
129  const cs_cdo_quantities_t *quant,
130  const double *array,
131  cs_real_3_t val_xc);
132 
133 /*----------------------------------------------------------------------------*/
148 /*----------------------------------------------------------------------------*/
149 
150 void
152  cs_lnum_t e_id,
153  const cs_connect_index_t *c2e,
154  const cs_cdo_quantities_t *quant,
155  const double *array,
156  cs_real_3_t val_pec);
157 
158 /*----------------------------------------------------------------------------*/
170 /*----------------------------------------------------------------------------*/
171 
172 void
174  cs_lnum_t e1_id,
175  const cs_connect_index_t *c2e,
176  const cs_cdo_quantities_t *quant,
177  const double *dof,
178  double reco[]);
179 
180 /*----------------------------------------------------------------------------*/
190 /*----------------------------------------------------------------------------*/
191 
192 void
194  const cs_connect_index_t *c2e,
195  const cs_cdo_quantities_t *quant,
196  const double *dof,
197  double reco[]);
198 
199 /*----------------------------------------------------------------------------*/
208 /*----------------------------------------------------------------------------*/
209 
210 void
212  const cs_cdo_quantities_t *quant,
213  const double *dof,
214  double *p_ccrec[]);
215 
216 /*----------------------------------------------------------------------------*/
217 
219 
220 #endif /* __CS_RECO_H__ */
void cs_reco_cost_edge_dof(cs_lnum_t cid, cs_lnum_t e1_id, const cs_connect_index_t *c2e, const cs_cdo_quantities_t *quant, const double *dof, double reco[])
Reconstruct by a constant vector a field of edge-based DoFs in a volume surrounding an edge...
Definition: cs_reco.c:217
Definition: cs_cdo_toolbox.h:82
void cs_reco_conf_vtx_dofs(const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, const double *dof, double *p_crec[], double *p_frec[])
Reconstruct at cell centers and face centers a vertex-based field Linear interpolation. If p_crec and/or p_frec are not allocated, this done in this subroutine.
Definition: cs_reco.c:88
#define BEGIN_C_DECLS
Definition: cs_defs.h:429
Definition: cs_cdo_connect.h:67
void cs_reco_ccen_edge_dof(cs_lnum_t cid, const cs_connect_index_t *c2e, const cs_cdo_quantities_t *quant, const double *dof, double reco[])
Reconstruct at the cell center a field of edge-based DoFs.
Definition: cs_reco.c:442
Definition: cs_cdo_quantities.h:86
void cs_reco_dfbyc_at_cell_center(cs_lnum_t c_id, const cs_connect_index_t *c2e, const cs_cdo_quantities_t *quant, const double *array, cs_real_3_t val_xc)
Reconstruct a constant vector at the cell center from an array of values defined on dual faces lying ...
Definition: cs_reco.c:329
void cs_reco_ccen_edge_dofs(const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, const double *dof, double *p_ccrec[])
Reconstruct at each cell center a field of edge-based DoFs.
Definition: cs_reco.c:487
cs_real_t cs_real_3_t[3]
vector of 3 floating-point values
Definition: cs_defs.h:307
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:292
#define END_C_DECLS
Definition: cs_defs.h:430
double cs_real_t
Definition: cs_defs.h:296
void cs_reco_conf_grdc(const cs_cdo_connect_t *connect, const cs_cdo_quantities_t *quant, cs_lnum_t c_id, cs_real_3_t *grdc)
Compute for each p_{f,c} the value of the gradient of the Lagrange shape function attached to x_c...
Definition: cs_reco.c:170
void cs_reco_pv_at_cell_center(cs_lnum_t c_id, const cs_connect_index_t *c2v, const cs_cdo_quantities_t *quant, const double *array, cs_real_t *val_xc)
Reconstruct the value at the cell center from an array of values defined on primal vertices...
Definition: cs_reco.c:284
void cs_reco_dfbyc_in_pec(cs_lnum_t c_id, cs_lnum_t e_id, const cs_connect_index_t *c2e, const cs_cdo_quantities_t *quant, const double *array, cs_real_3_t val_pec)
Reconstruct a constant vector inside pec which is a volume surrounding the edge e inside the cell c...
Definition: cs_reco.c:379