Loading...
Searching...
No Matches
fvMeshSubsetter Class Reference

Extends Foam::fvMeshSubset with two-step subsetting (uses polyTopoChange modification). More...

#include <fvMeshSubsetter.H>

Inheritance diagram for fvMeshSubsetter:
Collaboration diagram for fvMeshSubsetter:

Public Member Functions

labelList getExposedFaces (const bitSet &selectedCells, const bool syncPar=true) const
 Get labels of exposed faces.
labelList getExposedFaces (const label regioni, const labelUList &regions, const bool syncPar=true) const
 Get labels of exposed faces.
void setCellSubset (const bitSet &selectedCells, const labelList &exposedFaces, const labelList &patchIDs, const bool syncPar=true)
 For every exposed face (from above getExposedFaces).
void setCellSubset (const label regioni, const labelList &regions, const labelList &exposedFaces, const labelList &patchIDs, const bool syncPar=true)
 For every exposed face (from above getExposedFaces).
 fvMeshSubset (const fvMeshSubset &)=delete
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh) noexcept
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh, Foam::zero)
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh, const bitSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh, const labelUList &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh, const labelHashSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit constructors from fvMeshSubset.
 fvMeshSubset (const fvMesh &baseMesh, const label regioni, const labelUList &regions, const label patchID=-1, const bool syncPar=true)
 Inherit constructors from fvMeshSubset.
