FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

splitMeshRegions.C File Reference

Splits mesh into multiple regions. More...


Detailed Description

Splits mesh into multiple regions.

Each region is defined as a domain whose cells can all be reached by cell-face-cell walking without crossing

  • boundary faces
  • additional faces from faceset (-blockedFaces faceSet).
  • any face inbetween differing cellZones (-cellZones)

Output is:

  • volScalarField with regions as different scalars (-detectOnly) or
  • mesh with multiple regions or
  • mesh with cells put into cellZones (-makeCellZones)
Note:
  • cellZonesOnly does not do a walk and uses the cellZones only. Use this if you don't mind having disconnected domains in a single region. This option requires all cells to be in one (and one only) cellZone.
  • cellZonesFileOnly behaves like -cellZonesOnly but reads the cellZones from the specified file. This allows one to explicitly specify the region distribution and still have multiple cellZones per region.
  • useCellZonesOnly does not do a walk and uses the cellZones only. Use this if you don't mind having disconnected domains in a single region. This option requires all cells to be in one (and one only) cellZone.
  • Should work in parallel. cellZones can differ on either side of processor boundaries in which case the faces get moved from processor patch to directMapped patch. Not very well tested.
  • If a cell zone gets split into more than one region it can detect the largest matching region (-sloppyCellZones). This will accept any region that covers more than 50% of the zone. It has to be a subset so cannot have any cells in any other zone.
  • writes maps like decomposePar back to original mesh:
  • pointRegionAddressing : for every point in this region the point in the original mesh
  • cellRegionAddressing : ,, cell,, cell,,
  • faceRegionAddressing : ,, face,, face in the original mesh + 'turning index'. For a face in the same orientation this is the original facelabel+1, for a turned face this is -facelabel-1
Usage
  • splitMeshRegions [OPTIONS]
Parameters:
-cellZones
Split different cell zones.
-detectOnly
Do no processing.
-blockedFaces<faceSet name>
Split at give face set.
-sloppyCellZones
Try to match regions to existing cell zones.
-makeCellZones
Create mesh with cells in different cell zones.
-overwrite
Overwrite existing data.
-case<dir>
Case directory.
-parallel
Run in parallel.
-help
Display help message.
-doc
Display Doxygen API documentation page for this application.
-srcDoc
Display Doxygen source documentation page for this application.
-insidePoint<point>
Only keep region containing specified point.
-largestOnly
Only keep largest region.

Definition in file splitMeshRegions.C.

#include "src/OpenFOAM/containers/Lists/SortableList/SortableList.H"
#include "src/OpenFOAM/global/argList/argList.H"
#include "src/meshTools/regionSplit/regionSplit.H"
#include "src/finiteVolume/fvMesh/fvMeshSubset/fvMeshSubset.H"
#include "src/OpenFOAM/db/IOobjectList/IOobjectList.H"
#include "src/finiteVolume/fields/volFields/volFields.H"
#include "src/meshTools/sets/topoSets/faceSet.H"
#include "src/meshTools/sets/topoSets/cellSet.H"
#include "src/dynamicMesh/polyTopoChange/polyTopoChange/polyTopoChange.H"
#include "src/dynamicMesh/polyTopoChange/polyTopoChange/removeCells.H"
#include "src/OpenFOAM/meshes/meshShapes/edge/EdgeMap.H"
#include "src/OpenFOAM/meshes/polyMesh/syncTools/syncTools.H"
#include "src/OpenFOAM/fields/ReadFields/ReadFields.H"
#include "src/meshTools/directMapped/directMappedPolyPatch/directMappedWallPolyPatch.H"
#include "src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchFields.H"
#include "src/OpenFOAM/include/setRootCase.H"
#include "src/OpenFOAM/include/createTime.H"
#include "src/OpenFOAM/include/createMesh.H"
Include dependency graph for splitMeshRegions.C:

Go to the source code of this file.