1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | cfMesh: A library for mesh generation
5 \\ / A nd | Author: Franjo Juretic (franjo.juretic@c-fields.com)
6 \\/ M anipulation | Copyright (C) Creative Fields, Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of cfMesh.
11 cfMesh is free software; you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation; either version 3 of the License, or (at your
14 option) any later version.
16 cfMesh 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
21 You should have received a copy of the GNU General Public License
22 along with cfMesh. If not, see <http://www.gnu.org/licenses/>.
28 Decomposes selected cells into pyramids
33 \*---------------------------------------------------------------------------*/
35 #ifndef decomposeCells_H
36 #define decomposeCells_H
38 #include "polyMeshGenModifier.H"
39 #include "VRWGraphList.H"
45 /*---------------------------------------------------------------------------*\
46 Class decomposeCells Declaration
47 \*---------------------------------------------------------------------------*/
52 //- reference to the mesh
55 //- new boundary faces
58 VRWGraph newBoundaryFaces_;
59 labelLongList newBoundaryPatches_;
61 VRWGraphList facesOfNewCells_;
63 // Private member functions
65 //- check if the valid pyramids are generated from the split cells
66 //- this check splits faces which could
67 //- result in multiple inbetween faces
68 void checkFaceConnections(const boolList& decomposeCell);
70 //- create addressing needed to decompose the cell
71 void findAddressingForCell
74 DynList<label, 32>& vrt,
75 DynList<edge, 64>& edges,
76 DynList<DynList<label, 8> >& faceEdges,
77 DynList<DynList<label, 2>, 64>& edgeFaces
80 //- find the apex of the pyramids
84 const DynList<label, 32>& vrt,
85 const DynList<edge, 64>& edges,
86 const DynList<DynList<label, 2>, 64>& edgeFaces
89 void decomposeCellIntoPyramids(const label cellI);
91 void createPointsAndCellFaces(const boolList& decomposeCell);
93 void storeBoundaryFaces(const boolList& decomposeCell);
95 void removeDecomposedCells(const boolList& decomposeCell);
99 //- disallows bitwise construct
100 void operator=(const decomposeCells&);
103 decomposeCells(const decomposeCells&);
108 //- construct from polyMeshGen and a list containing patches
110 decomposeCells(polyMeshGen& mesh);
117 //- perform decomposition of selected cell into pyramids
118 void decomposeMesh(const boolList&);
122 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
124 } // End namespace Foam
126 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
130 // ************************************************************************* //