Definition of a 2D finite element. More...
#include <ptems/finiteelement.hpp>
Public Types | |
typedef LegacyRandomAccessIterator< const Vector< 2 > > | iterator |
Type for an iterator over the list of vertices for the element. More... | |
typedef iterator | const_iterator |
Type for a const iterator over the list of vertices for the element. More... | |
typedef std::reverse_iterator< iterator > | reverse_iterator |
Type for an iterator over the list of vertices for the element, iterating in reverse. More... | |
typedef std::reverse_iterator< reverse_iterator > | const_reverse_iterator |
Type for a const iterator over the list of vertices for the element, iterating in reverse. More... | |
typedef LegacyRandomAccessIterator< const PFEFace< 2 > > | faceiterator |
Type for an iterator over the list of faces for the element. More... | |
typedef faceiterator | const_faceiterator |
Type for a const iterator over the list of faces for the element. More... | |
typedef std::reverse_iterator< faceiterator > | reverse_faceiterator |
Type for an iterator over the list of faces for the element, iterating in reverse. More... | |
typedef std::reverse_iterator< const_faceiterator > | const_reverse_faceiterator |
Type for a const iterator over the list of faces for the element, iterating in reverse. More... | |
Public Member Functions | |
std::size_t | Index () const |
The index of the finite element within the mesh,. More... | |
const Vector< 2 > & | operator[] (std::size_t i) const |
Returns the ith vertex of the finite element. More... | |
const Vector< 2 > & | Vertex (std::size_t i) const |
Returns the ith vertex of the finite element. More... | |
std::size_t | VertexIndex (std::size_t i) const |
Returns the index in the mesh of ith vertex of the finite element. More... | |
Vector< 2 > | VertexLocal (std::size_t i) const |
Returns the ith vertex of the finite element in local coordinates. More... | |
iterator | begin () const |
Gets the begin iterator for iterating over the vertices of the element. More... | |
iterator | end () const |
Gets the end iterator for iterating over the vertices of the element. More... | |
const_iterator | cbegin () const |
Gets the const begin iterator for iterating over the vertices of the element. More... | |
const_iterator | cend () const |
Gets the const end iterator for iterating over the vertices of the element. More... | |
reverse_iterator | rbegin () const |
Gets the begin iterator for iterating over the vertices of the element in reverse. More... | |
reverse_iterator | rend () const |
Gets the end iterator for iterating over the vertices of the element in reverse. More... | |
const_reverse_iterator | crbegin () const |
Gets the const begin iterator for iterating over the vertices of the element in reverse. More... | |
const_reverse_iterator | crend () const |
Gets the const end iterator for iterating over the vertices of the element in reverse. More... | |
const PFEFace< 2 > & | Face (std::size_t i) const |
Returns the ith face of the finite element. More... | |
faceiterator | begin_faces () const |
Gets the begin iterator for iterating over the faces of the element. More... | |
faceiterator | end_faces () const |
Gets the end iterator for iterating over the faces of the element. More... | |
const_faceiterator | cbegin_faces () const |
Gets the const begin iterator for iterating over the faces of the element. More... | |
const_faceiterator | cend_faces () const |
Gets the const end iterator for iterating over the faces of the element. More... | |
reverse_faceiterator | rbegin_faces () const |
Gets the begin iterator for iterating over the faces of the element in reverse. More... | |
reverse_faceiterator | rend_faces () const |
Gets the end iterator for iterating over the faces of the element in reverse. More... | |
const_reverse_faceiterator | crbegin_faces () const |
Gets the const begin iterator for iterating over the faces of the element in reverse. More... | |
const_reverse_faceiterator | crend_faces () const |
Gets the const end iterator for iterating over the faces of the element in reverse. More... | |
std::size_t | VertexCount () const |
Gets the number of vertices in the element. More... | |
std::size_t | FaceCount () const |
Gets the number of faces in the element. More... | |
double | Diameter () const |
Gets the diameter of the element. More... | |
double | Volume () const |
Gets the volume of the element. More... | |
Vector< 2 > | Barycentre () const |
Gets the barycentre of the element. More... | |
const std::vector< std::shared_ptr< FiniteElement< 2 > > > & | Agglomerates () const |
Gets the list of base mesh elements if this element is an agglomerated element. More... | |
BBox< 2 > | BoundingBox () const |
Computes the bounding box for the element. More... | |
bool | SetNeighbour (const std::shared_ptr< FiniteElement< 2 >> &element) |
Specify that the specified element is a neighbour of this element. More... | |
std::shared_ptr< FEMesh< 2 > > | Mesh () const |
Gets a reference to the underlying mesh for the element. More... | |
const std::vector< ReferenceMapping< 2 > > & | ReferenceMappings () const |
Gets set of mappings from the element to standard reference elements. More... | |
Vector< 2 > | LocalToGlobal (const Vector< 2 > &pt) |
Converts a local point on the element (local to the reference element if only one reference element, otherwise the bounding box) into a global point. More... | |
Vector< 2 > | GlobalToLocal (const Vector< 2 > &pt) |
Converts a global point into a local point on the element (local to the reference element if only one reference element, otherwise the bounding box) More... | |
template<typename ALGO > | |
QuadraturePoints< 2 > | ComputeQuadraturePoints (ALGO algorithm, std::size_t order) |
Computes the quadrature points for the element. More... | |
T | shared_from_this (T... args) |
T | weak_from_this (T... args) |
Friends | |
class | FEMesh< 2 > |
Definition of a 2D finite element.
typedef faceiterator ptems::FiniteElement< 2 >::const_faceiterator |
Type for a const iterator over the list of faces for the element.
typedef iterator ptems::FiniteElement< 2 >::const_iterator |
Type for a const iterator over the list of vertices for the element.
typedef std::reverse_iterator<const_faceiterator> ptems::FiniteElement< 2 >::const_reverse_faceiterator |
Type for a const iterator over the list of faces for the element, iterating in reverse.
Type for a const iterator over the list of vertices for the element, iterating in reverse.
typedef LegacyRandomAccessIterator< const PFEFace<2> > ptems::FiniteElement< 2 >::faceiterator |
Type for an iterator over the list of faces for the element.
typedef LegacyRandomAccessIterator< const Vector<2> > ptems::FiniteElement< 2 >::iterator |
Type for an iterator over the list of vertices for the element.
Type for an iterator over the list of faces for the element, iterating in reverse.
typedef std::reverse_iterator<iterator> ptems::FiniteElement< 2 >::reverse_iterator |
Type for an iterator over the list of vertices for the element, iterating in reverse.
|
inline |
Gets the list of base mesh elements if this element is an agglomerated element.
List | of base mesh elements, or empty vector if not an agglomerated element |
|
inline |
Gets the barycentre of the element.
|
inline |
Gets the begin iterator for iterating over the vertices of the element.
|
inline |
Gets the begin iterator for iterating over the faces of the element.
|
inline |
Computes the bounding box for the element.
|
inline |
Gets the const begin iterator for iterating over the vertices of the element.
|
inline |
Gets the const begin iterator for iterating over the faces of the element.
|
inline |
Gets the const end iterator for iterating over the vertices of the element.
|
inline |
Gets the const end iterator for iterating over the faces of the element.
|
inline |
Computes the quadrature points for the element.
The points are in local element coordinates, and weights are for the global integration.
ALGO | Type of an algorithm for generating quadrature points on a reference element |
algorithm | An algorithm for generating quadrature points on a reference element |
order | The order of the quadrature |
|
inline |
Gets the const begin iterator for iterating over the vertices of the element in reverse.
|
inline |
Gets the const begin iterator for iterating over the faces of the element in reverse.
|
inline |
Gets the const end iterator for iterating over the vertices of the element in reverse.
|
inline |
Gets the const end iterator for iterating over the faces of the element in reverse.
|
inline |
Gets the diameter of the element.
|
inline |
Gets the end iterator for iterating over the vertices of the element.
|
inline |
Gets the end iterator for iterating over the faces of the element.
|
inline |
Returns the ith face of the finite element.
i | The index of the face to get. |
std::out_of_range | If i is not less than FaceCount() |
|
inline |
Gets the number of faces in the element.
|
inline |
Converts a global point into a local point on the element (local to the reference element if only one reference element, otherwise the bounding box)
pt | The global point to map |
|
inline |
The index of the finite element within the mesh,.
|
inline |
Converts a local point on the element (local to the reference element if only one reference element, otherwise the bounding box) into a global point.
pt | The local point to map |
|
inline |
Gets a reference to the underlying mesh for the element.
|
inline |
Returns the ith vertex of the finite element.
i | The index of the vertex to get. |
std::out_of_range | If i is not less than VertexCount() |
|
inline |
Gets the begin iterator for iterating over the vertices of the element in reverse.
|
inline |
Gets the begin iterator for iterating over the faces of the element in reverse.
|
inline |
Gets set of mappings from the element to standard reference elements.
If the element is a "basic" element a single reference element (reference triangle or reference cube) will be returned; otherwise, if a polygon, the element will be decomposed into sub-triangles and multiple reference triangles will be returned.
|
inline |
Gets the end iterator for iterating over the vertices of the element in reverse.
|
inline |
Gets the end iterator for iterating over the faces of the element in reverse.
|
inline |
Specify that the specified element is a neighbour of this element.
element | The neighbour |
|
inline |
Returns the ith vertex of the finite element.
i | The index of the vertex to get. |
std::out_of_range | If i is not less than VertexCount() |
|
inline |
Gets the number of vertices in the element.
|
inline |
Returns the index in the mesh of ith vertex of the finite element.
i | The index of the vertex to get. |
std::out_of_range | If i is not less than VertexCount() |
|
inline |
Returns the ith vertex of the finite element in local coordinates.
i | The index of the vertex to get. |
std::out_of_range | If i is not less than VertexCount() |
|
inline |
Gets the volume of the element.