Static Public Member Functions | List of all members
fvMeshTools Class Reference

A collection of tools for operating on an fvMesh. More...

Static Public Member Functions

static label addPatch (fvMesh &mesh, const polyPatch &patch, const dictionary &patchFieldDict, const word &defaultPatchFieldType, const bool validBoundary)
 Add patch. Inserts patch before all processor patches. More...
 
static void setPatchFields (fvMesh &mesh, const label patchi, const dictionary &patchFieldDict)
 Change patchField on registered fields according to dictionary. More...
 
static void zeroPatchFields (fvMesh &mesh, const label patchi)
 Change patchField to zero on registered fields. More...
 
static void reorderPatches (fvMesh &, const labelList &oldToNew, const label nPatches, const bool validBoundary)
 Reorder and remove trailing patches. If validBoundary call is parallel. More...
 

Detailed Description

A collection of tools for operating on an fvMesh.

Source files

Definition at line 48 of file fvMeshTools.H.

Member Function Documentation

◆ addPatch()

Foam::label addPatch ( fvMesh mesh,
const polyPatch patch,
const dictionary patchFieldDict,
const word defaultPatchFieldType,
const bool  validBoundary 
)
static

Add patch. Inserts patch before all processor patches.

Supply per field the new patchField per field as a subdictionary or a default type. If validBoundary call is parallel synced and all add the same patch with same settings.

Definition at line 32 of file fvMeshTools.C.

References fvMesh::boundary(), polyMesh::boundaryMesh(), fvMesh::clearOut(), polyPatch::clone(), polyBoundaryMesh::findPatchID(), forAll, mesh, patchIdentifier::name(), Foam::New(), primitiveMesh::nFaces(), patchi, PtrList< T >::reorder(), polyBoundaryMesh::reorder(), PtrList< T >::set(), PtrList< T >::setSize(), UPtrList< T >::size(), polyPatch::start(), and Foam::Zero.

Referenced by fvMeshDistribute::printCoupleInfo().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setPatchFields()

void setPatchFields ( fvMesh mesh,
const label  patchi,
const dictionary patchFieldDict 
)
static

Change patchField on registered fields according to dictionary.

Definition at line 214 of file fvMeshTools.C.

References mesh, and patchi.

◆ zeroPatchFields()

void zeroPatchFields ( fvMesh mesh,
const label  patchi 
)
static

◆ reorderPatches()

void reorderPatches ( fvMesh mesh,
const labelList oldToNew,
const label  nPatches,
const bool  validBoundary 
)
static

Reorder and remove trailing patches. If validBoundary call is parallel.

synced and all add the same patch with same settings

Definition at line 324 of file fvMeshTools.C.

References fvMesh::boundary(), polyMesh::boundaryMesh(), mesh, PtrList< T >::reorder(), and polyBoundaryMesh::reorder().

Referenced by fvMeshDistribute::printCoupleInfo(), and fvMeshTools::zeroPatchFields().

Here is the call graph for this function:
Here is the caller graph for this function:

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