37#include <boost/mpi/communicator.hpp>
57 boost::mpi::communicator m_comm;
59 double m_cutoff_regular;
60 std::vector<Cell *> m_local_cells;
61 std::vector<Cell *> m_ghost_cells;
71 std::set<int>
const m_n_square_types;
73 std::function<bool()> m_get_global_ghost_flags;
75 bool is_n_square_type(
int type_id)
const {
76 return (m_n_square_types.find(type_id) != m_n_square_types.end());
81 double skin, std::function<
bool()> get_ghost_flags,
83 std::set<int> n_square_types);
91 void resort(
bool global, std::vector<ParticleChange> &diff)
override;
96 return m_exchange_ghosts_comm;
100 return m_collect_ghost_force_comm;
103 std::span<Cell *const>
local_cells()
const override {
return m_local_cells; }
104 std::span<Cell *const>
ghost_cells()
const override {
return m_ghost_cells; }
107 if (is_n_square_type(p.
type())) {
114 if (is_n_square_type(p.
type())) {
143 std::size_t count_particles(std::vector<Cell *>
const &
local_cells)
const;
Vector implementation and trait types for boost qvm interoperability.
Atom decomposition cell system.
Utils::Vector3d max_range() const override
Utils::Vector3d max_cutoff() const override
auto const & get_local_cells() const
Cell * particle_to_cell(Particle const &p) override
Determine which cell a particle id belongs to.
Hybrid decomposition cell system.
std::span< Cell *const > local_cells() const override
GhostCommunicator const & exchange_ghosts_comm() const override
std::size_t count_particles_in_regular() const
Count particles in child regular decompositions.
Utils::Vector3d max_range() const override
auto get_cutoff_regular() const
std::size_t count_particles_in_n_square() const
Count particles in child N-square decompositions.
Cell * particle_to_cell(Particle const &p) override
auto get_cell_grid() const
Cell const * particle_to_cell(Particle const &p) const override
void resort(bool global, std::vector< ParticleChange > &diff) override
BoxGeometry const & box() const override
auto get_n_square_types() const
auto get_cell_size() const
Utils::Vector3d max_cutoff() const override
GhostCommunicator const & collect_ghost_force_comm() const override
std::optional< BoxGeometry > minimum_image_distance() const override
std::span< Cell *const > ghost_cells() const override
A distributed particle decomposition.
Ghost particles and particle exchange.
Properties for a ghost communication.
Struct holding all information for one particle.
auto const & type() const
Regular decomposition cell system.
Cell * particle_to_cell(Particle const &p) override
Utils::Vector3d cell_size
Cell size.
auto const & get_local_cells() const
Utils::Vector3i cell_grid
Grid dimensions per node.