Element Class Reference
Last update: 16.07.2025Repesents the geometry of a finite element within a mesh. More...
Public Types | |
| typedef size_t | count_type |
| a large numbereger for index algebra | |
| typedef std::vector< Edge *> | edge_ptr_vector_type |
| a Edge pointer vector | |
| typedef Element * | element_ptr_type |
| a pointer to Element | |
| typedef element::ElementData * | elementdata_const_ptr_type |
| a pointer to a const-address of ElementData | |
| typedef element::ElementData * | elementdata_ptr_type |
| a pointer to ElementData | |
| typedef element::ET * | elementtype_const_ptr_type |
| a pointer to element types ET | |
| typedef std::vector< Face *> | face_ptr_vector_type |
| a Face pointer vector | |
| typedef number | float_type |
| floating point number type for algebra | |
| typedef number | index_type |
| unsigned index type | |
| typedef Point * | point_ptr_type |
| a pointer of Point | |
| typedef std::vector< point_ptr_type > | point_ptr_vector_type |
| a Point pointer vector | |
| typedef std::vector< unsigned short > | small_index_vector_type |
| a vector of small unsigned index types | |
| typedef number | uint |
| number type | |
Public Member Functions | |
| computeLinearNodeCoordinates (Eigen::MatrixXd input_coors, Eigen::MatrixXd output_coors) | |
| number | computeSurfaceArea () |
| Computes the surface area of the element Collects all the element faces, checks which of them are on the elements surface, gets the triangulation of these faces and computes the sum of these triangle areas. More... | |
| Element () | |
| default constructor, DO NOT USE - provided for SWIG | |
| edge_ptr_vector_type | elementEdges () const |
| returns the edges of the element More... | |
| face_ptr_vector_type | elementFaces () const |
| returns the faces of the element More... | |
| point_ptr_vector_type | elementNodes () const |
| returns the nodes of the element More... | |
| element::ET | elementType () const |
| returns the element type: More... | |
| string | elementTypeString () |
| returns the element type: More... | |
| getNormal (Eigen::Vector3d output_normal) | |
| index_type | index () |
| returns the element index: More... | |
| bool | isDegenerated () |
| small_index_vector_type | localElementAtNode () |
| a getter for m_local_element_at_node More... | |
| small_index_vector_type | localElementAtNodeRef () |
| a setter for m_local_element_at_node More... | |
| Point | nodeAt (number id) |
| accesses inidividual connected nodes More... | |
| number | numNodes () const |
| index_type | part_index () |
| returns the part index: More... | |
| recomputeNodeCoordinatesMidEdge (Eigen::MatrixXd input_coors, Eigen::MatrixXd output_coors) | |
| Section | section () const |
| a getter for the element section: More... | |
Detailed Description
Repesents the geometry of a finite element within a mesh.
This class represents the geometrical instance of a finite element contained in a FEM mesh. The class associates the geometry and the topology of the mesh (and the finite element type). It does not provide information/methods on the underlying physical process.
Member Function Documentation
◆ computeLinearNodeCoordinates()
| computeLinearNodeCoordinates | ( | Eigen::MatrixXd | input_coors, |
| Eigen::MatrixXd | output_coors | ||
| ) |
recomputes the given node coordinates by linear shape functions The computation is done by assumption of an isoparametric approach.
- Parameters
-
input_coors a 3*n matrix containing the coordinates output_coors a 3*n matrix containing the new coordinates
◆ computeSurfaceArea()
| number computeSurfaceArea | ( | ) |
Computes the surface area of the element Collects all the element faces, checks which of them are on the elements surface, gets the triangulation of these faces and computes the sum of these triangle areas.
- Returns
- The surface area.
- Note
- Element surface: An element face is recognized as a surface if the face in question reports to be onSurface() and the ident of the elementType() face in question is not SNEG
◆ elementEdges()
| edge_ptr_vector_type elementEdges | ( | ) | const |
returns the edges of the element
- Returns
- a reference to m_edges
◆ elementFaces()
| face_ptr_vector_type elementFaces | ( | ) | const |
returns the faces of the element
- Returns
- a reference to m_faces
◆ elementNodes()
| point_ptr_vector_type elementNodes | ( | ) | const |
returns the nodes of the element
- Returns
- a reference to m_nodes
◆ elementType()
| element::ET elementType | ( | ) | const |
returns the element type:
- Returns
- a reference to *m_type
◆ elementTypeString()
| string elementTypeString | ( | ) |
returns the element type:
- Returns
- a string describing the element number
◆ getNormal()
| getNormal | ( | Eigen::Vector3d | output_normal | ) |
define the normal by average of triangles defined on the element
- Returns
- the normalized vector
◆ index()
| index_type index | ( | ) |
returns the element index:
- Returns
- a reference to m_index
◆ isDegenerated()
| bool isDegenerated | ( | ) |
- Returns
- true if the element is degenerated An element is degenerated if there are at most 3 non degenerated faces (in this case, there is no volume being spanned).
◆ localElementAtNode()
| small_index_vector_type localElementAtNode | ( | ) |
a getter for m_local_element_at_node
- Returns
- a reference to m_local_element_at_node
◆ localElementAtNodeRef()
| small_index_vector_type localElementAtNodeRef | ( | ) |
a setter for m_local_element_at_node
- Returns
- a reference to m_local_element_at_node
◆ nodeAt()
| Point nodeAt | ( | number | id | ) |
accesses inidividual connected nodes
- Parameters
-
id the index 0..numNodes()-1
- Returns
- a const-reference to the connected node
◆ numNodes()
| number numNodes | ( | ) | const |
- Returns
- the number of connected nodes
◆ part_index()
| index_type part_index | ( | ) |
returns the part index:
- Returns
- a reference to m_part_index
◆ recomputeNodeCoordinatesMidEdge()
| recomputeNodeCoordinatesMidEdge | ( | Eigen::MatrixXd | input_coors, |
| Eigen::MatrixXd | output_coors | ||
| ) |
recomputes the given node coordinates by placing the mid-edge nodes in the center of the edges The computation is done by assumption of an isoparametric approach.
- Parameters
-
input_coors a 3*n matrix containing the coordinates output_coors a 3*n matrix containing the new coordinates
◆ section()
| Section section | ( | ) | const |
a getter for the element section:
- Returns
- a reference to m_section