51 void Foam::faceToCell::combine(topoSet& set,
const bool add)
const
54 faceSet loadedSet(
mesh_, setName_);
60 const label facei = iter.key();
62 if ((option_ ==
OWNER) || (option_ ==
ANY))
85 Map<label> facesPerCell(loadedSet.size());
89 const label facei = iter.key();
94 if (fndOwn == facesPerCell.end())
96 facesPerCell.insert(own, 1);
109 if (fndNei == facesPerCell.end())
111 facesPerCell.insert(nei, 1);
124 const label celli = iter.key();
139 const polyMesh&
mesh,
141 const faceAction option
152 const polyMesh&
mesh,
153 const dictionary&
dict
178 Info<<
" Adding cells according to faceSet " << setName_
185 Info<<
" Removing cells according to faceSet " << setName_
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
Macros for easy insertion into run-time selection tables.
friend class iterator
Declare friendship with the iterator.
void size(const label)
Override size to be inconsistent with allocated storage.
Initialise the NamedEnum HashTable from the static list of names.
faceToCell(const polyMesh &mesh, const word &setName, const faceAction option)
Construct from components.
static const NamedEnum< faceAction, 4 > faceActionNames_
Names of the valid options.
virtual ~faceToCell()
Destructor.
virtual void applyToSet(const topoSetSource::setAction action, topoSet &) const
virtual const labelList & faceOwner() const
Return face owner.
virtual const labelList & faceNeighbour() const
Return face neighbour.
bool isInternalFace(const label faceIndex) const
Return true if given face label is internal to the mesh.
const cellList & cells() const
void addOrDelete(topoSet &set, const label celli, const bool) const
Add (if bool) celli to set or delete celli from set.
setAction
Enumeration defining the valid actions.
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
const unitSet & lookup(const word &unitName)
Lookup and return the named unit from the table.
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)
void add(GeometricField< typename typeOfSum< Type1, Type2 >::type, GeoMesh, PrimitiveField1 > &gf, const GeometricField< Type1, GeoMesh, PrimitiveField2 > &gf1, const GeometricField< Type2, GeoMesh, PrimitiveField3 > &gf2)
Ostream & endl(Ostream &os)
Add newline and flush stream.
treeBoundBox combine(const treeBoundBox &a, const treeBoundBox &b)
defineTypeNameAndDebug(atmosphericBoundaryLayer, 0)