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 Check whether the meshDict file is set correctly
33 \*---------------------------------------------------------------------------*/
35 #ifndef checkMeshDict_H
36 #define checkMeshDict_H
38 #include "objectRegistry.H"
40 #include "IOdictionary.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
49 /*---------------------------------------------------------------------------*\
50 Class checkMeshDict Declaration
51 \*---------------------------------------------------------------------------*/
55 //- Reference to the mesh
56 IOdictionary& meshDict_;
58 // Private member functions
59 //- check settings for cell size in meshDict
60 void checkBasicSettings() const;
62 //- check patchCellSize entry
63 void checkPatchCellSize() const;
65 //- check subsetCellSize entry
66 void checkSubsetCellSize() const;
68 //- check local refinement level
69 void checkLocalRefinementLevel() const;
71 //- check keepCellsIntersectingPatches entry
72 void checkKeepCellsIntersectingPatches() const;
74 //- check removeCellsIntersectingPatches entry
75 void checkRemoveCellsIntersectingPatches() const;
77 //- check objectRefinements entry
78 void checkObjectRefinements() const;
80 //- check anisotropic sources
81 void checkAnisotropicSources() const;
83 //- check surfaceRefinements entry
84 void checkSurfaceRefinements() const;
86 //- check edgeMeshRefinements entry
87 void checkEdgeMeshRefinements() const;
89 //- check entry for boundary layers
90 void checkBoundaryLayers() const;
92 //- check renameBoundary entry
93 void checkRenameBoundary() const;
95 //- perform all checks
96 void checkEntries() const;
98 //- update patchCellSize entry
99 void updatePatchCellSize(const std::map<word, wordList>&);
101 //- update subsetCellSize entry
102 void updateSubsetCellSize(const std::map<word, wordList>&);
104 //- update local refinement
105 void updateLocalRefinement(const std::map<word, wordList>&);
107 //- check keepCellsIntersectingPatches entry
108 void updateKeepCellsIntersectingPatches
110 const std::map<word, wordList>&
113 //- check removeCellsIntersectingPatches entry
114 void updateRemoveCellsIntersectingPatches
116 const std::map<word, wordList>&
119 //- check objectRefinements entry
120 void updateObjectRefinements(const std::map<word, wordList>&);
122 //- check entry for boundary layers
123 void updateBoundaryLayers(const std::map<word, wordList>&);
125 //- check renameBoundary entry
126 void updateRenameBoundary
128 const std::map<word, wordList>&,
129 const std::map<word, word>&
136 //- Construct from IOdictionary
137 checkMeshDict(IOdictionary& meshDict);
142 // Public member functions
144 //- update meshDict based on modification of patches in the surface
145 void updateDictionaries
147 const std::map<word, wordList>& patchesForPatch,
148 const std::map<word, word>& patchTypes,
149 const bool renamePatches = true
154 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
156 } // End namespace Foam
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
162 // ************************************************************************* //