meshOctreeCreatorCreateOctreeBoxes.C
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | cfMesh: A library for mesh generation
4  \\ / O peration |
5  \\ / A nd | Author: Franjo Juretic (franjo.juretic@c-fields.com)
6  \\/ M anipulation | Copyright (C) Creative Fields, Ltd.
7 -------------------------------------------------------------------------------
8 License
9  This file is part of cfMesh.
10 
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.
15 
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
19  for more details.
20 
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/>.
23 
24 Description
25 
26 \*---------------------------------------------------------------------------*/
27 
28 #include "meshOctreeCreator.H"
29 #include "meshOctreeModifier.H"
30 #include "IOdictionary.H"
31 #include "boundBox.H"
32 #include "triSurf.H"
34 
35 # ifdef USE_OMP
36 #include <omp.h>
37 # endif
38 
39 //#define DEBUGOctree
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 // Private member functions
48 
50 {
51  meshOctreeModifier octreeModifier(octree_);
52  if( octreeModifier.isRootInitialisedAccess() )
53  return;
54  if( !meshDictPtr_ )
55  {
56  WarningIn("void meshOctreeCreator::setRootCubeSizeAndRefParameters()")
57  << "meshDict is not available" << endl;
58  return;
59  }
60 
61  const scalar maxSize
62  (
64  readScalar(meshDictPtr_->lookup("maxCellSize"))
65  );
66 
67  octreeModifier.searchRangeAccess() = 0.25 * maxSize;
68 
69  const triSurf& surface = octree_.surface();
70  boundBox& rootBox = octreeModifier.rootBoxAccess();
71  const point c = (rootBox.max() + rootBox.min()) / 2.0;
72 
73  scalar size = rootBox.max().x() - rootBox.min().x();
74  if( (rootBox.max().y() - rootBox.min().y()) > size )
75  size = rootBox.max().y() - rootBox.min().y();
76  if( (rootBox.max().z() - rootBox.min().z()) > size )
77  size = rootBox.max().z() - rootBox.min().z();
78 
79  size += 0.5 * maxSize;
80 
81  globalRefLevel_ = 0;
82  bool finished;
83  do
84  {
85  finished = false;
86 
87  const scalar lSize = size / Foam::pow(2, label(globalRefLevel_));
88 
89  if( lSize < (maxSize * (1.0-SMALL)) )
90  {
91  const scalar bbSize =
92  0.5 * maxSize * Foam::pow(2, label(globalRefLevel_));
93  rootBox.max() = c + point(bbSize, bbSize, bbSize);
94  rootBox.min() = c - point(bbSize, bbSize, bbSize);
95  finished = true;
96  }
97  else
98  {
100  }
101  } while( !finished );
102 
103  //- exchange data
104  if( Pstream::parRun() )
105  {
107  reduce(l, maxOp<label>());
108  globalRefLevel_ = l;
109  }
110 
111  Info << "Root box " << rootBox << endl;
112  Info << "Requested cell size corresponds to octree level "
113  << label(globalRefLevel_) << endl;
114 
115  octreeModifier.isRootInitialisedAccess() = true;
116 
117  //surfRefLevel_ = globalRefLevel_;
118  forAll(surfRefLevel_, triI)
119  surfRefLevel_[triI].append(std::make_pair(globalRefLevel_, 0.0));
120 
121  //- set other refinement parameters
122  //- set boundary ref level
123  if( meshDictPtr_->found("boundaryCellSize") )
124  {
125  direction boundaryRefLevel_ = globalRefLevel_;
126  scalar cs(readScalar(meshDictPtr_->lookup("boundaryCellSize")));
127  cs *= (scalingFactor_ + SMALL);
128 
129  octreeModifier.searchRangeAccess() = cs;
130 
131  label addLevel(0);
132  do
133  {
134  finished = false;
135 
136  const scalar lSize = maxSize / Foam::pow(2, addLevel);
137 
138  if( lSize <= cs )
139  {
140  finished = true;
141  }
142  else
143  {
144  ++addLevel;
145  }
146  } while( !finished );
147 
148  boundaryRefLevel_ += addLevel;
149 
150  //- exchange data
151  if( Pstream::parRun() )
152  {
153  label l = boundaryRefLevel_;
154  reduce(l, maxOp<label>());
155  boundaryRefLevel_ = l;
156  }
157 
158  Info << "Requested boundary cell size corresponds to octree level "
159  << label(boundaryRefLevel_) << endl;
160 
161  scalar thickness(0.0);
162  if( meshDictPtr_->found("boundaryCellSizeRefinementThickness") )
163  {
164  const scalar s =
165  readScalar
166  (
167  meshDictPtr_->lookup("boundaryCellSizeRefinementThickness")
168  );
169  thickness = mag(s);
170  }
171 
172  forAll(surfRefLevel_, triI)
173  surfRefLevel_[triI][0] =
174  std::make_pair(boundaryRefLevel_, thickness);
175  }
176 
177  //- set patch-wise ref levels
178  if( meshDictPtr_->found("patchCellSize") )
179  {
180  patchRefinementList refPatches;
181 
182  if( meshDictPtr_->isDict("patchCellSize") )
183  {
184  const dictionary& dict = meshDictPtr_->subDict("patchCellSize");
185  const wordList patchNames = dict.toc();
186 
187  const wordList allPatches = surface.patchNames();
188 
189  refPatches.setSize(allPatches.size());
190 
191  label counter(0);
192 
193  forAll(patchNames, patchI)
194  {
195  if( !dict.isDict(patchNames[patchI]) )
196  continue;
197 
198  const dictionary& patchDict = dict.subDict(patchNames[patchI]);
199  const scalar cs = readScalar(patchDict.lookup("cellSize"));
200 
201  labelList matchedIDs = surface.findPatches(patchNames[patchI]);
202  forAll(matchedIDs, matchI)
203  {
204  refPatches[counter] =
205  patchRefinement(allPatches[matchedIDs[matchI]], cs);
206  ++counter;
207  }
208  }
209 
210  refPatches.setSize(counter);
211  }
212  else
213  {
214  patchRefinementList prl(meshDictPtr_->lookup("patchCellSize"));
215  refPatches.transfer(prl);
216  }
217 
218  forAll(refPatches, patchI)
219  {
220  const label regionI = refPatches[patchI].patchInSurface(surface);
221 
222  if( regionI < 0 )
223  continue;
224 
225  scalar cs = refPatches[patchI].cellSize();
226  cs *= (scalingFactor_ + SMALL);
227 
228  label addLevel(0);
229  do
230  {
231  finished = false;
232 
233  const scalar lSize = maxSize / Foam::pow(2, addLevel);
234 
235  if( lSize <= cs )
236  {
237  finished = true;
238  }
239  else
240  {
241  ++addLevel;
242  }
243  } while( !finished );
244 
245  if( Pstream::parRun() )
246  reduce(addLevel, maxOp<label>());
247 
248  const direction level = globalRefLevel_ + addLevel;
249 
250  std::pair<direction, scalar> pp(level, 0.0);
251  forAll(surface, triI)
252  {
253  if( surface[triI].region() == regionI )
254  surfRefLevel_[triI].append(pp);
255  }
256  }
257  }
258 
259  if( meshDictPtr_->found("subsetCellSize") )
260  {
261  patchRefinementList refPatches;
262 
263  if( meshDictPtr_->isDict("subsetCellSize") )
264  {
265  const dictionary& dict = meshDictPtr_->subDict("subsetCellSize");
266  const wordList patchNames = dict.toc();
267 
268  refPatches.setSize(patchNames.size());
269  label counter(0);
270 
271  forAll(patchNames, patchI)
272  {
273  if( !dict.isDict(patchNames[patchI]) )
274  continue;
275 
276  const dictionary& patchDict = dict.subDict(patchNames[patchI]);
277  const scalar cs = readScalar(patchDict.lookup("cellSize"));
278 
279  refPatches[counter] = patchRefinement(patchNames[patchI], cs);
280  ++counter;
281  }
282 
283  refPatches.setSize(counter);
284  }
285  else
286  {
287  patchRefinementList srl(meshDictPtr_->lookup("subsetCellSize"));
288  refPatches.transfer(srl);
289  }
290 
291  forAll(refPatches, patchI)
292  {
293  const word subsetName = refPatches[patchI].patchName();
294 
295  const label subsetID = surface.facetSubsetIndex(subsetName);
296  if( subsetID < 0 )
297  {
298  Warning << "Surface subset " << subsetName
299  << " does not exist" << endl;
300  continue;
301  }
302 
303  scalar cs = refPatches[patchI].cellSize();
304  cs *= (scalingFactor_+ SMALL);
305 
306  label addLevel(0);
307  do
308  {
309  finished = false;
310 
311  const scalar lSize = maxSize / Foam::pow(2, addLevel);
312 
313  if( lSize <= cs )
314  {
315  finished = true;
316  }
317  else
318  {
319  ++addLevel;
320  }
321  } while( !finished );
322 
323  if( Pstream::parRun() )
324  reduce(addLevel, maxOp<label>());
325 
326  labelLongList subsetFaces;
327  surface.facetsInSubset(subsetID, subsetFaces);
328  const direction level = globalRefLevel_ + addLevel;
329 
330  const std::pair<direction, scalar> pp(level, 0.0);
331  forAll(subsetFaces, tI)
332  surfRefLevel_[subsetFaces[tI]].append(pp);
333  }
334  }
335 
336  if( meshDictPtr_->found("localRefinement") )
337  {
338  if( meshDictPtr_->isDict("localRefinement") )
339  {
340  const dictionary& dict = meshDictPtr_->subDict("localRefinement");
341  const wordList entries = dict.toc();
342 
343  //- map patch name to its index
344  std::map<word, label> patchToIndex;
345  forAll(surface.patches(), patchI)
346  patchToIndex[surface.patches()[patchI].name()] = patchI;
347 
348  //- map a facet subset name to its index
349  std::map<word, label> setToIndex;
350  DynList<label> setIDs;
351  surface.facetSubsetIndices(setIDs);
352  forAll(setIDs, i)
353  setToIndex[surface.facetSubsetName(setIDs[i])] = setIDs[i];
354 
355  //- set refinement for these entries
356  forAll(entries, dictI)
357  {
358  if( !dict.isDict(entries[dictI]) )
359  continue;
360 
361  const word& pName = entries[dictI];
362  const dictionary& patchDict = dict.subDict(pName);
363 
364  label nLevel(0);
365 
366  if( patchDict.found("additionalRefinementLevels") )
367  {
368  nLevel =
369  readLabel
370  (
371  patchDict.lookup("additionalRefinementLevels")
372  );
373  }
374  else if( patchDict.found("cellSize") )
375  {
376  const scalar cs =
377  readScalar(patchDict.lookup("cellSize"));
378 
379  do
380  {
381  finished = false;
382 
383  const scalar lSize = maxSize / Foam::pow(2, nLevel);
384 
385  if( lSize <= cs )
386  {
387  finished = true;
388  }
389  else
390  {
391  ++nLevel;
392  }
393  } while( !finished );
394  }
395 
396  scalar refinementThickness(0.0);
397  if( patchDict.found("refinementThickness") )
398  {
399  refinementThickness =
400  readScalar(patchDict.lookup("refinementThickness"));
401  }
402 
403  const direction level = globalRefLevel_ + nLevel;
404 
405  const labelList matchedPatches = surface.findPatches(pName);
406 
407  std::pair<direction, scalar> rp(level, refinementThickness);
408 
409  forAll(matchedPatches, matchI)
410  {
411  //- patch-based refinement
412  const label patchI = matchedPatches[matchI];
413 
414  forAll(surface, triI)
415  {
416  if( surface[triI].region() == patchI )
417  {
418  surfRefLevel_[triI].append(rp);
419  }
420  }
421  }
422  if( setToIndex.find(pName) != setToIndex.end() )
423  {
424  //- this is a facet subset
425  const label subsetId = setToIndex[pName];
426 
427  labelLongList facetsInSubset;
428  surface.facetsInSubset(subsetId, facetsInSubset);
429 
430  forAll(facetsInSubset, i)
431  {
432  const label triI = facetsInSubset[i];
433  surfRefLevel_[triI].append(rp);
434  }
435  }
436  }
437  }
438  }
439 }
440 
442 {
444 
446 }
447 
449 {
450  //- set root cube size in order to achieve desired maxCellSize
451  Info << "Setting root cube size and refinement parameters" << endl;
453 
454  //- refine to required boundary resolution
455  Info << "Refining boundary" << endl;
456  refineBoundary();
457 
458  //- refine parts intersected by surface meshes acting as refinement sources
460 
461  //- refine parts intersected by edge meshes acting as refinement sources
463 
464  //- perform automatic octree refinement
465  if( !Pstream::parRun() )
466  {
467  Info << "Performing automatic refinement" << endl;
469 
470  if( hexRefinement_ )
471  autoRef.activateHexRefinement();
472 
473  autoRef.automaticRefinement();
474  }
475 
476  //- set up inside-outside information
478 
479  //- refine INSIDE and UNKNOWN boxes to to the given cell size
481 
482  //- refine boxes inside the geometry objects
484 
485  //- make sure that INSIDE and UNKNOWN neighbours of DATA boxes
486  //- have the same or higher refinement level
488 
489  //- distribute octree such that each processor has the same number
490  //- of leaf boxes which will be used as mesh cells
491  if( Pstream::parRun() )
492  {
493  loadDistribution(true);
494  }
495 }
496 
498 (
499  const direction maxLevel,
500  const label nTrianglesInLeaf
501 )
502 {
503  const triSurf& surface = octree_.surface();
504  surface.facetEdges();
505  surface.edgeFacets();
506  const boundBox& rootBox = octree_.rootBox();
507  meshOctreeModifier octreeModifier(octree_);
508  List<meshOctreeSlot>& slots = octreeModifier.dataSlotsAccess();
509 
510  while( true )
511  {
512  const LongList<meshOctreeCube*>& leaves =
513  octreeModifier.leavesAccess();
514 
515  label nMarked(0);
516 
517  # ifdef USE_OMP
518  # pragma omp parallel reduction(+ : nMarked)
519  # endif
520  {
521  # ifdef USE_OMP
522  meshOctreeSlot* slotPtr = &slots[omp_get_thread_num()];
523  # else
524  meshOctreeSlot* slotPtr = &slots[0];
525  # endif
526 
527  # ifdef USE_OMP
528  # pragma omp for schedule(dynamic, 20)
529  # endif
530  forAll(leaves, leafI)
531  {
532  meshOctreeCube& oc = *leaves[leafI];
533 
534  DynList<label> ct;
535  octree_.containedTriangles(leafI, ct);
536 
537  if( (oc.level() < maxLevel) && (ct.size() > nTrianglesInLeaf) )
538  {
539  oc.refineCube(surface, rootBox, slotPtr);
540  ++nMarked;
541  }
542  }
543  }
544 
545  if( nMarked == 0 )
546  break;
547 
548  octreeModifier.createListOfLeaves();
549 
550  }
551 }
552 
553 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
554 
555 } // End namespace Foam
556 
557 // ************************************************************************* //
Foam::meshOctreeAutomaticRefinement
Definition: meshOctreeAutomaticRefinement.H:56
Foam::meshOctreeCreator::refineBoxesIntersectingSurfaces
void refineBoxesIntersectingSurfaces()
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:421
Foam::surface::surface
surface(const surface &)
Disallow default bitwise copy construct.
Foam::maxOp
Definition: ops.H:172
Foam::meshOctreeModifier::searchRangeAccess
scalar & searchRangeAccess()
return search range
Definition: meshOctreeModifierI.H:56
triSurf.H
Foam::word
A class for handling words, derived from string.
Definition: word.H:59
Foam::boundBox::max
const point & max() const
Maximum describing the bounding box.
Definition: boundBoxI.H:60
Foam::meshOctreeCreator::scalingFactor_
scalar scalingFactor_
Scaling factor.
Definition: meshOctreeCreator.H:66
forAll
#define forAll(list, i)
Loop across all elements in list.
Definition: UList.H:406
Foam::meshOctreeCube::refineCube
void refineCube(const triSurf &, const boundBox &, meshOctreeSlot *slotPtr=NULL)
subdivide the octree cube
Definition: meshOctreeCubeRefine.C:223
Foam::meshOctreeModifier::rootBoxAccess
boundBox & rootBoxAccess()
return rootBox
Definition: meshOctreeModifierI.H:46
Foam::meshOctreeCreator::setRootCubeSizeAndRefParameters
void setRootCubeSizeAndRefParameters()
set the boundBox such that maxCellSize is achieved
Definition: meshOctreeCreatorCreateOctreeBoxes.C:49
Foam::Warning
messageStream Warning
Foam::UPstream::parRun
static bool & parRun()
Is this a parallel run?
Definition: UPstream.H:377
Foam::dictionary::lookup
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
Definition: dictionary.C:449
Foam::List::transfer
void transfer(List< T > &)
Transfer the contents of the argument List into this list.
Foam::endl
Ostream & endl(Ostream &os)
Add newline and flush stream.
Definition: Ostream.H:251
Foam::meshOctreeCreator::refineInsideAndUnknownBoxes
void refineInsideAndUnknownBoxes()
Definition: meshOctreeCreatorCreateOctreeBoxes.C:441
Foam::meshOctreeModifier::dataSlotsAccess
List< meshOctreeSlot > & dataSlotsAccess()
return octree slots
Definition: meshOctreeModifierI.H:72
Foam::mag
dimensioned< scalar > mag(const dimensioned< Type > &)
Foam::meshOctreeCubeBasic::UNKNOWN
@ UNKNOWN
Definition: meshOctreeCubeBasic.H:88
Foam::dictionary::isDict
bool isDict(const word &) const
Check if entry is a sub-dictionary.
Definition: dictionary.C:600
Foam::meshOctreeModifier
Definition: meshOctreeModifier.H:48
meshOctreeModifier.H
meshOctreeAutomaticRefinement.H
Foam::meshOctreeSlot
Definition: meshOctreeSlot.H:50
Foam::LongList< label >
Foam::meshOctreeCreator::refineBoxes
void refineBoxes(const direction refLevel, const direction cubeType)
refine boxes of the given flag to the given size
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:1135
Foam::meshOctreeCreator::createInsideOutsideInformation
void createInsideOutsideInformation()
Definition: meshOctreeCreatorFrontalMarking.C:40
Foam::patchRefinement
Definition: patchRefinement.H:55
Foam::reduce
void reduce(const List< UPstream::commsStruct > &comms, T &Value, const BinaryOp &bop, const int tag, const label comm)
Definition: PstreamReduceOps.H:43
Foam::meshOctreeCreator::octree_
meshOctree & octree_
Reference to meshOctree.
Definition: meshOctreeCreator.H:63
Foam::label
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
Foam::dictionary::found
bool found(const word &, bool recursive=false, bool patternMatch=true) const
Search dictionary for given keyword.
Definition: dictionary.C:304
Foam::Info
messageStream Info
Foam::meshOctreeCreator::refineBoxesNearDataBoxes
void refineBoxesNearDataBoxes(const label nLayers=1)
refine boxes near DATA boxes to get a nice smooth surface
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:871
Foam::meshOctreeCreator::createOctreeWithRefinedBoundary
void createOctreeWithRefinedBoundary(const direction maxLevel, const label nTrianglesInLeaf=15)
Definition: meshOctreeCreatorCreateOctreeBoxes.C:498
patchNames
wordList patchNames(nPatches)
Foam::meshOctreeCreator::createOctreeBoxes
void createOctreeBoxes()
create octree boxes
Definition: meshOctreeCreatorCreateOctreeBoxes.C:448
Foam::boundBox::min
const point & min() const
Minimum describing the bounding box.
Definition: boundBoxI.H:54
Foam::pow
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
Definition: dimensionedScalar.C:73
dict
dictionary dict
Definition: searchingEngine.H:14
Foam::Vector::x
const Cmpt & x() const
Definition: VectorI.H:65
Foam::meshOctreeModifier::isRootInitialisedAccess
bool & isRootInitialisedAccess()
return isRootInitialised_
Definition: meshOctreeModifierI.H:51
Foam::dictionary
A list of keyword definitions, which are a keyword followed by any number of values (e....
Definition: dictionary.H:137
Foam::meshOctreeCreator::globalRefLevel_
direction globalRefLevel_
ref level to achieve max cell size
Definition: meshOctreeCreator.H:108
Foam::geometryBase::name
const word & name() const
Return the name.
Definition: geometryBase.C:124
Foam
Namespace for OpenFOAM.
Definition: combustionModel.C:30
Foam::Vector::z
const Cmpt & z() const
Definition: VectorI.H:77
Foam::meshOctreeCreator::loadDistribution
void loadDistribution(const bool distributeUsed=false)
Definition: meshOctreeCreatorLoadDistribution.C:46
s
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
Foam::DynList< label >
Foam::meshOctreeCubeBasic::INSIDE
@ INSIDE
Definition: meshOctreeCubeBasic.H:91
Foam::meshOctreeCreator::surfRefLevel_
List< DynList< std::pair< direction, scalar > > > surfRefLevel_
this list contains ref level for each surface triangle
Definition: meshOctreeCreator.H:111
boundBox.H
IOdictionary.H
Foam::List::setSize
void setSize(const label)
Reset size of List.
Foam::meshOctreeCreator::meshDictPtr_
const IOdictionary * meshDictPtr_
Dictionary containing information necessary to perform refinement.
Definition: meshOctreeCreator.H:69
Foam::meshOctreeCubeCoordinates::level
direction level() const
return level
Definition: meshOctreeCubeCoordinatesI.H:74
Foam::readScalar
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if succesful.
Definition: doubleScalar.H:63
Foam::Vector< scalar >
Foam::List
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Definition: HashTable.H:59
Foam::meshOctreeAutomaticRefinement::activateHexRefinement
void activateHexRefinement()
activate hex refinement
Definition: meshOctreeAutomaticRefinementRef.C:60
Foam::meshOctreeCreator::refineBoxesIntersectingEdgeMeshes
void refineBoxesIntersectingEdgeMeshes()
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:652
Foam::meshOctreeCube
Definition: meshOctreeCube.H:56
Foam::surface
Definition: surface.H:55
Foam::readLabel
label readLabel(Istream &is)
Definition: label.H:64
Foam::direction
unsigned char direction
Definition: direction.H:43
Foam::boundBox
A bounding box defined in terms of the points at its extremities.
Definition: boundBox.H:55
Foam::constant::universal::c
const dimensionedScalar c
Speed of light in a vacuum.
Foam::meshOctreeCreator::refineBoxesContainedInObjects
void refineBoxesContainedInObjects()
refine boxes contained inside the objects for refinement
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:196
Foam::Vector::y
const Cmpt & y() const
Definition: VectorI.H:71
Foam::DynList::size
label size() const
Definition: DynListI.H:235
WarningIn
#define WarningIn(functionName)
Report a warning using Foam::Warning.
Definition: messageStream.H:254
meshOctreeCreator.H
Foam::List::size
void size(const label)
Override size to be inconsistent with allocated storage.
Foam::meshOctreeCreator::refineBoundary
void refineBoundary()
Definition: meshOctreeCreatorAdjustOctreeToSurface.C:57
Foam::point
vector point
Point is a vector.
Definition: point.H:41
Foam::meshOctree::surface
const triSurf & surface() const
return a reference to the surface
Definition: meshOctreeI.H:130
Foam::dictionary::subDict
const dictionary & subDict(const word &) const
Find and return a sub-dictionary.
Definition: dictionary.C:631
Foam::triSurf
Definition: triSurf.H:59
Foam::meshOctreeCreator::hexRefinement_
bool hexRefinement_
hex refinement flag
Definition: meshOctreeCreator.H:72
Foam::meshOctreeAutomaticRefinement::automaticRefinement
void automaticRefinement()
Definition: meshOctreeAutomaticRefinementRef.C:65
Foam::meshOctreeModifier::createListOfLeaves
void createListOfLeaves()
create leaves
Definition: meshOctreeModifierI.H:100
Foam::meshOctreeModifier::leavesAccess
LongList< meshOctreeCube * > & leavesAccess()
return leaves
Definition: meshOctreeModifierI.H:95