34 namespace faceSelections
47 const dictionary&
dict
51 zoneName_(
dict.lookup(
"zoneName"))
70 label readID = mesh_.faceZones().findIndex(zoneName_);
75 <<
"Cannot find faceZone " << zoneName_ <<
nl <<
"Valid zones are "
76 << mesh_.faceZones().toc()
80 const faceZone& fZone = mesh_.faceZones()[readID];
84 label facei = fZone[i];
86 if (faceToZoneID[facei] == -1)
88 faceToZoneID[facei] = zoneID;
89 faceToFlip[facei] = fZone.flipMap()[i];
91 else if (faceToZoneID[facei] != zoneID)
94 <<
"Face " << facei <<
" already in faceZone "
95 << faceToZoneID[facei]
#define forAll(list, i)
Loop across all elements in list.
Macros for easy insertion into run-time selection tables.
virtual void select(const label, labelList &, boolList &) const =0
virtual ~faceZoneSelection()
Destructor.
virtual void select(const label zoneID, labelList &, boolList &) const
Apply this selector.
faceZoneSelection(const word &name, const fvMesh &mesh, const dictionary &dict)
Construct from dictionary.
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
errorManipArg< error, int > exit(error &err, const int errNo=1)
List< label > labelList
A List of labels.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
addToRunTimeSelectionTable(polyPatch, mergedCyclicPolyPatch, word)
List< bool > boolList
Bool container classes.
defineTypeNameAndDebug(combustionModel, 0)
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.