56 patches_(methodDict_.lookup(
"patches")),
57 nLayers_(methodDict_.lookupOrDefault<
label>(
"nLayers",
labelMax)),
58 depthFirst_(methodDict_.lookup(
"depthFirst")),
60 reverse_(methodDict_.lookup(
"reverse"))
66 bool Foam::structuredRenumber::layerLess::operator()
129 return order_[a] < order_[
b];
144 <<
"Number of points " << points.
size()
145 <<
" should equal the number of cells " << mesh.
nCells()
155 nFaces += pbm[iter.key()].
size();
163 const labelUList& fc = pbm[iter.key()].faceCells();
173 const label nLayers = nTotalCells/nTotalSeeds;
175 Info<<
type() <<
" : seeding " << nTotalSeeds
176 <<
" cells on (estimated) " << nLayers <<
" layers" <<
nl 186 fvMeshSubset subsetter(dynamic_cast<const fvMesh&>(mesh));
202 orderedToOld[subsetter.
cellMap()[i]] =
203 globalSubCells.toGlobal(subOrigToOrdered[i]);
218 patchFaces[nFaces] = pp.
start()+i;
243 deltaCalc.iterate(nLayers_);
245 Info<<
type() <<
" : did not visit " 246 << deltaCalc.getUnsetCells()
247 <<
" cells out of " << nTotalCells
248 <<
"; using " << method_().type() <<
" renumbering for these" <<
endl;
257 method_().renumber(mesh, points)
268 layerLess(depthFirst_, oldToOrdered, cellData)
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
ListType renumber(const labelUList &oldToNew, const ListType &)
Renumber the values (not the indices) of a list.
#define forAll(list, i)
Loop across all elements in list.
void sortedOrder(const UList< T > &, labelList &order)
Generate the (stable) sort order for the list.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
structuredRenumber(const dictionary &renumberDict)
Construct given the renumber dictionary.
void size(const label)
Override size to be inconsistent with allocated storage.
const dimensionedScalar b
Wien displacement law constant: default SI units: [m K].
Ostream & endl(Ostream &os)
Add newline and flush stream.
static autoPtr< renumberMethod > New(const dictionary &renumberDict)
Return a reference to the selected renumbering method.
label nTotalCells() const
Return total number of cells in decomposed mesh.
Less function class that can be used for sorting according to.
bool insert(const Key &key)
Insert a new entry.
labelHashSet patchSet(const UList< wordRe > &patchNames, const bool warnNotFound=true, const bool usePatchGroups=true) const
Return the set of patch IDs corresponding to the given names.
label size() const
Return number of elements in table.
Macros for easy insertion into run-time selection tables.
const fvMesh & subMesh() const
Return reference to subset mesh.
Abstract base class for renumbering.
Calculates a unique integer (label so might not have enough room - 2G max) for processor + local inde...
labelList invert(const label len, const labelUList &)
Invert one-to-one map. Unmapped elements will be -1.
const dictionary & optionalSubDict(const word &) const
Find and return a sub-dictionary if found.
const labelUList & faceCells() const
Return face-cell addressing.
Version of FaceCellWave that walks through prismatic cells only.
const globalMeshData & globalData() const
Return parallel info.
static const label labelMax
const labelList & cellMap() const
Return cell map.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
void reverse(UList< T > &, const label n)
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
bool valid(TrackingData &td) const
Check whether origin has been changed at all or.
defineTypeNameAndDebug(combustionModel, 0)
Post-processing mesh subset tool. Given the original mesh and the list of selected cells...
label size() const
Return the number of elements in the UPtrList.
Mesh data needed to do the Finite Volume discretisation.
label start() const
Return start label of this patch in the polyMesh face list.
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
For use with FaceCellWave. Determines topological distance to starting faces.
T returnReduce(const T &Value, const BinaryOp &bop, const int tag=Pstream::msgType(), const label comm=UPstream::worldComm)
Mesh consisting of general polyhedral cells.
A patch is a list of labels that address the faces in the global face list.
virtual labelList renumber(const pointField &) const
Return the order in which cells need to be visited, i.e.
void setLargeCellSubset(const labelList ®ion, const label currentRegion, const label patchID=-1, const bool syncCouples=true)
Set the subset from all cells with region == currentRegion.