51 #define MESH_CRITICAL_VOLUME 1.0E-12 58 #define FOR_NODES(_mesh_, i) \ 59 for( NodeFullIter i( (_mesh_)->node_vector.begin() ); \ 60 i != (_mesh_)->node_vector.end(); \ 66 #define NODE_FULL_ITER(_mesh_,i) \ 67 (_mesh_)->node_vector.full_iter(i) 72 #define NODE_FULL_ITER_NULL(_mesh_) \ 73 NodeFullIter((_mesh_)->node_vector) 78 #define ELEM_FULL_ITER(_mesh_,i) \ 79 (_mesh_)->element.full_iter(i) 82 #define FOR_NODE_ELEMENTS(i,j) for((j)=0;(j)<(i)->n_elements();(j)++) 83 #define FOR_NODE_SIDES(i,j) for((j)=0;(j)<(i)->n_sides;(j)++) 102 <<
"Duplicate boundary elements! \n" 103 <<
"Element id: " << EI_ElemLast::val <<
" on region name: " << EI_RegLast::val <<
"\n" 104 <<
"Element id: " << EI_ElemNew::val <<
" on region name: " << EI_RegNew::val <<
"\n");
108 static const unsigned int undef_idx=-1;
114 enum {x_coord=0, y_coord=1, z_coord=2};
130 return node_vector.size();
134 return element.size();
138 return boundary_.size();
145 unsigned int n_corners();
171 void make_intersec_elements();
173 unsigned int n_sides();
176 return vb_neighbours_.size();
183 unsigned int max_edge_sides(
unsigned int dim)
const {
return max_edge_sides_[dim-1]; }
190 void read_gmsh_from_stream(istream &in);
194 void init_from_input();
200 vector<int> const & elements_id_maps(
bool boundary_domain)
const;
270 void check_and_finish();
294 void make_neighbours_and_edges();
300 void make_edge_permutations();
304 void create_node_element_lists();
327 void setup_topology();
330 void element_to_neigh_vb();
332 void count_element_types();
333 void count_side_types();
355 unsigned int max_edge_sides_[3];
365 std::shared_ptr<Partitioning>
part_;
405 #define FOR_ELEMENTS(_mesh_,__i) \ 406 for( ElementFullIter __i( (_mesh_)->element.begin() ); \ 407 __i != (_mesh_)->element.end(); \ 413 #define ELEMENT_FULL_ITER(_mesh_,i) \ 414 (_mesh_)->element.full_iter(i) 419 #define ELEMENT_FULL_ITER_NULL(_mesh_) \ 420 ElementFullIter((_mesh_)->element) 423 #define FOR_BOUNDARIES(_mesh_,i) \ 424 for( std::vector<Boundary>::iterator i= (_mesh_)->boundary_.begin(); \ 425 i != (_mesh_)->boundary_.end(); \ 431 #define BOUNDARY_FULL_ITER(_mesh_,i) \ 432 (_mesh_)->boundary.full_iter(i) 437 #define BOUNDARY_NULL(_mesh_) \ 438 BoundaryFullIter((_mesh_)->boundary) 444 #define FOR_EDGES(_mesh_,__i) \ 445 for( vector<Edge>::iterator __i = (_mesh_)->edges.begin(); \ 446 __i !=(_mesh_)->edges.end(); \ 449 #define FOR_SIDES(_mesh_, it) \ 450 FOR_ELEMENTS((_mesh_), ele) \ 451 for(SideIter it = ele->side(0); it->el_idx() < ele->n_sides(); ++it) 453 #define FOR_SIDE_NODES(i,j) for((j)=0;(j)<(i)->n_nodes;(j)++) 456 #define FOR_NEIGHBOURS(_mesh_, it) \ 457 for( std::vector<Neighbour>::iterator it = (_mesh_)->vb_neighbours_.begin(); \ 458 (it)!= (_mesh_)->vb_neighbours_.end(); ++it) 460 #define FOR_NEIGH_ELEMENTS(i,j) for((j)=0;(j)<(i)->n_elements;(j)++) 461 #define FOR_NEIGH_SIDES(i,j) for((j)=0;(j)<(i)->n_sides;(j)++)
Distribution * el_ds
Parallel distribution of elements.
Class for the mesh partitioning. This should provide:
vector< vector< unsigned int > > node_elements
static Input::Type::Record input_type
#define DECLARE_EXCEPTION(ExcName, Format)
Macro for simple definition of exceptions.
int * get_el_4_loc() const
vector< vector< vector< unsigned int > > > side_nodes
const RegionDB & region_db() const
vector< Boundary > boundary_
int * el_4_loc
Index set assigning to local element index its global index.
int * row_4_el
Index set assigning to global element index the local index used in parallel vectors.
unsigned int n_vb_neighbours() const
unsigned int n_elements() const
MPI_Comm get_comm() const
unsigned int n_boundaries() const
Class for O(log N) lookup for intersections with a set of bounding boxes.
ElementVector bc_elements
#define TYPEDEF_ERR_INFO(EI_Type, Type)
Macro to simplify declaration of error_info types.
std::shared_ptr< BIHTree > bih_tree_
Distribution * get_el_ds() const
vector< vector< unsigned int > > master_elements
vector< Neighbour > vb_neighbours_
unsigned int n_all_input_elements_
Number of elements read from input.
unsigned int max_edge_sides(unsigned int dim) const
int * get_row_4_el() const
std::vector< Edge > edges
Vector of MH edges, this should not be part of the geometrical mesh.
vector< Intersection > intersections
unsigned int n_nodes() const
unsigned int n_edges() const
vector< int > bulk_elements_id_
std::shared_ptr< Partitioning > part_
NodeVector node_vector
Vector of nodes of the mesh.
ElementVector element
Vector of elements of the mesh.