ASPECT
Public Member Functions | Protected Attributes | List of all members
aspect::FEVariableCollection< dim > Class Template Reference
Inheritance diagram for aspect::FEVariableCollection< dim >:
Inheritance graph
[legend]

Public Member Functions

 FEVariableCollection ()
 
 FEVariableCollection (const std::vector< VariableDeclaration< dim > > &variable_definitions)
 
void initialize (const std::vector< VariableDeclaration< dim > > &variable_definitions)
 
const FEVariable< dim > & variable (const std::string &name) const
 
bool variable_exists (const std::string &name) const
 
const std::vector< FEVariable< dim > > & get_variables () const
 
unsigned int n_components () const
 
unsigned int n_blocks () const
 
const std::vector< const FiniteElement< dim > * > & get_fes () const
 
const std::vector< unsigned int > & get_multiplicities () const
 
const std::vector< unsigned int > & get_components_to_blocks () const
 

Protected Attributes

std::vector< FEVariable< dim > > variables
 
unsigned int n_components_
 
unsigned int n_blocks_
 
std::vector< const FiniteElement< dim > * > fes
 
std::vector< unsigned int > multiplicities
 
std::vector< unsigned int > components_to_blocks
 

Detailed Description

template<int dim>
class aspect::FEVariableCollection< dim >

A class that represents a collection of variables (of type FEVariable) to form a Finite Element system. A FESystem can be constructed from it using get_fes() and get_multiplicities(). Other information contained in this class on top of FESystem are names, and the block structure for linear systems.

Definition at line 181 of file fe_variable_collection.h.

Constructor & Destructor Documentation

§ FEVariableCollection() [1/2]

template<int dim>
aspect::FEVariableCollection< dim >::FEVariableCollection ( )

Construct an empty object.

§ FEVariableCollection() [2/2]

template<int dim>
aspect::FEVariableCollection< dim >::FEVariableCollection ( const std::vector< VariableDeclaration< dim > > &  variable_definitions)

Construct object from a vector of variables (identical to calling initialize()).

Member Function Documentation

§ initialize()

template<int dim>
void aspect::FEVariableCollection< dim >::initialize ( const std::vector< VariableDeclaration< dim > > &  variable_definitions)

Fill this object with the given list of variables.

§ variable()

template<int dim>
const FEVariable<dim>& aspect::FEVariableCollection< dim >::variable ( const std::string &  name) const

Return the variable with name name. Throws an exception if this variable does not exist.

§ variable_exists()

template<int dim>
bool aspect::FEVariableCollection< dim >::variable_exists ( const std::string &  name) const

Returns true if the variable with name exists in the list of variables.

§ get_variables()

template<int dim>
const std::vector<FEVariable<dim> >& aspect::FEVariableCollection< dim >::get_variables ( ) const

Return the list of all variables.

§ n_components()

template<int dim>
unsigned int aspect::FEVariableCollection< dim >::n_components ( ) const

Return the total number of components in the system.

§ n_blocks()

template<int dim>
unsigned int aspect::FEVariableCollection< dim >::n_blocks ( ) const

Return the total number of block of the system.

§ get_fes()

template<int dim>
const std::vector<const FiniteElement<dim> *>& aspect::FEVariableCollection< dim >::get_fes ( ) const

Return the vector of finite element spaces used for the construction of the FESystem.

§ get_multiplicities()

template<int dim>
const std::vector<unsigned int>& aspect::FEVariableCollection< dim >::get_multiplicities ( ) const

Return the vector of multiplicities used for the construction of the FESystem.

§ get_components_to_blocks()

template<int dim>
const std::vector<unsigned int>& aspect::FEVariableCollection< dim >::get_components_to_blocks ( ) const

Return a variable that describes for each vector component which vector block it corresponds to.

Member Data Documentation

§ variables

template<int dim>
std::vector<FEVariable<dim> > aspect::FEVariableCollection< dim >::variables
protected

A std::vector that contains a collection of variables.

Definition at line 249 of file fe_variable_collection.h.

§ n_components_

template<int dim>
unsigned int aspect::FEVariableCollection< dim >::n_components_
protected

Total number of components of all variables, returned by n_components().

Definition at line 254 of file fe_variable_collection.h.

§ n_blocks_

template<int dim>
unsigned int aspect::FEVariableCollection< dim >::n_blocks_
protected

Total number of blocks of all variables, returned by n_blocks().

Definition at line 259 of file fe_variable_collection.h.

§ fes

template<int dim>
std::vector<const FiniteElement<dim> *> aspect::FEVariableCollection< dim >::fes
protected

Data to be used in the FESystem constructor. The get_fes() function returns a reference to this array.

The pointers stored in this area are not owned by the current object, but are instead pointers to the finite elements owned by the elements of the variables array. As a consequence, we do not need to explicitly manage the deallocation of these pointers.

Definition at line 270 of file fe_variable_collection.h.

§ multiplicities

template<int dim>
std::vector<unsigned int> aspect::FEVariableCollection< dim >::multiplicities
protected

Data to be used in the FESystem constructor, returned by get_multiplicities().

Definition at line 275 of file fe_variable_collection.h.

§ components_to_blocks

template<int dim>
std::vector<unsigned int> aspect::FEVariableCollection< dim >::components_to_blocks
protected

Mapping from component to block, returned by get_components_to_blocks().

Definition at line 280 of file fe_variable_collection.h.


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