Reference documentation for deal.II version 8.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Private Attributes | List of all members
FiniteElementData< dim > Class Template Reference

#include <fe_base.h>

Inheritance diagram for FiniteElementData< dim >:
[legend]

Public Types

enum  Conformity {
  unknown = 0x00, L2 = 0x01, Hcurl = 0x02, Hdiv = 0x04,
  H1 = Hcurl | Hdiv, H2 = 0x0e
}
 

Public Member Functions

 FiniteElementData ()
 
 FiniteElementData (const std::vector< unsigned int > &dofs_per_object, const unsigned int n_components, const unsigned int degree, const Conformity conformity=unknown, const unsigned int n_blocks=numbers::invalid_unsigned_int)
 
unsigned int n_dofs_per_vertex () const
 
unsigned int n_dofs_per_line () const
 
unsigned int n_dofs_per_quad () const
 
unsigned int n_dofs_per_hex () const
 
unsigned int n_dofs_per_face () const
 
unsigned int n_dofs_per_cell () const
 
template<int structdim>
unsigned int n_dofs_per_object () const
 
unsigned int n_components () const
 
unsigned int n_blocks () const
 
const BlockIndicesblock_indices () const
 
bool is_primitive () const
 
unsigned int tensor_degree () const
 
bool conforms (const Conformity) const
 
bool operator== (const FiniteElementData &) const
 

Public Attributes

const unsigned int dofs_per_vertex
 
const unsigned int dofs_per_line
 
const unsigned int dofs_per_quad
 
const unsigned int dofs_per_hex
 
const unsigned int first_line_index
 
const unsigned int first_quad_index
 
const unsigned int first_hex_index
 
const unsigned int first_face_line_index
 
const unsigned int first_face_quad_index
 
const unsigned int dofs_per_face
 
const unsigned int dofs_per_cell
 
const unsigned int components
 
const unsigned int degree
 
const Conformity conforming_space
 
BlockIndices block_indices_data
 

Static Public Attributes

static const unsigned int dimension = dim
 

Protected Member Functions

void set_primitivity (const bool value)
 

Private Attributes

bool cached_primitivity
 

Detailed Description

template<int dim>
class FiniteElementData< dim >

Dimension independent data for finite elements. See the derived class FiniteElement class for information on its use. All its data are available to the implementation in a concrete finite element class.

Author
Wolfgang Bangerth, Guido Kanschat, 1998, 1999, 2000, 2001, 2003, 2005

Definition at line 137 of file fe_base.h.

Member Enumeration Documentation

template<int dim>
enum FiniteElementData::Conformity

Enumerator for the different types of continuity a finite element may have. Continuity is measured by the Sobolev space containing the constructed finite element space and is also called this way.

Note that certain continuities may imply others. For instance, a function in H1 is in Hcurl and Hdiv as well.

If you are interested in continuity in the classical sense, then the following relations hold:

  1. H1 implies that the function is continuous over cell boundaries.

  2. H2 implies that the function is continuously differentiable over cell boundaries.

  3. L2 indicates that the element is discontinuous. Since discontinuous elements have no topological couplings between grid cells and code may actually depend on this property, L2 conformity is handled in a special way in the sense that it is not implied by any higher conformity.

In order to test if a finite element conforms to a certain space, use FiniteElementData<dim>::conforms().

Enumerator
unknown 

Indicates incompatible continuities of a system.

L2 

Discontinuous elements. See above!

Hcurl 

Conformity with the space Hcurl (continuous tangential component of a vector field)

Hdiv 

Conformity with the space Hdiv (continuous normal component of a vector field)

H1 

Conformity with the space H1 (continuous)

H2 

Conformity with the space H2 (continuously differentiable)

Definition at line 169 of file fe_base.h.

Constructor & Destructor Documentation

template<int dim>
FiniteElementData< dim >::FiniteElementData ( )

Default constructor. Constructs an element with no dofs. Checking n_dofs_per_cell() is therefore a good way to check if something went wrong.

template<int dim>
FiniteElementData< dim >::FiniteElementData ( const std::vector< unsigned int > &  dofs_per_object,
const unsigned int  n_components,
const unsigned int  degree,
const Conformity  conformity = unknown,
const unsigned int  n_blocks = numbers::invalid_unsigned_int 
)

Constructor, computing all necessary values from the distribution of dofs to geometrical objects.

Parameters
dofs_per_objectNumber of dofs on geometrical objects for each dimension. In this vector, entry 0 refers to dofs on vertices, entry 1 on lines and so on. Its length must be dim+1.
n_componentsNumber of vector components of the element.
degreeMaximal polynomial degree in a single direction.
conformityThe finite element space has continuity of this Sobolev space.
n_blocksobsolete and ignored.

Member Function Documentation

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_vertex ( ) const

Number of dofs per vertex.

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_line ( ) const

Number of dofs per line. Not including dofs on lower dimensional objects.

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_quad ( ) const

