Selects a section of mesh based on a cellSet. More...
Go to the source code of this file.
Functions | |
labelList | nearestPatch (const polyMesh &mesh, const labelList &patchIDs) |
template<class Type > | |
void | subsetVolFields (const fvMeshSubset &subsetter, const wordList &fieldNames, PtrList< GeometricField< Type, fvPatchField, volMesh > > &subFields) |
template<class Type > | |
void | subsetSurfaceFields (const fvMeshSubset &subsetter, const wordList &fieldNames, PtrList< GeometricField< Type, fvsPatchField, surfaceMesh > > &subFields) |
template<class Type > | |
void | subsetPointFields (const fvMeshSubset &subsetter, const pointMesh &pMesh, const wordList &fieldNames, PtrList< GeometricField< Type, pointPatchField, pointMesh > > &subFields) |
template<class Type > | |
void | subsetDimensionedFields (const fvMeshSubset &subsetter, const wordList &fieldNames, PtrList< DimensionedField< Type, volMesh > > &subFields) |
int | main (int argc, char *argv[]) |
Selects a section of mesh based on a cellSet.
Original source file subsetMesh.C
The utility sub-sets the mesh to choose only a part of interest. Check the setSet/cellSet/topoSet utilities to see how to select cells based on various shapes.
The mesh will subset all points, faces and cells needed to make a sub-mesh but will not preserve attached boundary types.
Definition in file subsetMesh.C.
Definition at line 48 of file subsetMesh.C.
References polyMesh::boundaryMesh(), FaceCellWave< Type, TrackingData >::data(), Foam::endl(), primitiveMesh::faceCentres(), forAll, polyMesh::globalData(), mesh, primitiveMesh::nCells(), primitiveMesh::nFaces(), globalMeshData::nTotalCells(), patchFaces(), polyPatch::start(), and WarningInFunction.
Referenced by main(), meshRefinement::markFacesOnProblemCells(), and meshRefinement::markFacesOnProblemCellsGeometric().
void subsetVolFields | ( | const fvMeshSubset & | subsetter, |
const wordList & | fieldNames, | ||
PtrList< GeometricField< Type, fvPatchField, volMesh > > & | subFields | ||
) |
Definition at line 124 of file subsetMesh.C.
References fvMeshSubset::baseMesh(), Foam::endl(), Foam::fieldNames(), fld(), forAll, Foam::Info, fvMeshSubset::interpolate(), IOobject::MUST_READ, IOobject::NO_WRITE, fvMesh::time(), and Time::timeName().
Referenced by main().
void subsetSurfaceFields | ( | const fvMeshSubset & | subsetter, |
const wordList & | fieldNames, | ||
PtrList< GeometricField< Type, fvsPatchField, surfaceMesh > > & | subFields | ||
) |
Definition at line 158 of file subsetMesh.C.
References fvMeshSubset::baseMesh(), Foam::endl(), Foam::fieldNames(), fld(), forAll, Foam::Info, fvMeshSubset::interpolate(), IOobject::MUST_READ, IOobject::NO_WRITE, fvMesh::time(), and Time::timeName().
Referenced by main().
void subsetPointFields | ( | const fvMeshSubset & | subsetter, |
const pointMesh & | pMesh, | ||
const wordList & | fieldNames, | ||
PtrList< GeometricField< Type, pointPatchField, pointMesh > > & | subFields | ||
) |
Definition at line 192 of file subsetMesh.C.
References fvMeshSubset::baseMesh(), Foam::endl(), Foam::fieldNames(), fld(), forAll, Foam::Info, fvMeshSubset::interpolate(), IOobject::MUST_READ, IOobject::NO_WRITE, fvMesh::time(), and Time::timeName().
Referenced by main().
void subsetDimensionedFields | ( | const fvMeshSubset & | subsetter, |
const wordList & | fieldNames, | ||
PtrList< DimensionedField< Type, volMesh > > & | subFields | ||
) |
Definition at line 227 of file subsetMesh.C.
References fvMeshSubset::baseMesh(), Foam::endl(), Foam::fieldNames(), fld(), forAll, Foam::Info, fvMeshSubset::interpolate(), IOobject::MUST_READ, IOobject::NO_WRITE, fvMesh::time(), and Time::timeName().
Referenced by main().
int main | ( | int | argc, |
char * | argv[] | ||
) |
Definition at line 260 of file subsetMesh.C.
References argList::addNote(), argList::addOption(), args, polyMesh::boundaryMesh(), polyMesh::defaultRegion, Foam::endl(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, polyBoundaryMesh::findPatchID(), forAll, forAllConstIter(), fvMeshSubset::getExposedFaces(), Foam::Info, mesh, IOobjectList::names(), polyBoundaryMesh::names(), primitiveMesh::nCells(), nearestPatch(), MeshObject< polyMesh, UpdateableMeshObject, pointMesh >::New(), Foam::nl, argList::optionFound(), argList::optionRead(), argList::optionReadIfPresent(), patchNames(), polyBoundaryMesh::patchSet(), polyMesh::pointsInstance(), polyMesh::setInstance(), fvMeshSubset::setLargeCellSubset(), List::size(), HashTable::sortedToc(), fvMeshSubset::subMesh(), subsetDimensionedFields(), subsetPointFields(), subsetSurfaceFields(), subsetVolFields(), argList::validArgs, and fvMesh::write().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.