The Reference2DElementInfo class allows to define information about reference two-dimensional elements. More...
Public Member Functions | |
virtual bool | areFacesCCWOrdered () const |
virtual bool | areVerticesCCWOrdered () const |
virtual double | evalArea (const std::array< double, 3 > *vertexCoords) const =0 |
double | evalFaceLength (int face, const std::array< double, 3 > *vertexCoords) const |
virtual std::array< double, 3 > | evalNormal (const std::array< double, 3 > *vertexCoords, const std::array< double, 3 > &point={{0.5, 0.5, 0.5}}) const =0 |
double | evalPerimeter (const std::array< double, 3 > *vertexCoords) const |
double | evalPointDistance (const std::array< double, 3 > &point, const std::array< double, 3 > *vertexCoords) const override |
void | evalPointProjection (const std::array< double, 3 > &point, const std::array< double, 3 > *vertexCoords, std::array< double, 3 > *projection, double *distance) const override |
double | evalSize (const std::array< double, 3 > *vertexCoords) const override |
virtual int | getCCWOrderedFace (int n) const |
virtual int | getCCWOrderedVertex (int n) const |
Protected Member Functions | |
Reference2DElementInfo (ElementType type, int nVertices) | |
void | getCCWVertexCoords (const std::array< double, 3 > *vertexCoords, const std::array< double, 3 > **ccwVertexCoords, std::array< double, 3 > *ccwVertexCoordsStorage) const |
Protected Member Functions inherited from bitpit::ReferenceElementInfo | |
ReferenceElementInfo (int _dimension, ElementType _type, int _nVertices, int _nFaces, int _nEdges) | |
ReferenceElementInfo (ReferenceElementInfo const &)=delete | |
void | initializeFaceEdges (const std::vector< const ReferenceElementInfo * > &facesInfo, const std::vector< const ReferenceElementInfo * > &edgesInfo) |
ReferenceElementInfo & | operator= (ReferenceElementInfo const &)=delete |
Additional Inherited Members | |
Static Public Member Functions inherited from bitpit::ReferenceElementInfo | |
static BITPIT_PUBLIC_API const ReferenceElementInfo & | getInfo (ElementType type) |
static bool | hasInfo (ElementType type) |
Public Attributes inherited from bitpit::ReferenceElementInfo | |
int | dimension |
std::array< std::array< int, MAX_ELEM_VERTICES >, MAX_ELEM_EDGES > | edgeConnectStorage |
std::array< ElementType, MAX_ELEM_EDGES > | edgeTypeStorage |
std::array< std::array< int, MAX_ELEM_VERTICES >, MAX_ELEM_FACES > | faceConnectStorage |
std::array< std::array< int, MAX_ELEM_FACES >, MAX_ELEM_FACES > | faceEdgeStorage |
std::array< ElementType, MAX_ELEM_FACES > | faceTypeStorage |
int | nEdges |
int | nFaces |
int | nVertices |
ElementType | type |
Static Public Attributes inherited from bitpit::ReferenceElementInfo | |
static BITPIT_PUBLIC_API const int | MAX_ELEM_EDGES = 12 |
static BITPIT_PUBLIC_API const int | MAX_ELEM_FACES = 6 |
static BITPIT_PUBLIC_API const int | MAX_ELEM_VERTICES = 8 |
The Reference2DElementInfo class allows to define information about reference two-dimensional elements.
The local numbering scheme of element vertices is shown below.
Definition at line 187 of file element_reference.hpp.
|
protected |
Constructor
type | is the type of element |
nVertices | is the number of vertices |
Definition at line 1071 of file element_reference.cpp.
|
virtual |
Check if the faces are ordered counter-clockwise.
Reimplemented in bitpit::ReferencePixelInfo.
Definition at line 1208 of file element_reference.cpp.
|
virtual |
Check if the vertices are ordered counter-clockwise.
Reimplemented in bitpit::ReferencePixelInfo.
Definition at line 1184 of file element_reference.cpp.
|
pure virtual |
Implemented in bitpit::ReferenceTriangleInfo, bitpit::ReferencePixelInfo, and bitpit::ReferenceQuadInfo.
double bitpit::Reference2DElementInfo::evalFaceLength | ( | int | face, |
const std::array< double, 3 > * | vertexCoords ) const |
Evaluates the length of the specified face of a two-dimensional element with the given vertex coordinates.
face | is the face |
vertexCoords | are the coordinate of the vertices |
Definition at line 1126 of file element_reference.cpp.
|
pure virtual |
Implemented in bitpit::ReferenceTriangleInfo, bitpit::ReferencePixelInfo, and bitpit::ReferenceQuadInfo.
double bitpit::Reference2DElementInfo::evalPerimeter | ( | const std::array< double, 3 > * | vertexCoords | ) | const |
Evaluates the perimeter of a two-dimensional element with the specified vertex coordinates.
vertexCoords | are the coordinate of the vertices |
Definition at line 1108 of file element_reference.cpp.
|
overridevirtual |
Evaluates the distance between the element and the specified point.
[in] | point | is the point |
vertexCoords | are the coordinate of the vertices |
Implements bitpit::ReferenceElementInfo.
Reimplemented in bitpit::ReferenceTriangleInfo.
Definition at line 1167 of file element_reference.cpp.
|
overridevirtual |
Evaluates the projection of the point on the element.
point | is the point | |
vertexCoords | are the coordinate of the vertices | |
[out] | projection | on output contains the projection point |
[out] | distance | on output contains the distance between the point and the projection |
Implements bitpit::ReferenceElementInfo.
Reimplemented in bitpit::ReferenceTriangleInfo.
Definition at line 1147 of file element_reference.cpp.
|
overridevirtual |
Evaluates the characteristics size of an element with the specified vertex coordinates.
The characteristics size is evaluated as the area divided by the length of the longest face.
vertexCoords | are the coordinate of the vertices |
Implements bitpit::ReferenceElementInfo.
Reimplemented in bitpit::ReferenceTriangleInfo, and bitpit::ReferencePixelInfo.
Definition at line 1086 of file element_reference.cpp.
|
virtual |
Get the index of the face occupying the n-th position in the counter-clockwise ordered list of faces.
n | is the requested position |
Reimplemented in bitpit::ReferencePixelInfo.
Definition at line 1221 of file element_reference.cpp.
|
virtual |
Get the index of the vertex occupying the n-th position in the counter-clockwise ordered list of vertices.
n | is the requested position |
Reimplemented in bitpit::ReferencePixelInfo.
Definition at line 1197 of file element_reference.cpp.
|
protected |
Gets the vertex coordinates ordered counter-clockwise.
If the input vertex coordintaes are already ordered, the function will only make the output vertex coordinates point the input ones, otherwise a full reoredr will be perfromed (the re-ordered coordinates will be stored in the storage provided by the user).
vertexCoords | are the coordinates of the vertices | |
[out] | ccwVertexCoords | on output will contain the coordinates of the vertices ordered counter-clockwise |
[out] | ccwVertexCoordsStorage | if a re-ordered is needed, this is the storage that will contain the ordered coordinates |
Definition at line 1240 of file element_reference.cpp.