Number of dofs per quad. Not including dofs on lower dimensional objects.

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_hex ( ) const

Number of dofs per hex. Not including dofs on lower dimensional objects.

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_face ( ) const

Number of dofs per face, accumulating degrees of freedom of all lower dimensional objects.

template<int dim>
unsigned int FiniteElementData< dim >::n_dofs_per_cell ( ) const

Number of dofs per cell, accumulating degrees of freedom of all lower dimensional objects.

template<int dim>
template<int structdim>
unsigned int FiniteElementData< dim >::n_dofs_per_object ( ) const

Return the number of degrees per structdim-dimensional object. For structdim==0, the function therefore returns dofs_per_vertex, for structdim==1 dofs_per_line, etc. This function is mostly used to allow some template trickery for functions that should work on all sorts of objects without wanting to use the different names (vertex, line, ...) associated with these objects.

template<int dim>
unsigned int FiniteElementData< dim >::n_components ( ) const

Number of components. See the glossary for more information.

template<int dim>
unsigned int FiniteElementData< dim >::n_blocks ( ) const

Number of blocks. See the glossary for more information.

template<int dim>
const BlockIndices& FiniteElementData< dim >::block_indices ( ) const

Detailed information on block sizes.

template<int dim>
bool FiniteElementData< dim >::is_primitive ( ) const

Return whether the entire finite element is primitive, in the sense that all its shape functions are primitive. If the finite element is scalar, then this is always the case.

Since this is an extremely common operation, the result is cached in the cached_primitivity variable which is computed in the constructor.

template<int dim>
unsigned int FiniteElementData< dim >::tensor_degree ( ) const

Maximal polynomial degree of a shape function in a single coordinate direction.

This function can be used to determine the optimal quadrature rule.

template<int dim>
bool FiniteElementData< dim >::conforms ( const Conformity  ) const

Test whether a finite element space conforms to a certain Sobolev space.

Note
This function will return a true value even if the finite element space has higher regularity than asked for.
template<int dim>
bool FiniteElementData< dim >::operator== ( const FiniteElementData< dim > &  ) const

Comparison operator.

template<int dim>
void FiniteElementData< dim >::set_primitivity ( const bool  value)
protected

Set the primitivity of the element. This is usually done by the constructor of a derived class. See primitive for details.

Member Data Documentation

template<int dim>
const unsigned int FiniteElementData< dim >::dimension = dim
static

The dimension of the finite element, which is the template parameter dim

Definition at line 209 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_vertex

Number of degrees of freedom on a vertex.

Definition at line 214 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_line

Number of degrees of freedom in a line; not including the degrees of freedom on the vertices of the line.

Definition at line 220 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_quad

Number of degrees of freedom in a quadrilateral; not including the degrees of freedom on the lines and vertices of the quadrilateral.

Definition at line 226 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_hex

Number of degrees of freedom in a hexahedron; not including the degrees of freedom on the quadrilaterals, lines and vertices of the hecahedron.

Definition at line 232 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::first_line_index

First index of dof on a line.

Definition at line 237 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::first_quad_index

First index of dof on a quad.

Definition at line 242 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::first_hex_index

First index of dof on a hexahedron.

Definition at line 247 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::first_face_line_index

First index of dof on a line for face data.

Definition at line 252 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::first_face_quad_index

First index of dof on a quad for face data.

Definition at line 257 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_face

Number of degrees of freedom on a face. This is the accumulated number of degrees of freedom on all the objects of dimension up to dim-1 constituting a face.

Definition at line 264 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::dofs_per_cell

Total number of degrees of freedom on a cell. This is the accumulated number of degrees of freedom on all the objects of dimension up to dim constituting a cell.

Definition at line 271 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::components

Number of vector components of this finite element, and dimension of the image space. For vector-valued finite elements (i.e. when this number is greater than one), the number of vector components is in many cases equal to the number of base elements glued together with the help of the FESystem class. However, for elements like the Nedelec element, the number is greater than one even though we only have one base element.

Definition at line 281 of file fe_base.h.

template<int dim>
const unsigned int FiniteElementData< dim >::degree

Maximal polynomial degree of a shape function in a single coordinate direction.

Definition at line 287 of file fe_base.h.

template<int dim>
const Conformity FiniteElementData< dim >::conforming_space

Indicate the space this element conforms to.

Definition at line 292 of file fe_base.h.

template<int dim>
BlockIndices FiniteElementData< dim >::block_indices_data

Storage for an object describing the sizes of each block of a compound element. For an element which is not an FESystem, this contains only a single block with length dofs_per_cell.

Definition at line 299 of file fe_base.h.

template<int dim>
bool FiniteElementData< dim >::cached_primitivity
private

Store whether all shape functions are primitive. Since finding this out is a very common operation, we cache the result, i.e. compute the value in the constructor for simpler access.

Definition at line 432 of file fe_base.h.


The documentation for this class was generated from the following file: