OpenFOAM: API Guide
v2012
The open source CFD toolbox
thresholdCellFaces.H
Go to the documentation of this file.
1
/*---------------------------------------------------------------------------*\
2
========= |
3
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4
\\ / O peration |
5
\\ / A nd | www.openfoam.com
6
\\/ M anipulation |
7
-------------------------------------------------------------------------------
8
Copyright (C) 2011 OpenFOAM Foundation
9
Copyright (C) 2018-2020 OpenCFD Ltd.
10
-------------------------------------------------------------------------------
11
License
12
This file is part of OpenFOAM.
13
14
OpenFOAM is free software: you can redistribute it and/or modify it
15
under the terms of the GNU General Public License as published by
16
the Free Software Foundation, either version 3 of the License, or
17
(at your option) any later version.
18
19
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22
for more details.
23
24
You should have received a copy of the GNU General Public License
25
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26
27
Class
28
Foam::thresholdCellFaces
29
30
Description
31
Selects the mesh cell faces specified by a threshold value.
32
Non-triangulated by default.
33
34
SourceFiles
35
thresholdCellFaces.C
36
37
\*---------------------------------------------------------------------------*/
38
39
#ifndef thresholdCellFaces_H
40
#define thresholdCellFaces_H
41
42
#include "
MeshedSurface.H
"
43
#include "
MeshedSurfacesFwd.H
"
44
45
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47
namespace
Foam
48
{
49
50
// Forward Declarations
51
class
polyMesh;
52
53
/*---------------------------------------------------------------------------*\
54
Class thresholdCellFaces Declaration
55
\*---------------------------------------------------------------------------*/
56
57
class
thresholdCellFaces
58
:
59
public
meshedSurface
60
{
61
// Private typedefs for convenience
62
typedef
meshedSurface
Mesh
;
63
64
65
// Private Data
66
67
//- Reference to mesh
68
const
polyMesh
& mesh_;
69
70
//- For each face, the original cell in mesh
71
labelList
meshCells_;
72
73
74
// Private Member Functions
75
76
void
calculate
77
(
78
const
scalarField
&
field
,
79
const
scalar lowerThreshold,
80
const
scalar upperThreshold,
81
const
bool
triangulate
82
);
83
84
public
:
85
86
//- Runtime type information
87
TypeName
(
"thresholdCellFaces"
);
88
89
90
// Constructors
91
92
//- Construct from mesh, field and threshold values
93
thresholdCellFaces
94
(
95
const
polyMesh
&
mesh
,
96
const
scalarField
&
field
,
97
const
scalar lowerThreshold,
98
const
scalar upperThreshold,
99
const
bool
triangulate
=
false
100
);
101
102
103
// Member Functions
104
105
//- For each face, the original cell in mesh
106
const
labelList
&
meshCells
()
const
107
{
108
return
meshCells_;
109
}
110
111
//- For each face, the original cell in mesh
112
labelList
&
meshCells
()
113
{
114
return
meshCells_;
115
}
116
};
117
118
119
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120
121
}
// End namespace Foam
122
123
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
124
125
126
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
127
128
#endif
129
130
// ************************************************************************* //
Foam::MeshedSurface::triangulate
virtual label triangulate()
Triangulate in-place, returning the number of triangles added.
Definition:
MeshedSurface.C:972
Foam::thresholdCellFaces::thresholdCellFaces
thresholdCellFaces(const polyMesh &mesh, const scalarField &field, const scalar lowerThreshold, const scalar upperThreshold, const bool triangulate=false)
Construct from mesh, field and threshold values.
Definition:
thresholdCellFaces.C:269
Foam::polyMesh
Mesh consisting of general polyhedral cells.
Definition:
polyMesh.H:77
Foam::thresholdCellFaces::TypeName
TypeName("thresholdCellFaces")
Runtime type information.
Foam::Field< scalar >
Foam::thresholdCellFaces::meshCells
labelList & meshCells()
For each face, the original cell in mesh.
Definition:
thresholdCellFaces.H:111
field
rDeltaTY field()
Foam::thresholdCellFaces
Selects the mesh cell faces specified by a threshold value. Non-triangulated by default.
Definition:
thresholdCellFaces.H:56
mesh
dynamicFvMesh & mesh
Definition:
createDynamicFvMesh.H:6
Foam
Namespace for OpenFOAM.
Definition:
atmBoundaryLayer.C:33
Foam::List< label >
Foam::thresholdCellFaces::meshCells
const labelList & meshCells() const
For each face, the original cell in mesh.
Definition:
thresholdCellFaces.H:105
MeshedSurfacesFwd.H
Foam::MeshedSurface< face >
MeshedSurface.H
src
sampling
surface
thresholdCellFaces
thresholdCellFaces.H
Generated by
1.8.17
OPENFOAM® is a registered
trademark
of OpenCFD Ltd.