37 #ifndef MultiscaleCommunicatorsManager_H 38 #define MultiscaleCommunicatorsManager_H 1
40 #include <lifev/multiscale/framework/MultiscaleDefinitions.hpp> 106 return M_commContainer.size();
149 return M_commContainer.find ( modelID )->second;
171 void parallelProcessesAssignment ( std::vector< std::vector< Int > >& parallelProcesses,
const std::vector<Real>& localNumberOfProcesses,
const Int& numberOfProcesses );
181 return static_cast<
Int> ( std::floor ( value + 0.5 ) );
MultiscaleCommunicatorsManager(const MultiscaleCommunicatorsManager &solver)
void parallelProcessesAssignment(std::vector< std::vector< Int > > ¶llelProcesses, const std::vector< Real > &localNumberOfProcesses, const Int &numberOfProcesses)
const multiscaleCommPtr_Type & modelCommunicator(const UInt &modelID) const
Get the communicator of a specific model.
modelsID_Type M_parallelModelsID
Displayer::commPtr_Type multiscaleCommPtr_Type
UInt myModelsNumber() const
Determine the number of model owned by the process.
modelsCommunicatorContainer_Type M_commContainer
int32_type Int
Generic integer data.
MultiscaleCommunicatorsManager & operator=(const MultiscaleCommunicatorsManager &solver)
void updateInverseJacobian(const UInt &iQuadPt)
modelsLoad_Type::iterator modelsLoadIterator_Type
void setCommunicator(const multiscaleCommPtr_Type &comm)
Set the main epetra communicator.
modelsProcessesList_Type M_serialProcesses
modelsLoad_Type M_parallelModelsLoad
void showMe()
Display some information about the communicators.
void addGroup(const Real &load, const modelsID_Type &modelsID)
Add a group of models.
modelsProcessesList_Type M_parallelProcesses
virtual ~MultiscaleCommunicatorsManager()
Destructor.
multiscaleCommPtr_Type M_comm
void parallelProcessesDistribution(std::vector< Real > &localNumberOfProcesses, const Int &numberOfProcesses)
std::vector< Real > modelsLoad_Type
Int roundToInteger(const Real &value) const
Round a real number to the closest integer.
double Real
Generic real data.
modelsID_Type M_serialModelsID
std::map< UInt, multiscaleCommPtr_Type > modelsCommunicatorContainer_Type
bool myModel(const UInt &modelID) const
Determine if the model is owned by the process.
modelsID_Type::iterator modelsIDIterator_Type
void splitCommunicator()
Split the communicator among the models.
modelsCommunicatorContainer_Type::const_iterator modelsCommunicatorContainerIterator_Type
MultiscaleCommunicatorsManager()
Constructor.
std::vector< std::vector< Int > > modelsProcessesList_Type
MultiscaleCommunicatorsManager - The Multiscale Communicators Manager.
uint32_type UInt
generic unsigned integer (used mainly for addressing)
std::vector< UInt > modelsID_Type