36 namespace fvMeshDistributors
68 fvMesh& mesh = this->mesh();
96 redistributionInterval_(1),
114 const fvMesh& mesh = this->mesh();
116 bool redistributed =
false;
128 const scalar idealNCells =
137 if (imbalance > maxImbalance_)
139 Info<<
"Redistributing mesh with imbalance " << imbalance <<
endl;
149 redistributed =
true;
153 return redistributed;
Macros for easy insertion into run-time selection tables.
label timeIndex() const
Return current time index.
static label nProcs(const label communicator=0)
Number of processes in parallel run.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Abstract base class for decomposition.
A list of keyword definitions, which are a keyword followed by any number of values (e....
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T, if not found return the given default.
Base class for statistical distributions.
Sends/receives parts of mesh+fvfields to neighbouring processors. Used in load balancing.
Abstract base class for fvMesh movers.
const dictionary & dict() const
Return the dynamicMeshDict/distributor sub-dict.
Dynamic mesh redistribution using the distributor specified in decomposeParDict.
scalar maxImbalance_
Maximum imbalance between the ideal number of cells per processor.
void readDict()
Read the projection parameters from dictionary.
virtual ~distributor()
Destructor.
void distribute(const labelList &distribution)
Distribute the mesh and mesh data.
virtual void topoChange(const polyTopoChangeMap &)
Update corresponding to the given map.
label redistributionInterval_
Time-step interval between redistribution calls.
virtual void mapMesh(const polyMeshMap &)
Update from another mesh using the given map.
virtual bool write(const bool write=true) const
Write using given format, version and compression.
virtual bool update()
Distribute the.
distributor(fvMesh &mesh)
Construct from fvMesh.
Mesh data needed to do the Finite Volume discretisation.
const Time & time() const
Return the top-level database.
virtual void distribute(const polyDistributionMap &map)
Redistribute or update using the given distribution map.
label nTotalCells() const
Return total number of cells in decomposed mesh.
Class containing mesh-to-mesh mapping information after a mesh distribution where we send parts of me...
Class containing mesh-to-mesh mapping information.
const globalMeshData & globalData() const
Return parallel info.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
defineTypeNameAndDebug(none, 0)
addToRunTimeSelectionTable(fvMeshDistributor, none, fvMesh)
void write(std::ostream &os, const bool binary, List< floatScalar > &fField)
Write floats ascii or binary.
Ostream & endl(Ostream &os)
Add newline and flush stream.
T returnReduce(const T &Value, const BinaryOp &bop, const int tag=Pstream::msgType(), const label comm=UPstream::worldComm)
dimensioned< scalar > mag(const dimensioned< Type > &)