Go to the documentation of this file.
20 #ifndef LIBMESH_MESH_COMMUNICATION_H
21 #define LIBMESH_MESH_COMMUNICATION_H
24 #include "libmesh/compare_elems_by_level.h"
25 #include "libmesh/libmesh_common.h"
26 #include "libmesh/mesh_tools.h"
29 #include <unordered_map>
36 class DistributedMesh;
102 bool newly_coarsened_only =
false)
const;
176 template <
typename ForwardIterator>
178 const ForwardIterator &,
179 const ForwardIterator &,
180 std::unordered_map<dof_id_type, dof_id_type> &)
const;
186 template <
typename ForwardIterator>
189 const ForwardIterator &,
190 const ForwardIterator &,
191 std::vector<dof_id_type> &)
const;
198 #ifdef LIBMESH_ENABLE_AMR
203 #endif // LIBMESH_ENABLE_AMR
256 MeshBase::const_element_iterator elem_it,
257 MeshBase::const_element_iterator elem_end,
258 std::set<const Elem *, CompareElemIdsByLevel> & connected_elements);
263 MeshBase::const_element_iterator elem_it,
264 MeshBase::const_element_iterator elem_end,
265 std::set<const Elem *, CompareElemIdsByLevel> & connected_elements);
269 void connect_families(std::set<const Elem *, CompareElemIdsByLevel> & connected_elements);
272 void reconnect_nodes (
const std::set<const Elem *, CompareElemIdsByLevel> & connected_elements,
273 std::set<const Node *> & connected_nodes);
283 #endif // LIBMESH_MESH_COMMUNICATION_H
void check_for_duplicate_global_indices(MeshBase &) const
Throw an error if we have any index clashes in the numbering used by assign_global_indices.
void connect_children(const MeshBase &mesh, MeshBase::const_element_iterator elem_it, MeshBase::const_element_iterator elem_end, std::set< const Elem *, CompareElemIdsByLevel > &connected_elements)
void allgather(DistributedMesh &mesh) const
This method takes an input DistributedMesh which may be distributed among all the processors.
void delete_remote_elements(DistributedMesh &, const std::set< Elem * > &) const
This method takes an input DistributedMesh which may be distributed among all the processors.
Defines a Cartesian bounding box by the two corner extremum.
void gather_neighboring_elements(DistributedMesh &) const
The libMesh namespace provides an interface to certain functionality in the library.
void find_local_indices(const libMesh::BoundingBox &, const ForwardIterator &, const ForwardIterator &, std::unordered_map< dof_id_type, dof_id_type > &) const
This method determines a locally unique, contiguous index for each object in the input range.
void make_p_levels_parallel_consistent(MeshBase &)
Copy p levels of ghost elements from their local processors.
void reconnect_nodes(const std::set< const Elem *, CompareElemIdsByLevel > &connected_elements, std::set< const Node * > &connected_nodes)
MeshCommunication()
Constructor.
void make_node_ids_parallel_consistent(MeshBase &)
Assuming all ids on local nodes are globally unique, and assuming all processor ids are parallel cons...
void make_nodes_parallel_consistent(MeshBase &)
Copy processor_ids and ids on ghost nodes from their local processors.
void send_coarse_ghosts(MeshBase &) const
Examine a just-coarsened mesh, and for any newly-coarsened elements, send the associated ghosted elem...
void find_global_indices(const Parallel::Communicator &communicator, const libMesh::BoundingBox &, const ForwardIterator &, const ForwardIterator &, std::vector< dof_id_type > &) const
This method determines a globally unique, partition-agnostic index for each object in the input range...
void make_node_proc_ids_parallel_consistent(MeshBase &)
Assuming all processor ids on nodes touching local elements are parallel consistent,...
void broadcast(MeshBase &) const
void redistribute(DistributedMesh &mesh, bool newly_coarsened_only=false) const
This method takes a parallel distributed mesh and redistributes the elements.
void make_node_unique_ids_parallel_consistent(MeshBase &)
Assuming all unique_ids on local nodes are globally unique, and assuming all processor ids are parall...
This is the MeshBase class.
void gather(const processor_id_type root_id, DistributedMesh &) const
This method takes an input DistributedMesh which may be distributed among all the processors.
uint8_t processor_id_type
void make_new_nodes_parallel_consistent(MeshBase &)
Copy processor_ids and ids on new nodes from their local processors.
void clear()
Clears all data structures and resets to a pristine state.
void query_ghosting_functors(const MeshBase &mesh, processor_id_type pid, MeshBase::const_element_iterator elem_it, MeshBase::const_element_iterator elem_end, std::set< const Elem *, CompareElemIdsByLevel > &connected_elements)
void connect_families(std::set< const Elem *, CompareElemIdsByLevel > &connected_elements)
void make_elems_parallel_consistent(MeshBase &)
Copy ids of ghost elements from their local processors.
void assign_global_indices(MeshBase &) const
This method assigns globally unique, partition-agnostic indices to the nodes and elements in the mesh...
static const processor_id_type invalid_processor_id
An invalid processor_id to distinguish DoFs that have not been assigned to a processor.
This is the MeshCommunication class.
void make_new_node_proc_ids_parallel_consistent(MeshBase &)
Assuming all processor ids on nodes touching local elements are parallel consistent,...
The DistributedMesh class is derived from the MeshBase class, and is intended to provide identical fu...
~MeshCommunication()
Destructor.