31 #ifndef DOMAINHANDLER_H
32 #define DOMAINHANDLER_H
72 void createMesh(std::vector<Mdouble>& simulationMin, std::vector<Mdouble>& simulationMax,
73 std::vector<unsigned>& numberOfDomains,
bool open);
78 void createDomains(std::vector<Mdouble> domainMin, std::vector<Mdouble> domainMax,
79 std::vector<unsigned>& globalMeshIndex, std::vector<unsigned>& numberOfDomains,
int dimCounter,
80 std::vector<Mdouble>& meshSize,
bool open);
100 std::string
getName()
const final;
148 void updateStatus(std::set<BaseParticle*>& particlesToBeDeleted);
dominoes D
Definition: Domino.cpp:76
Container to store the pointers to all objects that one creates in a simulation.
Definition: BaseHandler.h:51
Definition: BaseParticle.h:54
Container to store all Domain.
Definition: DomainHandler.h:47
void createDomains(std::vector< Mdouble > domainMin, std::vector< Mdouble > domainMax, std::vector< unsigned > &globalMeshIndex, std::vector< unsigned > &numberOfDomains, int dimCounter, std::vector< Mdouble > &meshSize, bool open)
Recursive function that creates the domains for a 3D mesh.
Definition: DomainHandler.cc:156
std::string getName() const final
returns the name of the class
Definition: DomainHandler.cc:230
void setCurrentDomainIndex(unsigned int index)
This sets a domain to the processor.
Definition: DomainHandler.cc:240
DomainHandler()
Default constructor, it creates an empty DomainHandler.
Definition: DomainHandler.cc:40
Mdouble getInteractionDistance()
Gets the interaction distance of the domain handler.
Definition: DomainHandler.cc:324
int getParticleDomainGlobalIndex(BaseParticle *particle)
Definition: DomainHandler.cc:330
void updateVelocity()
Definition: DomainHandler.cc:424
void setInteractionDistance(Mdouble interactionDistance)
Sets the interaction distance of the domain handler.
Definition: DomainHandler.cc:299
unsigned int currentDomainIndex_
Index to the particular domain of this process.
Definition: DomainHandler.h:161
void initialise()
Definition: DomainHandler.cc:434
unsigned int getCurrentDomainIndex() const
Gets the domain index assigned to the processor.
Definition: DomainHandler.cc:265
void addNewParticles()
Definition: DomainHandler.cc:429
void addObject(Domain *D) final
Adds a Domain to the DomainHandler.
Definition: DomainHandler.cc:203
void readOldObject(std::istream &is)
reads an old domain object
Definition: DomainHandler.cc:223
std::vector< unsigned > getNumberOfDomains()
Gets the number of domains in the domain handler.
Definition: DomainHandler.cc:287
Domain * getParticleDomain(int globalIndex)
Definition: DomainHandler.cc:414
void readAndAddObject(std::istream &is) final
reads a domain object
Definition: DomainHandler.cc:215
std::vector< unsigned > numberOfDomains_
vector containing the number of domains in Cartesian direction
Definition: DomainHandler.h:171
Mdouble interactionDistance_
Interaction distance between a domain boundary and the communication zone boundary.
Definition: DomainHandler.h:176
Domain * getCurrentDomain()
Gets the domain assigned to the processor.
Definition: DomainHandler.cc:250
std::vector< int > globalIndexToProcessorList_
look-up table to find the processor of a domain given the globalIndex of the domain
Definition: DomainHandler.h:166
~DomainHandler() final
Destructor, it destructs the DomainHandler and all Domain it contains.
Definition: DomainHandler.cc:78
void updateStatus(std::set< BaseParticle * > &particlesToBeDeleted)
Definition: DomainHandler.cc:419
DomainHandler & operator=(const DomainHandler &rhs)
Assignment operator.
Definition: DomainHandler.cc:64
void setNumberOfDomains(std::vector< unsigned > &numberOfdomains)
Sets the number of domains in the domain handler.
Definition: DomainHandler.cc:276
int getParticleProcessor(int globalIndex)
Definition: DomainHandler.cc:409
void createMesh(std::vector< Mdouble > &simulationMin, std::vector< Mdouble > &simulationMax, std::vector< unsigned > &numberOfDomains, bool open)
Creates a Cartesian square mesh in 3D.
Definition: DomainHandler.cc:93
The simulation can be subdivided into Domain's used in parallel code.
Definition: Domain.h:64