programmer's documentation
cs_lagr_roughness.h
Go to the documentation of this file.
1 #ifndef __CS_LAGR_ROUGHNESS_H__
2 #define __CS_LAGR_ROUGHNESS_H__
3 
4 /*============================================================================
5  * Functions and types for the roughness modeling
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  * Local headers
30  *----------------------------------------------------------------------------*/
31 
32 #include "cs_defs.h"
33 #include "cs_lagr_tracking.h"
34 
35 /*----------------------------------------------------------------------------*/
36 
38 
39 /*============================================================================
40  * Type definitions
41  *============================================================================*/
42 
43 typedef struct {
44 
62 
64 
65 /*============================================================================
66  * Public function definitions for Fortran API
67  *============================================================================*/
68 
69 /*----------------------------------------------------------------------------
70  * Clogging initialization:
71  * - Retrieve various parameters for storing in global structure
72  * - Compute and store the Debye screening length
73  *----------------------------------------------------------------------------*/
74 
75 void
76 CS_PROCF (roughness_init, ROUGHNESS_INIT)(const cs_real_t *faraday_cst,
77  const cs_real_t *free_space_permit,
78  const cs_real_t *water_permit,
79  const cs_real_t *ionic_strength,
80  const cs_real_t temperature[],
81  const cs_real_t *valen,
82  const cs_real_t *phi_p,
83  const cs_real_t *phi_s,
84  const cs_real_t *cstham,
85  const cs_real_t *dcutof,
86  const cs_real_t *lambwl,
87  const cs_real_t *kboltz,
88  const cs_real_t *espasg,
89  const cs_real_t *denasp,
90  const cs_real_t *rayasp,
91  const cs_real_t *rayasg
92 );
93 
94 /*=============================================================================
95  * Function definitions
96  *============================================================================*/
97 
98 /*----------------------------------------------------------------------------
99  * Deallocate the arrays storing temperature and Debye length.
100  *----------------------------------------------------------------------------*/
101 
102 void
104 
105 /*----------------------------------------------------------------------------
106  * Compute the energy barrier for a rough wall.
107  *
108  * parameters:
109  * particle <-- pointer to particle data
110  * attr_map <-- pointer to attribute map
111  * face_id <-- id of face neighboring particle
112  * energy_barrier <-> energy barrier
113  *----------------------------------------------------------------------------*/
114 
115 void
116 cs_lagr_roughness_barrier(const void *particle,
117  const cs_lagr_attribute_map_t *attr_map,
118  cs_lnum_t face_id,
119  cs_real_t *energy_barrier);
120 
121 /*----------------------------------------------------------------------------*/
122 
124 
125 #endif /* __CS_LAGR_ROUGHNESS_H__ */
126 
void roughness_init(const cs_real_t *faraday_cst, const cs_real_t *free_space_permit, const cs_real_t *water_permit, const cs_real_t *ionic_strength, const cs_real_t temperature[], const cs_real_t *valen, const cs_real_t *phi_p, const cs_real_t *phi_s, const cs_real_t *cstham, const cs_real_t *dcutof, const cs_real_t *lambwl, const cs_real_t *kboltz, const cs_real_t *espasg, const cs_real_t *denasp, const cs_real_t *rayasp, const cs_real_t *rayasg)
Definition: cs_lagr_roughness.c:107
cs_real_t * temperature
Definition: cs_lagr_roughness.h:51
void cs_lagr_roughness_finalize(void)
Definition: cs_lagr_roughness.c:190
double precision kboltz
Boltzmann constant (J/K)
Definition: lagran.f90:1076
double precision, save cstham
Hamaker constant for the particle/fluid/substrate system.
Definition: lagran.f90:1050
double precision, save denasp
Parameter of the particle resuspension model.
Definition: lagran.f90:310
double precision, save rayasg
Parameter of the particle resuspension model.
Definition: lagran.f90:316
#define BEGIN_C_DECLS
Definition: cs_defs.h:429
cs_real_t rayasp
Definition: cs_lagr_roughness.h:60
cs_real_t phi_p
Definition: cs_lagr_roughness.h:49
cs_real_t denasp
Definition: cs_lagr_roughness.h:59
double precision, save valen
Valency of ions in the solution (used for EDL forces)
Definition: lagran.f90:1062
cs_real_t espasg
Definition: cs_lagr_roughness.h:58
double precision, save phi_p
Electrokinetic potential of the first solid - particle.
Definition: lagran.f90:1056
cs_real_t water_permit
Definition: cs_lagr_roughness.h:47
cs_real_t lambwl
Definition: cs_lagr_roughness.h:56
void cs_lagr_roughness_barrier(const void *particle, const cs_lagr_attribute_map_t *attr_map, cs_lnum_t face_id, cs_real_t *energy_barrier)
Definition: cs_lagr_roughness.c:207
double precision, save rayasp
Parameter of the particle resuspension model.
Definition: lagran.f90:314
cs_real_t rayasg
Definition: cs_lagr_roughness.h:61
double precision lambwl
Characteristic retardation wavelength (m) for Hamaker constant.
Definition: lagran.f90:1084
Definition: cs_lagr_roughness.h:43
double precision, save phi_s
Electrokinetic potential of the second solid - surface.
Definition: lagran.f90:1059
int cs_lnum_t
local mesh entity id
Definition: cs_defs.h:292
cs_real_t dcutof
Definition: cs_lagr_roughness.h:55
#define END_C_DECLS
Definition: cs_defs.h:430
double cs_real_t
Definition: cs_defs.h:296
cs_real_t * debye_length
Definition: cs_lagr_roughness.h:53
double precision dcutof
Cut-off distance for adhesion forces (assumed to be the Born distance) (m)
Definition: lagran.f90:1080
#define CS_PROCF(x, y)
Definition: cs_defs.h:453
double precision, save espasg
Parameter of the particle resuspension model.
Definition: lagran.f90:308
cs_real_t ionic_strength
Definition: cs_lagr_roughness.h:48
cs_real_t valen
Definition: cs_lagr_roughness.h:52
cs_real_t free_space_permit
Definition: cs_lagr_roughness.h:46
Definition: cs_lagr_tracking.h:132
cs_real_t phi_s
Definition: cs_lagr_roughness.h:50
cs_real_t cstham
Definition: cs_lagr_roughness.h:54
cs_real_t kboltz
Definition: cs_lagr_roughness.h:57
cs_real_t faraday_cst
Definition: cs_lagr_roughness.h:45