|
CArl
Code Arlequin / C++ implementation
|
Class used to build a restriction of a parent mesh to the coupling region. More...
#include <restrict_mesh.h>
Public Member Functions | |
| Mesh_restriction (libMesh::Mesh &mesh, const libMesh::Parallel::Communicator &local_comm, bool debugOutput=false) | |
| Constructor with a pre-defined parent mesh and a local communicator. More... | |
| void | BuildRestriction (const libMesh::ReplicatedMesh &Coupling_mesh) |
| Build the restriction of the parent mesh to the coupling region defined by Coupling_mesh. More... | |
| libMesh::ReplicatedMesh & | restricted_mesh () |
| Returns the restricted mesh. More... | |
| void | export_restriction_mesh (const std::string &filename_base) |
| Export the restricted mesh to a file. More... | |
| void | BuildRestrictionFromSet (const std::unordered_set< unsigned int > *restricted_mesh_set) |
| Build the restriction of the parent mesh from a given element set. This version is useful if the intersection search was already done. More... | |
Public Member Functions inherited from carl::Patch_construction | |
| Patch_construction (libMesh::Mesh &mesh, const libMesh::Parallel::Communicator &local_comm, bool debugOutput=false) | |
| Constructor with a pre-defined parent mesh and a local communicator. More... | |
| libMesh::ReplicatedMesh & | parent_mesh () |
| Returns the parent mesh. More... | |
| libMesh::ReplicatedMesh & | patch_mesh () |
| Returns the patch mesh. More... | |
| std::unordered_set< unsigned int > & | elem_indexes () |
| Returns the set of elements inside the patch. More... | |
| std::unordered_set< unsigned int > & | node_indexes () |
| Returns the set of nodes inside the patch. More... | |
| unsigned int | size () |
| Returns the number of elements inside the patch. More... | |
| const libMesh::Elem * | elem (unsigned int idx) |
| std::unordered_map< unsigned int, std::unordered_set< unsigned int > > & | patch_elem_neighbours () |
| Returns the patch mesh element neighbour table. More... | |
| void | BuildPatch (const libMesh::Elem *Query_elem) |
| Build the patch mesh covering a given "Query_elem". More... | |
| unsigned int | convert_parent_to_patch_elem_id (unsigned int input) |
| Convert an element index from the parent mesh to the patch mesh. More... | |
| unsigned int | convert_patch_to_parent_elem_id (unsigned int input) |
| Convert an element index from the patch mesh to the parent mesh. More... | |
| void | export_patch_mesh (std::string &filename_base) |
| Export the patch mesh to a file. More... | |
| unsigned int | current_elem_id () |
| const libMesh::Elem * | current_elem_pointer () |
| void | intersection_queue_push_back (unsigned int elem_id) |
| [ADV. FRONT] Push back element to the deque containing the elements to be treated. More... | |
| void | set_elem_as_treated (unsigned int elem_id) |
| [ADV. FRONT] Mark element as already treated. More... | |
| void | set_elem_as_inside_queue (unsigned int elem_id) |
| [ADV. FRONT] Mark element as already inside the deque of elements to be treated. More... | |
| bool | intersection_queue_empty () |
| [ADV. FRONT] Check if deque of elements to be treated is empty. More... | |
| bool | test_queue_empty () |
| [ADV. FRONT] Check if deque of elements to be tested is empty. More... | |
| unsigned int | intersection_queue_extract_front_elem () |
| [ADV. FRONT] Pop and returns the first element to be treated. More... | |
| unsigned int | test_queue_extract_front_elem () |
| [ADV. FRONT] Pop and returns the first element to be tested. More... | |
| std::unordered_set< unsigned int > & | neighbors_to_search_next_pair () |
| [ADV. FRONT] Returns the current element's neighbors that must be tested yet. More... | |
| bool | set_neighbors_to_search_next_pairs () |
| [ADV. FRONT] Set the list of neighbors of the current element that must be tested yet. More... | |
| void | add_neighbors_to_test_list () |
| [ADV. FRONT] Adds element to test list. More... | |
| void | FrontSearch_initialize () |
| [ADV. FRONT] Initialize the advancing front search data structures. More... | |
| void | FrontSearch_reset () |
| [ADV. FRONT] Reset the advancing front search data structures, with the exception of list of elements to be treated (should be joined to "FrontSearch_prepare_for_probed_test") More... | |
| unsigned int | FrontSearch_prepare_for_probed_test () |
| [ADV. FRONT] Reset the advancing front search data structures, with the exception of list of elements to be treated. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from carl::Patch_construction | |
| Patch_construction () | |
| void | insert_patch_element (const libMesh::Elem *Patch_elem) |
| Insert an parent mesh element inside the patch, updating the data structures. More... | |
| void | build_patch_mesh () |
| Build a patch mesh from the patch data structures. More... | |
Protected Attributes inherited from carl::Patch_construction | |
| const libMesh::Parallel::Communicator & | m_comm |
| Parent mesh communicator. More... | |
| const unsigned int | m_nodes |
| Parent mesh number of processors. More... | |
| const unsigned int | m_rank |
| Parent mesh processor rank. More... | |
| const libMesh::Parallel::Communicator & | m_local_comm |
| Patch mesh communicator. More... | |
| libMesh::ReplicatedMesh & | m_Mesh_parent |
| Parent mesh. More... | |
| libMesh::ReplicatedMesh | m_Mesh_patch |
| Patch mesh. More... | |
| std::unique_ptr< libMesh::PointLocatorBase > | m_Parent_Point_Locator |
| Parent mesh point locator. More... | |
| Intersection_Tools | m_Intersection_Test |
| Intersection search and construction tools. More... | |
| std::unordered_set< unsigned int > | m_Patch_Elem_indexes |
| Set of elements inside the patch. More... | |
| std::unordered_set< unsigned int > | m_Patch_Node_indexes |
| Set of nodes inside the patch. More... | |
| std::unordered_map< unsigned int, std::unordered_set< unsigned int > > | m_Patch_Elem_Neighbours |
| Element neighbour table for the patch. More... | |
| unsigned int | m_working_element_id |
| [ADV. FRONT] Index of the patch element currently being tested More... | |
| bool | m_bTestNeighsForNewPairs |
| !!! More... | |
| std::deque< int > | m_element_intersection_queue |
| [ADV. FRONT] Deque containing the elements to be treated. More... | |
| std::deque< int > | m_element_test_queue |
| [ADV. FRONT] Deque containing the elements to be tested More... | |
| std::unordered_map< unsigned int, int > | m_element_already_treated |
| [ADV. FRONT] Marks if an element was already treated or not More... | |
| std::unordered_map< unsigned int, int > | m_element_inside_intersection_queue |
| [ADV. FRONT] Marks if an element is already inside "m_element_intersection_queue" More... | |
| std::unordered_set< unsigned int > | m_element_neighbours_to_search |
| [ADV. FRONT] Set containing the current element's neighbors that must be tested yet. More... | |
| std::unordered_map< unsigned int, int > | m_node_map_Parent_to_Patch |
| Mapping between the parent and patch mesh nodes, using the former as keys. More... | |
| std::unordered_map< unsigned int, int > | m_node_map_Patch_to_Parent |
| Mapping between the patch and parent mesh nodes, using the former as keys. More... | |
| std::unordered_map< unsigned int, int > | m_elem_map_Parent_to_Patch |
| Mapping between the parent and patch mesh elements, using the former as keys. More... | |
| std::unordered_map< unsigned int, int > | m_elem_map_Patch_to_Parent |
| Mapping between the patch and parent mesh elements, using the former as keys. More... | |
| bool | m_bPrintDebug |
| Print debug information? Default: false. More... | |
Class used to build a restriction of a parent mesh to the coupling region.
This class is derived from the carl::Patch_construction class, and it contains the methods needed to restrict a mesh to the region defined by the coupling mesh.
Definition at line 31 of file restrict_mesh.h.
|
inline |
Constructor with a pre-defined parent mesh and a local communicator.
Definition at line 37 of file restrict_mesh.h.
| void carl::Mesh_restriction::BuildRestriction | ( | const libMesh::ReplicatedMesh & | Coupling_mesh | ) |
Build the restriction of the parent mesh to the coupling region defined by Coupling_mesh.
Definition at line 36 of file restrict_mesh.cpp.
| void carl::Mesh_restriction::BuildRestrictionFromSet | ( | const std::unordered_set< unsigned int > * | restricted_mesh_set | ) |
Build the restriction of the parent mesh from a given element set. This version is useful if the intersection search was already done.
Definition at line 12 of file restrict_mesh.cpp.
| void carl::Mesh_restriction::export_restriction_mesh | ( | const std::string & | filename_base | ) |
Export the restricted mesh to a file.
Definition at line 162 of file restrict_mesh.cpp.
| libMesh::ReplicatedMesh & carl::Mesh_restriction::restricted_mesh | ( | ) |
Returns the restricted mesh.
Definition at line 187 of file restrict_mesh.cpp.