1 /*--------------------------------*- C++ -*----------------------------------*\
3 | \\ / F ield | foam-extend: Open Source CFD |
4 | \\ / O peration | Version: 3.2 |
5 | \\ / A nd | Web: http://www.foam-extend.org |
6 | \\/ M anipulation | |
7 \*---------------------------------------------------------------------------*/
13 object snappyHexMeshDict;
15 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
17 // Which of the steps to run
22 // Geometry. Definition of all surfaces. All surfaces are of class
25 // - to specify refinement for any mesh cell intersecting it
26 // - to specify refinement for any mesh cell inside/outside/near
27 // - to 'snap' the mesh boundary to the surface
43 // Settings for the castellatedMesh generation.
44 castellatedMeshControls
47 // Refinement parameters
48 // ~~~~~~~~~~~~~~~~~~~~~
50 // If local number of cells is >= maxLocalCells on any processor
51 // switches from from refinement followed by balancing
52 // (current method) to (weighted) balancing before refinement.
53 maxLocalCells 1000000;
55 // Overall cell limit (approximately). Refinement will stop immediately
56 // upon reaching this number so a refinement level might not complete.
57 // Note that this is the number of cells before removing the part which
58 // is not 'visible' from the keepPoint. The final number of cells might
59 // actually be a lot less.
60 maxGlobalCells 2000000;
62 // The surface refinement loop might spend lots of iterations refining just a
63 // few cells. This setting will cause refinement to stop if <= minimumRefine
64 // are selected for refinement. Note: it will at least do one iteration
65 // (unless the number of cells to refine is 0)
66 minRefinementCells 100;
68 // Number of buffer layers between different levels.
69 // 1 means normal 2:1 refinement restriction, larger means slower
71 nCellsBetweenLevels 6;
73 // Explicit feature edge refinement
74 // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
76 // Specifies a level for any cell intersected by its edges.
77 // This is a featureEdgeMesh, read from constant/triSurface for now.
80 // Surface based refinement
81 // ~~~~~~~~~~~~~~~~~~~~~~~~
83 // Specifies two levels for every surface. The first is the minimum level,
84 // every cell intersecting a surface gets refined up to the minimum level.
85 // The second level is the maximum level. Cells that 'see' multiple
86 // intersections where the intersections make an
87 // angle > resolveFeatureAngle get refined up to the maximum level.
93 // Surface-wise min and max refinement level
98 // Resolve sharp angles on fridges
99 resolveFeatureAngle 30;
101 // Region-wise refinement
102 // ~~~~~~~~~~~~~~~~~~~~~~
104 // Specifies refinement level for cells in relation to a surface. One of
106 // - distance. 'levels' specifies per distance to the surface the
107 // wanted refinement level. The distances need to be specified in
109 // - inside. 'levels' is only one entry and only the level is used. All
110 // cells inside the surface get refined up to the level. The surface
111 // needs to be closed for this to be possible.
112 // - outside. Same but cells outside.
126 // After refinement patches get added for all refinementSurfaces and
127 // all cells intersecting the surfaces get put into these patches. The
128 // section reachable from the locationInMesh is kept.
129 // NOTE: This point should never be on a face, always inside a cell, even
131 locationInMesh (-0.5 0 0);
133 // Whether any faceZones (as specified in the refinementSurfaces)
134 // are only on the boundary of corresponding cellZones or also allow
135 // free-standing zone faces. Not used if there are no faceZones.
136 allowFreeStandingZoneFaces true;
139 // Settings for the snapping.
142 //- Number of patch smoothing iterations before finding correspondence
146 //- Relative distance for points to be attracted by surface feature point
147 // or edge. True distance is this factor times local
148 // maximum edge length.
151 //- Number of mesh displacement relaxation iterations.
154 //- Maximum number of snapping relaxation iterations. Should stop
155 // before upon reaching a correct mesh.
159 // Settings for the layer addition.
162 // Are the thickness parameters below relative to the undistorted
163 // size of the refined cell outside layer (true) or absolute sizes (false).
166 // Per final patch (so not geometry!) the layer information
175 // Expansion factor for layer mesh
178 //- Wanted thickness of final added cell layer. If multiple layers
180 // thickness of the layer furthest away from the wall.
181 // Relative to undistorted size of cell outside layer.
182 // is the thickness of the layer furthest away from the wall.
183 // See relativeSizes parameter.
184 finalLayerThickness 0.7;
186 //- Minimum thickness of cell layer. If for any reason layer
187 // cannot be above minThickness do not add layer.
188 // Relative to undistorted size of cell outside layer.
189 // See relativeSizes parameter.
192 //- If points get not extruded do nGrow layers of connected faces that are
193 // also not grown. This helps convergence of the layer addition process
194 // close to features.
199 //- When not to extrude surface. 0 is flat surface, 90 is when two faces
200 // make straight angle.
203 //- Maximum number of snapping relaxation iterations. Should stop
204 // before upon reaching a correct mesh.
207 // Number of smoothing iterations of surface normals
208 nSmoothSurfaceNormals 1;
210 // Number of smoothing iterations of interior mesh movement direction
213 // Smooth layer thickness over surface patches
216 // Stop layer growth on highly warped cells
217 maxFaceThicknessRatio 0.5;
219 // Reduce layer growth where ratio thickness to medial
221 maxThicknessToMedialRatio 0.3;
223 // Angle used to pick up medial axis points
224 // Note: changed(corrected) w.r.t 16x! 90 degrees corresponds to 130 in 16x.
225 minMedianAxisAngle 90;
227 // Create buffer region for new layer terminations
228 nBufferCellsNoExtrude 0;
230 // Overall max number of layer addition iterations. The mesher will exit
231 // if it reaches this number of iterations; possibly with an illegal
236 // Generic mesh quality settings. At any undoable phase these determine
240 //- Maximum non-orthogonality allowed. Set to 180 to disable.
243 //- Max skewness allowed. Set to <0 to disable.
244 maxBoundarySkewness 20;
245 maxInternalSkewness 4;
247 //- Max concaveness allowed. Is angle (in degrees) below which concavity
248 // is allowed. 0 is straight face, <0 would be convex face.
249 // Set to 180 to disable.
252 //- Minimum pyramid volume. Is absolute volume of cell pyramid.
253 // Set to a sensible fraction of the smallest cell volume expected.
254 // Set to very negative number (e.g. -1E30) to disable.
257 //- Minimum tet volume. Is absolute volume of the tet formed by the
258 // face-centre decomposition triangle and the cell centre.
259 // Set to a sensible fraction of the smallest cell volume expected.
260 // Set to very negative number (e.g. -1E30) to disable.
263 //- Minimum face area. Set to <0 to disable.
266 //- Minimum face twist. Set to <-1 to disable. dot product of face normal
267 //- and face centre triangles normal
270 //- minimum normalised cell determinant
271 //- 1 = hex, <= 0 = folded or flattened illegal cell
272 minDeterminant 0.001;
274 //- minFaceWeight (0 -> 0.5)
277 //- minVolRatio (0 -> 1)
280 //must be >0 for Fluent compatibility
285 //- Number of error distribution iterations
287 //- amount to scale back displacement at error points
293 // Flags for optional output
294 // 0 : only write final meshes
295 // 1 : write intermediate meshes
296 // 2 : write volScalarField with cellLevel for postprocessing
297 // 4 : write current intersections as .obj files
300 // Merge tolerance. Is fraction of overall bounding box of initial mesh.
301 // Note: the write tolerance needs to be higher than this.
304 // ************************************************************************* //