primitiveMeshI.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 | Copyright (C) 2011 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
11  OpenFOAM is free software: you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
16  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Description
25 
26 \*---------------------------------------------------------------------------*/
27 
28 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
29 
30 namespace Foam
31 {
32 
33 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
34 
36 {
37  return nInternalPoints_;
38 }
39 
40 
42 {
43  return nPoints_;
44 }
45 
46 
48 {
49  // Force edge calculation
50  (void)nEdges();
51  return nInternal0Edges_;
52 }
53 
54 
56 {
57  // Force edge calculation
58  (void)nEdges();
59  return nInternal1Edges_;
60 }
61 
62 
64 {
65  // Force edge calculation
66  (void)nEdges();
67  return nInternalEdges_;
68 }
69 
70 
72 {
73  if (nEdges_ < 0)
74  {
75  nEdges_ = edges().size();
76  }
77 
78  return nEdges_;
79 }
80 
81 
83 {
84  return nInternalFaces_;
85 }
86 
87 
89 {
90  return nFaces_;
91 }
92 
93 
95 {
96  return nCells_;
97 }
98 
99 
100 inline bool primitiveMesh::isInternalFace(const label faceIndex) const
101 {
102  return faceIndex < nInternalFaces();
103 }
104 
105 
106 inline bool primitiveMesh::hasCellShapes() const
107 {
108  return cellShapesPtr_;
109 }
110 
111 
112 inline bool primitiveMesh::hasEdges() const
113 {
114  return edgesPtr_;
115 }
116 
117 
118 inline bool primitiveMesh::hasCellCells() const
119 {
120  return ccPtr_;
121 }
122 
123 
124 inline bool primitiveMesh::hasEdgeCells() const
125 {
126  return ecPtr_;
127 }
128 
129 
130 inline bool primitiveMesh::hasPointCells() const
131 {
132  return pcPtr_;
133 }
134 
135 
136 inline bool primitiveMesh::hasCells() const
137 {
138  return cfPtr_;
139 }
140 
141 
142 inline bool primitiveMesh::hasEdgeFaces() const
143 {
144  return efPtr_;
145 }
146 
147 
148 inline bool primitiveMesh::hasPointFaces() const
149 {
150  return pfPtr_;
151 }
152 
153 
154 inline bool primitiveMesh::hasCellEdges() const
155 {
156  return cePtr_;
157 }
158 
159 
160 inline bool primitiveMesh::hasFaceEdges() const
161 {
162  return fePtr_;
163 }
164 
165 
166 inline bool primitiveMesh::hasPointEdges() const
167 {
168  return pePtr_;
169 }
170 
171 
172 inline bool primitiveMesh::hasPointPoints() const
173 {
174  return ppPtr_;
175 }
176 
177 
178 inline bool primitiveMesh::hasCellPoints() const
179 {
180  return cpPtr_;
181 }
182 
183 
184 inline bool primitiveMesh::hasCellCentres() const
185 {
186  return cellCentresPtr_;
187 }
188 
189 
190 inline bool primitiveMesh::hasFaceCentres() const
191 {
192  return faceCentresPtr_;
193 }
194 
195 
196 inline bool primitiveMesh::hasCellVolumes() const
197 {
198  return cellVolumesPtr_;
199 }
200 
201 
202 inline bool primitiveMesh::hasFaceAreas() const
203 {
204  return faceAreasPtr_;
205 }
206 
207 
208 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
209 
210 } // End namespace Foam
211 
212 // ************************************************************************* //
bool hasEdgeFaces() const
bool hasCellCentres() const
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Definition: label.H:59
bool hasCellPoints() const
label nInternalFaces() const
label nFaces() const
label nInternalPoints() const
Points not on boundary.
void size(const label)
Override size to be inconsistent with allocated storage.
Definition: ListI.H:163
bool hasCellCells() const
label nCells() const
label nInternal0Edges() const
Internal edges (i.e. not on boundary face) using.
bool hasCellShapes() const
bool hasFaceAreas() const
bool hasEdges() const
label nInternal1Edges() const
Internal edges using 0 or 1 boundary point.
bool hasCells() const
bool hasFaceCentres() const
bool hasCellEdges() const
bool isInternalFace(const label faceIndex) const
Return true if given face label is internal to the mesh.
bool hasPointFaces() const
label nEdges() const
const edgeList & edges() const
Return mesh edges. Uses calcEdges.
bool hasEdgeCells() const
bool hasPointPoints() const
label nPoints() const
bool hasCellVolumes() const
bool hasPointEdges() const
label nInternalEdges() const
Internal edges using 0,1 or 2 boundary points.
Namespace for OpenFOAM.
bool hasPointCells() const
bool hasFaceEdges() const