33 #ifndef __SIMPLE_MANIFOLD_2_H_ 
   34 #define __SIMPLE_MANIFOLD_2_H_ 
   94   { 
init(p, parent, with_ghost); }
 
  244     if ( eID.is_border())
 
  277     if ( !eID.is_border()) 
 
  281       while ( !oeID.is_border()) 
 
  358     if ( eID.is_border()) {
 
  364       return ene[opp.lid()+1==ene.size_of_edges()?0:opp.lid()+1];
 
  368         return (*ene_in)[eID.lid()];
 
  382       return ene[opp.
lid()];
 
  386         return (*ene_in)[eID.
lid()+1==ene_in->size_of_edges()?0:eID.
lid()+1];
 
  389         return ene[eID.
lid()+1==ene.size_of_edges()?0:eID.
lid()+1];
 
  431                          "No real edge incident on given vertex"); 
 
  446     if ( isghost) 
return eID;
 
  457                          "No ghost edge incident on given vertex"); 
 
  469     if ( !eID.is_border()) 
return false;
 
  470     if ( eID.eid()>int(
_beIDs.size())) 
return false;
 
  496     if ( eID.
eid()>int(
_beIDs.size())) 
return false;
 
  547     if ( !eID.
is_border()) { assert(
false); 
return -1; }
 
  548     else return eID.
eid();
 
  650                     std::vector< bool> &is_isolated, 
 
  651                     std::vector< Edge_ID > *b, 
 
  659              bool with_ghost=
true);
 