void setCellSubset (const bitSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit all one-step subsetting.
void setCellSubset (const labelUList &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit all one-step subsetting.
void setCellSubset (const labelHashSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Inherit all one-step subsetting.
void setCellSubset (const label regioni, const labelUList &regions, const label patchID=-1, const bool syncPar=true)
 Inherit all one-step subsetting.
Public Member Functions inherited from fvMeshSubset
 ClassName ("fvMeshSubset")
 fvMeshSubset (const fvMeshSubset &)=delete
 No copy construct.
void operator= (const fvMeshSubset &)=delete
 No copy assignment.
 fvMeshSubset (const fvMesh &baseMesh) noexcept
 Construct using the entire mesh (no subset).
 fvMeshSubset (const fvMesh &baseMesh, Foam::zero)
 Construct a zero-sized subset mesh, non-processor patches only.
 fvMeshSubset (const fvMesh &baseMesh, const bitSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Construct for a cell-subset of the given mesh.
 fvMeshSubset (const fvMesh &baseMesh, const labelUList &selectedCells, const label patchID=-1, const bool syncPar=true)
 Construct for a cell-subset of the given mesh.
 fvMeshSubset (const fvMesh &baseMesh, const labelHashSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Construct for a cell-subset of the given mesh.
 fvMeshSubset (const fvMesh &baseMesh, const label regioni, const labelUList &regions, const label patchID=-1, const bool syncPar=true)
 Construct for a cell-subset of the given mesh.
const fvMeshbaseMesh () const noexcept
 Original mesh.
const fvMeshmesh () const noexcept
 Return baseMesh or subMesh, depending on the current state.
bool hasSubMesh () const noexcept
 Have subMesh?
const fvMeshsubMesh () const
 Return reference to subset mesh.
fvMeshsubMesh ()
 Return reference to subset mesh.
const labelListpointMap () const
 Return point map.
const labelListfaceMap () const
 Return face map.
const labelListfaceFlipMap () const
 Return face map with sign to encode flipped faces.
const labelListcellMap () const
 Return cell map.
const labelListpatchMap () const
 Return patch map.
const labelListpointPatchMap () const
 Return point-patch map. Usually identical to patchMap except if additional patches are added to the pointMesh.
void clear ()
 Reset subMesh and all maps.
void reset ()
 Reset subMesh and all maps. Same as clear().
void reset (Foam::zero)
 Reset to a zero-sized subset mesh, non-processor patches only.
void reset (autoPtr< fvMesh > &&subMeshPtr, labelList &&pointMap, labelList &&faceMap, labelList &&cellMap, labelList &&patchMap)
 Reset from components.
void reset (const bitSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells.
void reset (const labelUList &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells.
void reset (const labelHashSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells.
void reset (const label regioni, const labelUList &regions, const label patchID=-1, const bool syncCouples=true)
 Use the cells of cells corresponding to where region == regioni.
void setCellSubset (const bitSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells. Same as reset().
void setCellSubset (const labelUList &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells. Same as reset().
void setCellSubset (const labelHashSet &selectedCells, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells. Same as reset().
void setCellSubset (const label regioni, const labelUList &regions, const label patchID=-1, const bool syncPar=true)
 Use the specified subset of cells. Same as reset().
template<class Type>
tmp< DimensionedField< Type, volMesh > > interpolate (const DimensionedField< Type, volMesh > &, const bool allowUnmapped=false) const
 Map volume internal (dimensioned) field Optional unmapped argument (currently unused).
template<class Type>
tmp< GeometricField< Type, fvPatchField, volMesh > > interpolate (const GeometricField< Type, fvPatchField, volMesh > &, const bool allowUnmapped=false) const
 Map volume field.
template<class Type>
tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate (const GeometricField< Type, fvsPatchField, surfaceMesh > &, const bool allowUnmapped=false) const
 Map surface field.
template<class Type>
tmp< GeometricField< Type, pointPatchField, pointMesh > > interpolate (const GeometricField< Type, pointPatchField, pointMesh > &, const bool allowUnmapped=false) const
 Map point field.
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::fvPatchField, Foam::volMesh > > interpolate (const GeometricField< Type, fvPatchField, volMesh > &vf, const fvMesh &sMesh, const labelUList &patchMap, const labelUList &cellMap, const labelUList &faceMap, const bool allowUnmapped)
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::fvPatchField, Foam::volMesh > > interpolate (const GeometricField< Type, fvPatchField, volMesh > &vf, const bool allowUnmapped) const
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::fvsPatchField, Foam::surfaceMesh > > interpolate (const GeometricField< Type, fvsPatchField, surfaceMesh > &vf, const fvMesh &sMesh, const labelUList &patchMap, const labelUList &cellMap, const labelUList &faceMap)
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::fvsPatchField, Foam::surfaceMesh > > interpolate (const GeometricField< Type, fvsPatchField, surfaceMesh > &sf, const bool allowUnmapped) const
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::pointPatchField, Foam::pointMesh > > interpolate (const GeometricField< Type, pointPatchField, pointMesh > &vf, const pointMesh &sMesh, const labelUList &patchMap, const labelUList &pointMap)
template<class Type>
Foam::tmp< Foam::GeometricField< Type, Foam::pointPatchField, Foam::pointMesh > > interpolate (const GeometricField< Type, pointPatchField, pointMesh > &sf, const bool allowUnmapped) const
template<class Type>
Foam::tmp< Foam::DimensionedField< Type, Foam::volMesh > > interpolate (const DimensionedField< Type, volMesh > &df, const fvMesh &sMesh, const labelUList &cellMap)
template<class Type>
Foam::tmp< Foam::DimensionedField< Type, Foam::volMesh > > interpolate (const DimensionedField< Type, volMesh > &df, const bool allowUnmapped) const

Additional Inherited Members

Static Public Member Functions inherited from fvMeshSubset
template<class Type>
static tmp< DimensionedField< Type, volMesh > > interpolate (const DimensionedField< Type, volMesh > &, const fvMesh &sMesh, const labelUList &cellMap)
 Map volume internal (dimensioned) field.
template<class Type>
static tmp< GeometricField< Type, fvPatchField, volMesh > > interpolate (const GeometricField< Type, fvPatchField, volMesh > &, const fvMesh &sMesh, const labelUList &patchMap, const labelUList &cellMap, const labelUList &faceMap, const bool allowUnmapped=false)
 Map volume field.
template<class Type>
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate (const GeometricField< Type, fvsPatchField, surfaceMesh > &, const fvMesh &sMesh, const labelUList &patchMap, const labelUList &cellMap, const labelUList &faceMap)
 Map surface field.
template<class Type>
static tmp< GeometricField< Type, pointPatchField, pointMesh > > interpolate (const GeometricField< Type, pointPatchField, pointMesh > &, const pointMesh &sMesh, const labelUList &patchMap, const labelUList &pointMap)
 Map point field.
Static Public Attributes inherited from fvMeshSubset
static word exposedPatchName
 Name for exposed internal faces (default: oldInternalFaces).
Protected Member Functions inherited from fvMeshSubset
bool checkHasSubMesh () const
 FatalError if subset has not been performed.

Detailed Description

Extends Foam::fvMeshSubset with two-step subsetting (uses polyTopoChange modification).

Source files

Definition at line 48 of file fvMeshSubsetter.H.

Member Function Documentation

◆ getExposedFaces() [1/2]

Foam::labelList getExposedFaces ( const bitSet & selectedCells,
const bool syncPar = true ) const

Get labels of exposed faces.

These are

  • internal faces that become boundary faces
  • coupled faces that become uncoupled (since one of the sides gets deleted)

Definition at line 128 of file fvMeshSubsetter.C.

References fvMeshSubset::baseMesh(), removeCells::getExposedFaces(), and Foam::invertCellSelection().

Here is the call graph for this function:

◆ getExposedFaces() [2/2]

Foam::labelList getExposedFaces ( const label regioni,
const labelUList & regions,
const bool syncPar = true ) const

Get labels of exposed faces.

These are

  • internal faces that become boundary faces
  • coupled faces that become uncoupled (since one of the sides gets deleted)

Definition at line 142 of file fvMeshSubsetter.C.

References fvMeshSubset::baseMesh(), removeCells::getExposedFaces(), and Foam::invertCellSelection().

Here is the call graph for this function:

◆ setCellSubset() [1/6]

void setCellSubset ( const bitSet & selectedCells,
const labelList & exposedFaces,
const labelList & patchIDs,
const bool syncPar = true )

For every exposed face (from above getExposedFaces).

Uses supplied (existing!) patches

Definition at line 157 of file fvMeshSubsetter.C.

References fvMeshSubset::baseMesh(), Foam::invertCellSelection(), and patchIDs.

Here is the call graph for this function:

◆ setCellSubset() [2/6]

void setCellSubset ( const label regioni,
const labelList & regions,
const labelList & exposedFaces,
const labelList & patchIDs,
const bool syncPar = true )

For every exposed face (from above getExposedFaces).

Uses supplied (existing!) patches

Definition at line 175 of file fvMeshSubsetter.C.

References fvMeshSubset::baseMesh(), Foam::invertCellSelection(), and patchIDs.

Here is the call graph for this function:

◆ fvMeshSubset() [1/7]

fvMeshSubset ( const fvMeshSubset & )
delete

Inherit constructors from fvMeshSubset.

◆ fvMeshSubset() [2/7]

fvMeshSubset ( const fvMesh & baseMesh)
explicitnoexcept

Inherit constructors from fvMeshSubset.

Definition at line 183 of file fvMeshSubset.C.

References pp().

Here is the call graph for this function:

◆ fvMeshSubset() [3/7]

fvMeshSubset ( const fvMesh & baseMesh,
Foam::zero  )

Inherit constructors from fvMeshSubset.

Definition at line 188 of file fvMeshSubset.C.

References pp().

Here is the call graph for this function:

◆ fvMeshSubset() [4/7]

fvMeshSubset ( const fvMesh & baseMesh,
const bitSet & selectedCells,
const label patchID = -1,
const bool syncPar = true )

Inherit constructors from fvMeshSubset.

Definition at line 195 of file fvMeshSubset.C.

References Foam::isA(), and pp().

Here is the call graph for this function:

◆ fvMeshSubset() [5/7]

fvMeshSubset ( const fvMesh & baseMesh,
const labelUList & selectedCells,
const label patchID = -1,
const bool syncPar = true )

Inherit constructors from fvMeshSubset.

Definition at line 208 of file fvMeshSubset.C.

◆ fvMeshSubset() [6/7]

fvMeshSubset ( const fvMesh & baseMesh,
const labelHashSet & selectedCells,
const label patchID = -1,
const bool syncPar = true )

Inherit constructors from fvMeshSubset.

Definition at line 221 of file fvMeshSubset.C.

References pp().

Here is the call graph for this function:

◆ fvMeshSubset() [7/7]

fvMeshSubset ( const fvMesh & baseMesh,
const label regioni,
const labelUList & regions,
const label patchID = -1,
const bool syncPar = true )

Inherit constructors from fvMeshSubset.

Definition at line 234 of file fvMeshSubset.C.

◆ setCellSubset() [3/6]

void setCellSubset ( const bitSet & selectedCells,
const label patchID = -1,
const bool syncPar = true )
inline

Inherit all one-step subsetting.

Definition at line 390 of file fvMeshSubset.H.

◆ setCellSubset() [4/6]

void setCellSubset ( const labelUList & selectedCells,
const label patchID = -1,
const bool syncPar = true )
inline

Inherit all one-step subsetting.

Definition at line 403 of file fvMeshSubset.H.

◆ setCellSubset() [5/6]

void setCellSubset ( const labelHashSet & selectedCells,
const label patchID = -1,
const bool syncPar = true )
inline

Inherit all one-step subsetting.

Definition at line 416 of file fvMeshSubset.H.

◆ setCellSubset() [6/6]

void setCellSubset ( const label regioni,
const labelUList & regions,
const label patchID = -1,
const bool syncPar = true )
inline

Inherit all one-step subsetting.

Definition at line 429 of file fvMeshSubset.H.


The documentation for this class was generated from the following files: