1 #ifndef __H2D_NEIGHBOR_H
2 #define __H2D_NEIGHBOR_H
5 #include "quadrature/quad.h"
6 #include "function/solution.h"
8 #include "mesh/refmap.h"
10 #include "space/space.h"
67 template<
typename Scalar>
105 void set_active_edge(
int edge);
108 bool set_active_edge_multimesh(
const int& edge);
111 Hermes::vector<unsigned int> get_transforms(uint64_t sub_idx)
const;
114 bool is_inter_edge(
const int& edge,
const Hermes::vector<unsigned int>& transformations)
const;
117 void update_according_to_sub_idx(
const Hermes::vector<unsigned int>& transformations);
120 void handle_sub_idx_way_down(
const Hermes::vector<unsigned int>& transformations);
124 bool compatible_transformations(
unsigned int a,
unsigned int b,
int edge)
const;
128 void clear_initial_sub_idx();
131 void delete_neighbor(
unsigned int position);
164 void set_quad_order(
int order);
171 int get_quad_eo(
bool on_neighbor =
false)
const;
179 int get_num_neighbors()
const;
185 const Hermes::vector<Element*>* get_neighbors()
const;
188 void clear_supported_shapes();
191 void set_ignore_errors(
bool value);
211 void free_central_al();
214 void combine_assembly_lists();
227 bool has_support_on_neighbor(
unsigned int index)
const;
242 int local_num_of_edge;
252 int get_active_segment()
const;
255 void set_active_segment(
unsigned int index);
258 Element* get_neighb_el()
const;
264 unsigned int get_central_n_trans(
unsigned int index)
const;
267 unsigned int get_central_transformations(
unsigned int index_1,
unsigned int index_2)
const;
270 unsigned int get_neighbor_n_trans(
unsigned int index)
const;
273 unsigned int get_neighbor_transformations(
unsigned int index_1,
unsigned int index_2)
const;
279 static const int max_level = Transformable::H2D_MAX_TRN_LEVEL;
282 unsigned int transf[max_level];
289 void copy_from(
const Hermes::vector<unsigned int>& t);
293 void copy_to(Hermes::vector<unsigned int>* t);
297 void strip_initial_transformations(
unsigned int number_of_stripped);
301 void apply_on(
const Hermes::vector<Transformable*>& tr)
const;
305 template<
typename T>
friend class Adapt;
306 template<
typename T>
friend class Func;
318 LightArray< Transformations* > central_transformations;
321 LightArray< Transformations* > neighbor_transformations;
323 uint64_t original_central_el_transform;
334 Hermes::vector<NeighborEdgeInfo> neighbor_edges;
335 Hermes::vector<Element*> neighbors;
336 unsigned int n_neighbors;
341 enum NeighborhoodType
343 H2D_DG_NOT_INITIALIZED = -1,
344 H2D_DG_NO_TRANSF = 0,
351 NeighborhoodType neighborhood_type;
368 void find_act_elem_up(
Element* elem,
int* orig_vertex_id,
Node** par_mid_vertices,
int n_parents);
386 void find_act_elem_down(
Node* vertex,
int* bounding_verts_id,
int* sons,
unsigned int n_sons);
406 int neighbor_edge_orientation(
int bounding_vert1,
int bounding_vert2,
int segment)
const;
409 void reset_neighb_info();
414 int central_quad_order;
415 int neighb_quad_order;
418 template<
typename T>
friend class Adapt;
419 template<
typename T>
friend class Func;