MFEM v2.0
Public Types | Public Member Functions | Protected Attributes
Element Class Reference

Abstract data type element. More...

#include <element.hpp>

Inheritance diagram for Element:
Inheritance graph
[legend]

List of all members.

Public Types

enum  Type {
  POINT, SEGMENT, TRIANGLE, QUADRILATERAL,
  TETRAHEDRON, HEXAHEDRON, BISECTED, QUADRISECTED,
  OCTASECTED
}
 Constants for the classes derived from Element. More...

Public Member Functions

 Element (int bg=Geometry::POINT)
 Default element constructor.
virtual void SetVertices (const int *ind)
 Set the indices the element according to the input.
virtual int GetType () const =0
 Returns element's type.
int GetGeometryType () const
virtual void GetVertices (Array< int > &v) const =0
 Returns element's vertices.
virtual int * GetVertices ()=0
virtual int GetNVertices () const =0
virtual int GetNEdges () const =0
virtual const int * GetEdgeVertices (int) const =0
virtual void MarkEdge (DenseMatrix &pmat)
 Mark the longest edge by assuming/changing the order of the vertices.
virtual void MarkEdge (const DSTable &v_to_v, const int *length)
 Mark the longest edge by assuming/changing the order of the vertices.
virtual int NeedRefinement (DSTable &v_to_v, int *middle) const
 Return 1 if the element needs refinement in order to get conforming mesh.
int GetAttribute () const
 Return element's attribute.
void SetAttribute (const int attr)
 Set element's attribute.
virtual int GetRefinementFlag ()
virtual ElementDuplicate (Mesh *m) const =0
virtual ~Element ()
 Destroys element.

Protected Attributes

int attribute
 Element's attribute (specifying material property, etc).
int base_geom

Detailed Description

Abstract data type element.

Definition at line 18 of file element.hpp.


Member Enumeration Documentation

Constants for the classes derived from Element.

Enumerator:
POINT 
SEGMENT 
TRIANGLE 
QUADRILATERAL 
TETRAHEDRON 
HEXAHEDRON 
BISECTED 
QUADRISECTED 
OCTASECTED 

Definition at line 28 of file element.hpp.


Constructor & Destructor Documentation

Element::Element ( int  bg = Geometry::POINT) [inline, explicit]

Default element constructor.

Definition at line 32 of file element.hpp.

References attribute, and base_geom.

virtual Element::~Element ( ) [inline, virtual]

Destroys element.

Definition at line 73 of file element.hpp.


Member Function Documentation

virtual Element* Element::Duplicate ( Mesh m) const [pure virtual]
int Element::GetAttribute ( ) const [inline]

Return element's attribute.

Definition at line 63 of file element.hpp.

References attribute.

Referenced by Mesh::Bisection(), Mesh::PrintElement(), RefinedElement::RefinedElement(), and RefinedElement::SetCoarseElem().

virtual const int* Element::GetEdgeVertices ( int  ) const [pure virtual]
int Element::GetGeometryType ( ) const [inline]

Definition at line 40 of file element.hpp.

References base_geom.

Referenced by Mesh::PrintElement(), and RefinedElement::SetCoarseElem().

virtual int Element::GetNEdges ( ) const [pure virtual]
virtual int Element::GetNVertices ( ) const [pure virtual]
virtual int Element::GetRefinementFlag ( ) [inline, virtual]

Reimplemented in Tetrahedron.

Definition at line 68 of file element.hpp.

virtual int Element::GetType ( ) const [pure virtual]
virtual void Element::GetVertices ( Array< int > &  v) const [pure virtual]
virtual int* Element::GetVertices ( ) [pure virtual]
virtual void Element::MarkEdge ( DenseMatrix pmat) [inline, virtual]

Mark the longest edge by assuming/changing the order of the vertices.

Reimplemented in RefinedElement, Tetrahedron, and Triangle.

Definition at line 54 of file element.hpp.

Referenced by RefinedElement::MarkEdge().

virtual void Element::MarkEdge ( const DSTable v_to_v,
const int *  length 
) [inline, virtual]

Mark the longest edge by assuming/changing the order of the vertices.

Reimplemented in RefinedElement, Tetrahedron, and Triangle.

Definition at line 57 of file element.hpp.

virtual int Element::NeedRefinement ( DSTable v_to_v,
int *  middle 
) const [inline, virtual]

Return 1 if the element needs refinement in order to get conforming mesh.

Reimplemented in RefinedElement, Tetrahedron, and Triangle.

Definition at line 60 of file element.hpp.

Referenced by RefinedElement::NeedRefinement().

void Element::SetAttribute ( const int  attr) [inline]

Set element's attribute.

Definition at line 66 of file element.hpp.

References attribute.

Referenced by Mesh::AddTet(), Mesh::Bisection(), Tetrahedron::Duplicate(), Mesh::Load(), and Mesh::ReadElement().

void Element::SetVertices ( const int *  ind) [virtual]

Set the indices the element according to the input.

Reimplemented in RefinedElement, Quadrilateral, Segment, Tetrahedron, and Triangle.

Definition at line 15 of file element.cpp.

References GetNVertices(), and GetVertices().

Referenced by RefinedElement::SetVertices().


Member Data Documentation

int Element::attribute [protected]
int Element::base_geom [protected]

Definition at line 23 of file element.hpp.

Referenced by Element(), GetGeometryType(), and RefinedElement::SetCoarseElem().


The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines