OpenFCST: The open-source Fuel Cell Simulation Toolbox
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members
FuelCellShop::Equation::EquationBase< dim > Class Template Reference

This class contains generic data and methods heavily used by all derived equation classes. More...

#include <equation_base.h>

Inheritance diagram for FuelCellShop::Equation::EquationBase< dim >:
Inheritance graph
[legend]
Collaboration diagram for FuelCellShop::Equation::EquationBase< dim >:
Collaboration graph
[legend]

Public Member Functions

Local CG FEM based assemblers
virtual void assemble_cell_matrix (AppFrame::MatrixVector &cell_matrices, const typename AppFrame::DoFApplication< dim >::CellInfo &cell_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 Assemble local cell matrix.
 
virtual void assemble_cell_residual (AppFrame::FEVector &cell_residual, const typename AppFrame::DoFApplication< dim >::CellInfo &cell_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 Assemble local cell residual.
 
virtual void assemble_bdry_matrix (AppFrame::MatrixVector &bdry_matrices, const typename AppFrame::DoFApplication< dim >::FaceInfo &bdry_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 Assemble local boundary matrix.
 
virtual void assemble_bdry_residual (AppFrame::FEVector &bdry_residual, const typename AppFrame::DoFApplication< dim >::FaceInfo &bdry_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 Assemble local boundary residual.
 
Accessors and info
const couplings_mapget_internal_cell_couplings () const
 This function returns internal_cell_couplings of a derived equation class.
 
const couplings_mapget_internal_flux_couplings () const
 This function returns internal_flux_couplings (DG FEM only) of a derived equation class.
 
const
component_materialID_value_map
get_component_materialID_value () const
 This function returns component_materialID_value of a derived equation class.
 
const
component_boundaryID_value_map
get_component_boundaryID_value () const
 This function returns component_boundaryID_value of a derived equation class.
 
const std::vector< BoundaryType > & get_boundary_types () const
 This function returns boundary_types of a derived equation class.
 
const std::vector< std::vector
< BoundaryType > > & 
get_multi_boundary_types () const
 This function returns multi_boundary_types of a derived equation class.
 
const std::vector< OutputType > & get_output_types () const
 This function returns output_types of a derived equation class.
 
const std::vector< std::vector
< OutputType > > & 
get_multi_output_types () const
 This function returns multi_output_types of a derived equation class.
 
const std::string & get_equation_name () const
 This function returns equation_name of a derived equation class.
 
const std::vector< unsigned int > & get_matrix_block_indices () const
 This function returns matrix_block_indices of a derived equation class.
 
const std::vector< unsigned int > & get_residual_indices () const
 This function returns residual_indices of a derived equation class.
 
virtual void print_equation_info () const
 This function prints out the equations info of a derived equation class.
 

Protected Member Functions

Constructors, destructor, and initialization
 EquationBase (FuelCell::SystemManagement &system_management)
 Constructor.
 
virtual ~EquationBase ()
 Destructor.
 
virtual void declare_parameters (ParameterHandler &param) const
 Declare parameters.
 
virtual void initialize (ParameterHandler &param)
 Initialize parameters.
 
Local CG FEM based assemblers - make_ functions
virtual void make_assemblers_generic_constant_data ()
 This function is overridden in the derived equation classes.
 
virtual void make_assemblers_cell_constant_data (const typename AppFrame::DoFApplication< dim >::CellInfo &cell_info)
 This function is overridden in the derived equation classes.
 
virtual void make_assemblers_bdry_constant_data (const typename AppFrame::DoFApplication< dim >::FaceInfo &bdry_info)
 This function is overridden in the derived equation classes.
 
virtual void make_assemblers_cell_variable_data (const typename AppFrame::DoFApplication< dim >::CellInfo &cell_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 This function is overridden in the derived equation classes.
 
virtual void make_assemblers_bdry_variable_data (const typename AppFrame::DoFApplication< dim >::FaceInfo &bdry_info, FuelCellShop::Layer::BaseLayer< dim > *const layer)
 This function is overridden in the derived equation classes.
 
Other - make_ functions
virtual void make_internal_cell_couplings ()
 This function fills out internal_cell_couplings of a derived equation class.
 
virtual void make_internal_flux_couplings ()
 This function fills out internal_flux_couplings (DG FEM only) of a derived equation class.
 
virtual void make_component_materialID_value ()
 This function fills out component_materialID_value of a derived equation class.
 
virtual void make_component_boundaryID_value ()
 This function fills out component_boundaryID_value of a derived equation class.
 
virtual void make_boundary_types ()
 This function fills out boundary_types of a derived equation class.
 
virtual void make_multi_boundary_types ()
 This function fills out multi_boundary_types of a derived equation class.
 
virtual void make_output_types ()
 This function fills out output_types of a derived equation class.
 
virtual void make_multi_output_types ()
 This function fills out multi_output_types of a derived equation class.
 
virtual void make_matrix_block_indices ()
 This function fills out matrix_block_indices of a derived equation class.
 
virtual void make_residual_indices ()
 This function fills out residual_indices of a derived equation class.
 
Converters
void standard_to_block_wise (FullMatrix< double > &target) const
 This function changes the order of dealii::FullMatrix<double> target from standard to block-wise.
 
void standard_to_block_wise (Vector< double > &target) const
 This function changes the order of dealii::Vector<double> target from standard to block-wise.
 
void dealII_to_appframe (AppFrame::MatrixVector &dst, const FullMatrix< double > &src, const std::vector< unsigned int > &matrix_block_indices) const
 This function converts the standard ordered structure dealii::FullMatrix<double> src into the block-wise ordered structure AppFrame::MatrixVector dst.
 
void dealII_to_appframe (AppFrame::FEVector &dst, const Vector< double > &src, const std::vector< unsigned int > &residual_indices) const
 This function converts the standard ordered structure dealii::Vector<double> src into the block-wise ordered structure AppFrame::FEVector dst.
 
Other functions
bool belongs_to_boundary (const unsigned int &tria_boundary_id, const unsigned int &param_boundary_id) const
 This function returns true if a boundary indicator of an external face on the triangulation coincides with a boundary indicator defined in the parameters file of a derived equation class.
 
Minor functions
void print_caller_name (const std::string &caller_name) const
 This function is used to print out the name of another function that has been declared in the scope of this class, but not yet been implemented.
 

Protected Attributes

Local CG FEM based assemblers - constant data (generic)
unsigned int dofs_per_cell
 Number of degrees of freedom per cell.
 
Local CG FEM based assemblers - constant data (cell)
unsigned int n_q_points_cell
 Number of quadrature points per cell.
 
Local CG FEM based assemblers - constant data (boundary)
unsigned int n_q_points_bdry
 Number of quadrature points per boundary.
 
Local CG FEM based assemblers - variable data (active mesh iterators)
DoFHandler< dim >
::active_cell_iterator 
cell
 Currently active DoFHandler<dim> active cell iterator.
 
DoFHandler< dim >
::active_face_iterator 
bdry
 Currently active DoFHandler<dim> active boundary iterator.
 
Local CG FEM based assemblers - variable data (other - cell)

Implementation is in the derived equation classes.

std::vector< double > JxW_cell
 Jacobian of mapping by Weight in the quadrature points of a cell.
 
Local CG FEM based assemblers - variable data (other - boundary)

Implementation is in the derived equation classes.

std::vector< double > JxW_bdry
 Jacobian of mapping by Weight in the quadrature points of a boundary.
 
std::vector< Point< dim > > normal_vectors
 Normal vectors in the quadrature points of a boundary.
 
std::vector< std::vector
< Point< dim > > > 
tangential_vectors
 Tangential vectors in the quadrature points of a boundary.
 
GENERIC DATA
FuelCell::SystemManagementsystem_management
 Pointer to the external YourApplication<dim>::system_management object.
 
couplings_map internal_cell_couplings
 This object contains the info on how the equations and solution variables of a derived equation class are coupled.
 
couplings_map internal_flux_couplings
 This object contains the info on how the "X" and "Y" of a derived equation class are coupled (DG FEM only).
 
component_materialID_value_map component_materialID_value
 This object reflects the following structure (see FuelCell::InitialAndBoundaryData namespace docs):
 
component_boundaryID_value_map component_boundaryID_value
 This object reflects the following structure (see FuelCell::InitialAndBoundaryData namespace docs):
 
std::vector< BoundaryTypeboundary_types
 The list of boundary types of a derived equation class.
 
std::vector< std::vector
< BoundaryType > > 
multi_boundary_types
 The list of multiple boundary types of a derived equation class.
 
std::vector< OutputTypeoutput_types
 The list of output types of a derived equation class.
 
std::vector< std::vector
< OutputType > > 
multi_output_types
 The list of multiple output types of a derived equation class.
 
std::string equation_name
 The name of a derived equation class.
 
std::vector< unsigned int > matrix_block_indices
 The system matrix block indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).
 
std::vector< unsigned int > residual_indices
 The residual indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).
 
std::vector< bool > counter
 This vector contains the collection of internal "counters" used by the derived equation classes.
 

Detailed Description

template<int dim>
class FuelCellShop::Equation::EquationBase< dim >

This class contains generic data and methods heavily used by all derived equation classes.

This class is used to lock the interface of all derived equation classes under the FuelCellShop::Equation namespace.

The functionality of this class can be extended if needed.

Author
Valentin N. Zingan, 2012
Marc Secanell Gallart, 2012

Constructor & Destructor Documentation

template<int dim>
FuelCellShop::Equation::EquationBase< dim >::EquationBase ( FuelCell::SystemManagement system_management)
protected

Constructor.

template<int dim>
virtual FuelCellShop::Equation::EquationBase< dim >::~EquationBase ( )
protectedvirtual

Destructor.

Member Function Documentation

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::assemble_bdry_matrix ( AppFrame::MatrixVector bdry_matrices,
const typename AppFrame::DoFApplication< dim >::FaceInfo &  bdry_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlinevirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::assemble_bdry_residual ( AppFrame::FEVector bdry_residual,
const typename AppFrame::DoFApplication< dim >::FaceInfo &  bdry_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlinevirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::assemble_cell_matrix ( AppFrame::MatrixVector cell_matrices,
const typename AppFrame::DoFApplication< dim >::CellInfo &  cell_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlinevirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::assemble_cell_residual ( AppFrame::FEVector cell_residual,
const typename AppFrame::DoFApplication< dim >::CellInfo &  cell_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlinevirtual
template<int dim>
bool FuelCellShop::Equation::EquationBase< dim >::belongs_to_boundary ( const unsigned int &  tria_boundary_id,
const unsigned int &  param_boundary_id 
) const
inlineprotected

This function returns true if a boundary indicator of an external face on the triangulation coincides with a boundary indicator defined in the parameters file of a derived equation class.

template<int dim>
void FuelCellShop::Equation::EquationBase< dim >::dealII_to_appframe ( AppFrame::MatrixVector dst,
const FullMatrix< double > &  src,
const std::vector< unsigned int > &  matrix_block_indices 
) const
protected

This function converts the standard ordered structure dealii::FullMatrix<double> src into the block-wise ordered structure AppFrame::MatrixVector dst.

matrix_block_indices is the system matrix block indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).

template<int dim>
void FuelCellShop::Equation::EquationBase< dim >::dealII_to_appframe ( AppFrame::FEVector dst,
const Vector< double > &  src,
const std::vector< unsigned int > &  residual_indices 
) const
protected

This function converts the standard ordered structure dealii::Vector<double> src into the block-wise ordered structure AppFrame::FEVector dst.

residual_indices is the residual indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::declare_parameters ( ParameterHandler &  param) const
inlineprotectedvirtual
template<int dim>
const std::vector< BoundaryType >& FuelCellShop::Equation::EquationBase< dim >::get_boundary_types ( ) const
inline

This function returns boundary_types of a derived equation class.

template<int dim>
const component_boundaryID_value_map& FuelCellShop::Equation::EquationBase< dim >::get_component_boundaryID_value ( ) const
inline

This function returns component_boundaryID_value of a derived equation class.

template<int dim>
const component_materialID_value_map& FuelCellShop::Equation::EquationBase< dim >::get_component_materialID_value ( ) const
inline

This function returns component_materialID_value of a derived equation class.

template<int dim>
const std::string& FuelCellShop::Equation::EquationBase< dim >::get_equation_name ( ) const
inline

This function returns equation_name of a derived equation class.

template<int dim>
const couplings_map& FuelCellShop::Equation::EquationBase< dim >::get_internal_cell_couplings ( ) const
inline

This function returns internal_cell_couplings of a derived equation class.

template<int dim>
const couplings_map& FuelCellShop::Equation::EquationBase< dim >::get_internal_flux_couplings ( ) const
inline

This function returns internal_flux_couplings (DG FEM only) of a derived equation class.

template<int dim>
const std::vector<unsigned int>& FuelCellShop::Equation::EquationBase< dim >::get_matrix_block_indices ( ) const
inline

This function returns matrix_block_indices of a derived equation class.

template<int dim>
const std::vector< std::vector< BoundaryType > >& FuelCellShop::Equation::EquationBase< dim >::get_multi_boundary_types ( ) const
inline

This function returns multi_boundary_types of a derived equation class.

template<int dim>
const std::vector< std::vector< OutputType > >& FuelCellShop::Equation::EquationBase< dim >::get_multi_output_types ( ) const
inline

This function returns multi_output_types of a derived equation class.

template<int dim>
const std::vector< OutputType >& FuelCellShop::Equation::EquationBase< dim >::get_output_types ( ) const
inline

This function returns output_types of a derived equation class.

template<int dim>
const std::vector<unsigned int>& FuelCellShop::Equation::EquationBase< dim >::get_residual_indices ( ) const
inline

This function returns residual_indices of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::initialize ( ParameterHandler &  param)
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_assemblers_bdry_constant_data ( const typename AppFrame::DoFApplication< dim >::FaceInfo &  bdry_info)
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_assemblers_bdry_variable_data ( const typename AppFrame::DoFApplication< dim >::FaceInfo &  bdry_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_assemblers_cell_constant_data ( const typename AppFrame::DoFApplication< dim >::CellInfo &  cell_info)
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_assemblers_cell_variable_data ( const typename AppFrame::DoFApplication< dim >::CellInfo &  cell_info,
FuelCellShop::Layer::BaseLayer< dim > *const  layer 
)
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_assemblers_generic_constant_data ( )
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_boundary_types ( )
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_component_boundaryID_value ( )
inlineprotectedvirtual

This function fills out component_boundaryID_value of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_component_materialID_value ( )
inlineprotectedvirtual

This function fills out component_materialID_value of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_internal_cell_couplings ( )
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_internal_flux_couplings ( )
inlineprotectedvirtual

This function fills out internal_flux_couplings (DG FEM only) of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_matrix_block_indices ( )
inlineprotectedvirtual

This function fills out matrix_block_indices of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_multi_boundary_types ( )
inlineprotectedvirtual

This function fills out multi_boundary_types of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_multi_output_types ( )
inlineprotectedvirtual

This function fills out multi_output_types of a derived equation class.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_output_types ( )
inlineprotectedvirtual
template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::make_residual_indices ( )
inlineprotectedvirtual

This function fills out residual_indices of a derived equation class.

template<int dim>
void FuelCellShop::Equation::EquationBase< dim >::print_caller_name ( const std::string &  caller_name) const
protected

This function is used to print out the name of another function that has been declared in the scope of this class, but not yet been implemented.

template<int dim>
virtual void FuelCellShop::Equation::EquationBase< dim >::print_equation_info ( ) const
inlinevirtual
template<int dim>
void FuelCellShop::Equation::EquationBase< dim >::standard_to_block_wise ( FullMatrix< double > &  target) const
protected

This function changes the order of dealii::FullMatrix<double> target from standard to block-wise.

template<int dim>
void FuelCellShop::Equation::EquationBase< dim >::standard_to_block_wise ( Vector< double > &  target) const
protected

This function changes the order of dealii::Vector<double> target from standard to block-wise.

Member Data Documentation

template<int dim>
DoFHandler<dim>::active_face_iterator FuelCellShop::Equation::EquationBase< dim >::bdry
protected

Currently active DoFHandler<dim> active boundary iterator.

template<int dim>
std::vector< BoundaryType > FuelCellShop::Equation::EquationBase< dim >::boundary_types
protected

The list of boundary types of a derived equation class.

template<int dim>
DoFHandler<dim>::active_cell_iterator FuelCellShop::Equation::EquationBase< dim >::cell
protected

Currently active DoFHandler<dim> active cell iterator.

template<int dim>
component_boundaryID_value_map FuelCellShop::Equation::EquationBase< dim >::component_boundaryID_value
protected

This object reflects the following structure (see FuelCell::InitialAndBoundaryData namespace docs):

  • first argument : name of the solution component,
  • second argument : boundary id,
  • third argument : value of the solution component.
template<int dim>
component_materialID_value_map FuelCellShop::Equation::EquationBase< dim >::component_materialID_value
protected

This object reflects the following structure (see FuelCell::InitialAndBoundaryData namespace docs):

  • first argument : name of the solution component,
  • second argument : material id,
  • third argument : value of the solution component.
template<int dim>
std::vector<bool> FuelCellShop::Equation::EquationBase< dim >::counter
protected

This vector contains the collection of internal "counters" used by the derived equation classes.

template<int dim>
unsigned int FuelCellShop::Equation::EquationBase< dim >::dofs_per_cell
protected

Number of degrees of freedom per cell.

template<int dim>
std::string FuelCellShop::Equation::EquationBase< dim >::equation_name
protected

The name of a derived equation class.

Referenced by FuelCellShop::Equation::NewFicksTransportEquation< dim >::set_solute_and_solvent().

template<int dim>
couplings_map FuelCellShop::Equation::EquationBase< dim >::internal_cell_couplings
protected

This object contains the info on how the equations and solution variables of a derived equation class are coupled.

template<int dim>
couplings_map FuelCellShop::Equation::EquationBase< dim >::internal_flux_couplings
protected

This object contains the info on how the "X" and "Y" of a derived equation class are coupled (DG FEM only).

template<int dim>
std::vector<double> FuelCellShop::Equation::EquationBase< dim >::JxW_bdry
protected

Jacobian of mapping by Weight in the quadrature points of a boundary.

template<int dim>
std::vector<double> FuelCellShop::Equation::EquationBase< dim >::JxW_cell
protected

Jacobian of mapping by Weight in the quadrature points of a cell.

template<int dim>
std::vector<unsigned int> FuelCellShop::Equation::EquationBase< dim >::matrix_block_indices
protected

The system matrix block indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).

template<int dim>
std::vector< std::vector< BoundaryType > > FuelCellShop::Equation::EquationBase< dim >::multi_boundary_types
protected

The list of multiple boundary types of a derived equation class.

template<int dim>
std::vector< std::vector< OutputType > > FuelCellShop::Equation::EquationBase< dim >::multi_output_types
protected

The list of multiple output types of a derived equation class.

template<int dim>
unsigned int FuelCellShop::Equation::EquationBase< dim >::n_q_points_bdry
protected

Number of quadrature points per boundary.

template<int dim>
unsigned int FuelCellShop::Equation::EquationBase< dim >::n_q_points_cell
protected

Number of quadrature points per cell.

template<int dim>
std::vector< Point<dim> > FuelCellShop::Equation::EquationBase< dim >::normal_vectors
protected

Normal vectors in the quadrature points of a boundary.

template<int dim>
std::vector< OutputType > FuelCellShop::Equation::EquationBase< dim >::output_types
protected

The list of output types of a derived equation class.

template<int dim>
std::vector<unsigned int> FuelCellShop::Equation::EquationBase< dim >::residual_indices
protected

The residual indices (a derived equation class) drawn from the global structure (a derived equation class + other active equation classes included into the computation).

template<int dim>
FuelCell::SystemManagement* FuelCellShop::Equation::EquationBase< dim >::system_management
protected

Pointer to the external YourApplication<dim>::system_management object.

template<int dim>
std::vector< std::vector< Point<dim> > > FuelCellShop::Equation::EquationBase< dim >::tangential_vectors
protected

Tangential vectors in the quadrature points of a boundary.


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