OGS
PointRule1.h
Go to the documentation of this file.
1
11#pragma once
12
13#include "MeshLib/MeshEnums.h"
14#include "Element.h"
15#include "VertexRule.h"
16#include "EdgeReturn.h"
17
18namespace MeshLib
19{
20
22class PointRule1 : public VertexRule
23{
24public:
26 static const unsigned n_base_nodes = 1u;
27
29 static const unsigned n_all_nodes = 1u;
30
33
36
38 static const unsigned n_neighbors = 2;
39
41 static const unsigned edge_nodes[1][1];
42
45
52 static bool isPntInElement(Node const* const* nodes,
53 MathLib::Point3d const& pnt, double eps);
54
56 static ElementErrorCode validate(const Element* e);
57
59 static unsigned identifyFace(Node const* const* /*element_nodes*/,
60 Node const* nodes[1]);
61
63 static double computeVolume(Node const* const* element_nodes);
64};
65} // namespace MeshLib
Definition of the Element class.
Definition of mesh-related Enumerations.
Collects error flags for mesh elements.
Returns always null pointer.
Definition EdgeReturn.h:20
A 0d point element.
Definition PointRule1.h:23
static bool isPntInElement(Node const *const *nodes, MathLib::Point3d const &pnt, double eps)
static ElementErrorCode validate(const Element *e)
Tests if the element is geometrically valid.
static const MeshElemType mesh_elem_type
Constant: The geometric type of the element.
Definition PointRule1.h:32
static const unsigned edge_nodes[1][1]
Constant: Local node index table for edge.
Definition PointRule1.h:41
static unsigned identifyFace(Node const *const *, Node const *nodes[1])
Returns the ID of a face given an array of nodes.
static const CellType cell_type
Constant: The FEM type of the element.
Definition PointRule1.h:35
static const unsigned n_base_nodes
Constant: The number of base nodes for this element.
Definition PointRule1.h:26
static const unsigned n_neighbors
Constant: The number of neighbors.
Definition PointRule1.h:38
static double computeVolume(Node const *const *element_nodes)
Calculates the length of a line.
static const unsigned n_all_nodes
Constant: The number of all nodes for this element.
Definition PointRule1.h:29
CellType
Types of mesh elements supported by OpenGeoSys.
Definition MeshEnums.h:43
MeshElemType
Types of mesh elements supported by OpenGeoSys. Values are from VTKCellType enum.
Definition MeshEnums.h:27