Go to the documentation of this file.
48 { cellType::CALCULATED,
"calculated" },
49 { cellType::INTERPOLATED,
"interpolated" },
50 { cellType::HOLE,
"hole" },
56 Foam::cellCellStencil::cellCellStencil(
const fvMesh&
mesh)
59 nonInterpolatedFields_({
"zoneID"})
74 auto* ctorPtr = meshConstructorTable(stencilType);
83 *meshConstructorTablePtr_
133 zoneID[cellI] = label(volZoneID[cellI]);
160 return nonInterpolatedFields_;
166 return nonInterpolatedFields_;
174 if (slots[i] >= mesh_.nCells())
232 cellCellCentres.
setSize(cellCells.size());
236 label celli = selectedCells[i];
240 pointList& stencilPoints = cellCellCentres[celli];
241 stencil.
setSize(cFaces.size()+1);
242 stencilPoints.
setSize(stencil.size());
246 if (isValidCell[celli])
248 stencil[compacti] = globalCellIDs[celli];
249 stencilPoints[compacti++] = cellCentres[celli];
255 label facei = cFaces[i];
257 label own = faceOwner[facei];
260 bool isValid =
false;
263 nbrCelli = nbrGlobalCellIDs[bFacei];
264 nbrCc = nbrCellCentres[bFacei];
265 isValid = nbrIsValidCell[bFacei];
272 nbrCc = cellCentres[own];
273 isValid = isValidCell[own];
277 label nei = faceNeighbour[facei];
279 nbrCc = cellCentres[nei];
280 isValid = isValidCell[nei];
287 if (!current.found(nbrCelli))
289 stencil[compacti] = nbrCelli;
290 stencilPoints[compacti++] = nbrCc;
295 stencilPoints.
setSize(compacti);
Defines the attributes of an object for which implicit objectRegistry management is supported,...
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
A class for handling words, derived from Foam::string.
bool localStencil(const labelUList &) const
Helper: is stencil fully local.
label localStart() const
My local start.
static constexpr const zero Zero
Global zero (0)
defineRunTimeSelectionTable(reactionRateFlameArea, dictionary)
A List obtained as a section of another List.
virtual const fileName & dbDir() const
Override the objectRegistry dbDir for a single-region case.
static labelList count(const label size, const labelUList &lst)
Count occurrences (in parallel)
virtual const wordHashSet & nonInterpolatedFields() const
Return the names of any (stencil or mesh specific) fields that.
static word meshSubDir
Return the mesh sub-directory name (usually "polyMesh")
const cellList & cells() const
const fileName & facesInstance() const
Return the current instance directory for faces.
label localSize() const
My local size.
Ostream & endl(Ostream &os)
Add newline and flush stream.
T get(const word &keyword, enum keyType::option matchOpt=keyType::REGEX) const
IOList< label > labelIOList
Label container classes.
bool foundObject(const word &name, const bool recursive=false) const
Is the named Type found?
Mesh consisting of general polyhedral cells.
#define forAll(list, i)
Loop across all elements in list.
label nCells() const noexcept
Number of mesh cells.
#define FatalIOErrorInLookup(ios, lookupTag, lookupName, lookupTable)
Report an error message using Foam::FatalIOError.
static void globalCellCells(const globalIndex &gi, const polyMesh &mesh, const boolList &isValidDonor, const labelList &selectedCells, labelListList &cellCells, pointListList &cellCellCentres)
Helper: create cell-cell addressing in global numbering.
#define DebugInFunction
Report an information message using Foam::Info.
void setSize(const label n)
Alias for resize()
const labelIOList & zoneID() const
Helper: get reference to registered zoneID. Loads volScalarField.
virtual const labelList & faceOwner() const
Return face owner.
const Type & lookupObject(const word &name, const bool recursive=false) const
virtual ~cellCellStencil()
Destructor.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Macros for easy insertion into run-time selection tables.
const labelIOList & zoneID
Mesh data needed to do the Finite Volume discretisation.
Calculates a unique integer (label so might not have enough room - 2G max) for processor + local inde...
word findInstance(const fileName &dir, const word &name=word::null, const IOobject::readOption rOpt=IOobject::MUST_READ, const word &stopInstance=word::null) const
errorManipArg< error, int > exit(error &err, const int errNo=1)
static void listCombineGather(const List< commsStruct > &comms, List< T > &Value, const CombineOp &cop, const int tag, const label comm)
const vectorField & cellCentres() const
unsigned int count(const UList< bool > &bools, const bool val=true)
Count number of 'true' entries.
label nInternalFaces() const noexcept
Number of internal faces.
labelList identity(const label len, label start=0)
Create identity map of the given length with (map[i] == i)
const Time & time() const
Return the top-level database.
defineTypeNameAndDebug(combustionModel, 0)
static autoPtr< cellCellStencil > New(const fvMesh &, const dictionary &dict, const bool update=true)
New function which constructs and returns pointer to a.
static const Enum< cellType > cellTypeNames_
Mode type names.
A cell is defined as a list of faces with extra functionality.
virtual const labelList & faceNeighbour() const
Return face neighbour.
label toGlobal(const label i) const
From local to global index.