std::vector< Edge_ID > _oeIDs_real_or_str
int size_of_ghost_faces() const 
Number of ghost elements of the pane. 
Edge_ID get_a_real_border_edge() const 
Obtain a border edge on real part of the pane. 
#define MAP_END_NAMESPACE
int maxsize_of_nodes() const 
Maximum number of nodes allowed in the pane. 
Edge_ID get_incident_ghost_edge(int vID) const 
Get the ID of an incident real edge within the pane of a given node The incident edge may encode an i...
int maxsize_of_real_triangles() const 
Maximum number of real triangles allowed in the pane. 
void get_borders(std::vector< bool > &is_border, std::vector< bool > &is_isolated, std::vector< Edge_ID > *b, int *ng=NULL) const 
Obtain all the border nodes, isolated nodes, and border edges. 
bool is_pure_real_border_edge(const Edge_ID &eID) const 
Determine whether a given edge is a border edge of real part of the whole pane (on physical border)...
bool is_ghost_border_edge(const Edge_ID &eID) const 
Determine whether a given edge is a border edge of ghost part of the pane (either on physical border ...
std::vector< const COM::Connectivity * > _elem_conns
#define COM_assertion(EX)
Error checking utility similar to the assert macro of the C language. 
Edge_ID get_prev_edge_interior(const Edge_ID &eID) const 
int size_of_real_elements() const 
Number of real elements of the pane. 
int size_of_halfedges() const 
Number of halfedges of the pane. 
int size_of_triangles() const 
Total number of triangles of the pane. 
An adaptor for enumerating node IDs of an element. 
int size_of_edges() const 
Number of edges of the pane. 
bool operator==(const Facet_ID e) const 
Comparison operators. 
bool is_real_border_edge(const Edge_ID &eID) const 
Determine whether a given edge is a border edge of real part of the pane (either on physical border o...
bool is_real_node(int vID) const 
Is the given node a real node? 
Edge_ID get_opposite_edge_border(const Edge_ID &eID) const 
Get the opposite edge of a border edge for the whole pane. 
int size_of_ghost_edges() const 
Number of ghost edges of the pane. 
int maxsize_of_elements() const 
Maximum number of elements allowed in the pane. 
int maxsize_of_quadrilaterals() const 
Maximum number of quadrilaterals allowed in the pane. 
Facet_ID(int eid, char lid)
int size_of_quadrilaterals() const 
Total number of quadrilaterals of the pane. 
int size_of_ghost_elements() const 
Number of ghost elements of the pane. 
Simple_manifold_2()
Default constructors. 
#define COM_assertion_msg(EX, msg)
int size_of_ghost_triangles() const 
Number of ghost triangles of the pane. 
Edge_ID get_next_edge_interior(const Edge_ID &eID) const 
const COM::Pane * pane() const 
Obtain a const pointer to the pane. 
char lid() const 
Local edge ID of the halfedge within its element. 
bool is_real_border_node(int vID) const 
Is the node on the pane boundary of real part (not isolated)? 
Simple_manifold_2(const COM::Pane *p, const Simple_manifold_2 *parent=NULL, bool with_ghost=true)
Constructors. 
std::vector< Edge_ID > _ieIDs_ghost
int size_of_faces() const 
Number of elements of the pane. 
int get_a_ghost_border_node() const 
Obtain the ID of a border node of the ghost part of the pane. 
int size_of_real_nodes() const 
Number of real nodes of the pane. 
bool is_border_edge(const Edge_ID &eID) const 
Is a given edge on the boundary of the whole pane? 
int size_of_real_halfedges() const 
Number of real halfedges of the pane. 
int size_of_real_quadrilaterals() const 
Number of real quadrilaterals of the pane. 
int size_of_border_edges() const 
Number of border edges of the whole pane. 
int get_destination(Edge_ID eID, Element_node_enumerator *ene_in=NULL) const 
Get the ID of the destination of a given edge. 
Edge_ID get_incident_real_edge(int vID) const 
Get the ID of an incident real edge within the pane of a given node. 
real *8 function offset(vNorm, x2, y2, z2)
std::vector< Edge_ID > _ieIDs_real_or_str
int get_border_edgeID(Edge_ID eID) const 
Get the border edge index. Return -1 if not a border edge. 
int eid() const 
Element ID of the halfedge. 
int maxsize_of_ghost_quadrilaterals() const 
Maximum number of ghost quadrilaterals allowed in the pane. 
Edge_ID get_opposite_edge(const Edge_ID &eID) const 
Get the ID of the opposite edge of a given interior or border edge. 
int maxsize_of_triangles() const 
Maximum number of triangles allowed in the pane. 
int get_a_border_node() const 
Obtain the ID of a border node. 
int maxsize_of_faces() const 
Maximum number of elements allowed in the pane. 
std::vector< bool > _isghostelmt
int size_of_elements() const 
Number of elements of the pane. 
int maxsize_of_real_nodes() const 
Maximum number of real nodes allowed in the pane. 
Edge_ID get_opposite_real_edge(const Edge_ID &eID) const 
Get the ID of the opposite real edge of a given real or border edge. 
Edge_ID get_opposite_ghost_edge_interior(const Edge_ID &eID) const 
Get the opposite edge of an interior edge of the ghost part. 
Edge_ID get_next_real_edge_interior(const Edge_ID &eID) const 
int maxsize_of_real_elements() const 
Maximum number of real elements allowed in the pane. 
void init(const COM::Pane *p, const Simple_manifold_2 *parent=NULL, bool with_ghost=true)
Initialize the database for the pane, including ghost information, opposite halfedges, incident halfedges, and border halfedges. 
Edge_ID get_next_ghost_edge(const Edge_ID &eID) const 
Get the ID of the next ghost edge of the element or along the boundary. 
int get_edge_index(const Edge_ID &eid, const int offset=0) const 
Get an index for internal edges. 
std::vector< Edge_ID > _oeIDs_ghost
int maxsize_of_ghost_nodes() const 
Maximum number of ghost nodes allowed in the pane. 
int get_a_real_border_node() const 
Obtain the ID of a border node of the real part of the pane. 
Edge_ID get_opposite_edge_interior(const Edge_ID &eID) const 
Get the opposite edge of an interior edge of the whole pane. 
Edge_ID get_opposite_ghost_edge(const Edge_ID &eID) const 
Get the ID of the opposite ghost edge of a given real or border edge. 
Edge_ID get_next_ghost_edge_interior(const Edge_ID &eID) const 
Edge_ID get_prev_ghost_edge(const Edge_ID &eID) const 
Get the ID of the previous ghost edge of the element or along the boundary. 
int maxsize_of_real_faces() const 
Maximum number of real elements allowed in the pane. 
int upperbound_edge_index() const 
Get size of internal edges. 
bool is_ghost_element(int eid) const 
Is the element incident on the give edge a ghost element? 
bool is_ghost_node(int vID) const 
Is the given node a ghost node? 
bool is_real_element(int eid) const 
Is the element incident on the give edge a real element? 
int size_of_real_triangles() const 
Number of real triangles of the pane. 
Provides a data structure accessing nodes, elements, and edges in a pane, in a manner similar to the ...
int maxsize_of_ghost_triangles() const 
Maximum number of ghost triangles allowed in the pane. 
std::vector< int > _isovIDs
Edge_ID get_next_real_edge(const Edge_ID &eID) const 
Get the ID of the next real edge of the element or along the boundary. 
bool operator!=(const Facet_ID e) const 
int size_of_ghost_nodes() const 
Number of ghost nodes of the pane. 
Edge_ID get_prev_edge(const Edge_ID &eID) const 
Get the ID of the previous edge of the element or along the boundary. 
int maxsize_of_real_quadrilaterals() const 
Maximum number of real quadrilaterals allowed in the pane. 
Edge_ID get_opposite_ghost_edge_border(const Edge_ID &eID) const 
Get the opposite edge of a border edge for the ghost pane. 
int size_of_nodes() const 
Number of nodes of the pane. 
Edge_ID get_a_ghost_border_edge() const 
Obtain a border edge on ghost part of the pane. 
Edge_ID get_a_border_edge() const 
Obtain the ID of a border edge of the whole pane. 
int size_of_real_faces() const 
Number of real elements of the pane. 
int size_of_real_edges() const 
Number of real edges of the pane. 
The ID of a facet (edge in 2D and face in 3D) encodes an element ID and the local facet's ID internal...
std::vector< bool > _isghostnode
int size_of_real_border_edges() const 
Number of border edges of the real part of the pane. 
#define MAP_BEGIN_NAMESPACE
bool is_ghost_border_node(int vID) const 
Is the node on pane boundary (not isolated)? It assumes vID is incident on the ghost (no checking is ...
int size_of_ghost_border_edges() const 
Number of border edges of the ghost part of the pane. 
std::vector< Edge_ID > _beIDs
Edge_ID get_prev_real_edge(const Edge_ID &eID) const 
Get the ID of the previous real edge of the element or along the boundary. 
Edge_ID get_opposite_real_edge_border(const Edge_ID &eID) const 
Get the opposite edge of a border edge for the real pane. 
Edge_ID get_prev_ghost_edge_interior(const Edge_ID &eID) const 
int size_of_ghost_quadrilaterals() const 
Number of ghost quadrilaterals of the pane. 
void determine_incident_halfedges()
Determine an incident halfedge for each node. 
int size_of_ghost_halfedges() const 
Number of ghost halfedges of the pane. 
int get_origin(Edge_ID eID, Element_node_enumerator *ene_in=NULL) const 
Get the ID of the origin of a given edge. 
bool is_border_node(int vID) const 
Is the node on pane boundary (not isolated)? 
Edge_ID get_opposite_real_edge_interior(const Edge_ID &eID) const 
Get the opposite edge of an interior edge of the real part. 
bool operator<(const Facet_ID e) const 
Edge_ID get_prev_real_edge_interior(const Edge_ID &eID) const 
void determine_ghosts()
Determine the ghost nodes and elements. 
bool is_border() const 
Determines whether the facet is on border. 
int maxsize_of_ghost_faces() const 
Maximum number of ghost elements allowed in the pane. 
void determine_opposite_halfedges()
Determine the opposite halfedges of each halfedge, and identify border halfedge. 
Edge_ID get_next_edge(const Edge_ID &eID) const 
Get the ID of the next edge of the element or along the boundary. 
int size_of_isolated_nodes() const 
Number of isolated nodes. 
bool is_isolated_node(int vID) const 
Is the node isolated (i.e. not incident on any element)? 
Edge_ID get_incident_edge(int vID) const 
Get the ID of an incident edge within the pane of a given node that originated from the node...
int maxsize_of_ghost_elements() const 
Maximum number of ghost elements allowed in the pane.