FEI Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder > Class Template Reference

#include <fei_DofMapper.hpp>

Public Types

typedef std::map< Dof
< LocalOrdinal, GlobalOrdinal >
, GlobalOrdinal, DofOrder > 
DofMap
 
typedef std::map
< GlobalOrdinal, const Dof
< LocalOrdinal, GlobalOrdinal > * > 
IdxMap
 
typedef std::map< LocalOrdinal,
LocalOrdinal > 
FieldSizeMap
 

Public Member Functions

 DofMapper ()
 
 ~DofMapper ()
 
void addDOF (LocalOrdinal rank, GlobalOrdinal id, LocalOrdinal field)
 
void setFieldSize (LocalOrdinal field, LocalOrdinal field_size)
 
LocalOrdinal getFieldSize (LocalOrdinal field) const
 
GlobalOrdinal getGlobalIndex (LocalOrdinal rank, GlobalOrdinal id, LocalOrdinal field) const
 
std::pair< const Dof
< LocalOrdinal, GlobalOrdinal >
*, LocalOrdinal > 
getDof (GlobalOrdinal global_index) const
 
bool maps_are_valid () const
 
void set_maps_are_valid (bool flag)
 
DofMap::const_iterator begin_dof () const
 
DofMap::const_iterator end_dof () const
 
DofMap::iterator begin_dof ()
 
DofMap::iterator end_dof ()
 
IdxMap::const_iterator begin_idx () const
 
IdxMap::const_iterator end_idx () const
 
IdxMap::iterator begin_idx ()
 
IdxMap::iterator end_idx ()
 
const DofMapget_dof_idx_map () const
 
DofMapget_dof_idx_map ()
 
const IdxMapget_idx_dof_map () const
 
IdxMapget_idx_dof_map ()
 
const FieldSizeMapgetFieldSizeMap () const
 

Private Member Functions

 DofMapper (const DofMapper< LocalOrdinal, GlobalOrdinal > &src)
 
DofMapperoperator= (const DofMapper< LocalOrdinal, GlobalOrdinal > &src)
 

Private Attributes

std::map< Dof< LocalOrdinal,
GlobalOrdinal >, GlobalOrdinal,
DofOrder > 
m_dof_idx
 
std::map< GlobalOrdinal, const
Dof< LocalOrdinal,
GlobalOrdinal > * > 
m_idx_dof
 
bool m_maps_are_valid
 
std::map< LocalOrdinal,
LocalOrdinal > 
m_field_sizes
 

Detailed Description

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
class fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >

A mapping from mesh-degrees-of-freedom (dofs) to equation-numbers.

Mesh-dofs are represented by fei::Dof, see fei_Dof.hpp for details.

Equation numbers are also called global indices. They are globally-unique and zero-based.

A 'dof' may correspond to multiple global-indices if the dof's field has multiple scalar components, e.g. a vector field such as velocity in 3D.

Fields are assumed to be scalar fields (have 1 component) unless a field-size is set using the setFieldSize method.

Definition at line 42 of file fei_DofMapper.hpp.

Member Typedef Documentation

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
typedef std::map<Dof<LocalOrdinal,GlobalOrdinal>,GlobalOrdinal,DofOrder> fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::DofMap

Definition at line 74 of file fei_DofMapper.hpp.

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
typedef std::map<GlobalOrdinal,const Dof<LocalOrdinal,GlobalOrdinal>*> fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::IdxMap

Definition at line 88 of file fei_DofMapper.hpp.

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
typedef std::map<LocalOrdinal,LocalOrdinal> fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::FieldSizeMap

Definition at line 108 of file fei_DofMapper.hpp.

Constructor & Destructor Documentation

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::DofMapper ( )
inline

constructor

Definition at line 45 of file fei_DofMapper.hpp.

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::~DofMapper ( )
inline

destructor

Definition at line 49 of file fei_DofMapper.hpp.

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::DofMapper ( const DofMapper< LocalOrdinal, GlobalOrdinal > &  src)
private

Member Function Documentation

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
void fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::addDOF ( LocalOrdinal  rank,
GlobalOrdinal  id,
LocalOrdinal  field 
)
inline
template<class LocalOrdinal , class GlobalOrdinal , class DofOrder >
void fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::setFieldSize ( LocalOrdinal  field,
LocalOrdinal  field_size 
)

Set the specified field to have the specified field_size. 'field' is added to the internal field map if not already present. If 'field' is already present, its field_size is reset to the new value.

Definition at line 124 of file fei_DofMapper.hpp.

template<class LocalOrdinal , class GlobalOrdinal , class DofOrder >
LocalOrdinal fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::getFieldSize ( LocalOrdinal  field) const

Definition at line 137 of file fei_DofMapper.hpp.

Referenced by fei::set_dof_mappings().

template<class LocalOrdinal , class GlobalOrdinal , class DofOrder >
GlobalOrdinal fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::getGlobalIndex ( LocalOrdinal  rank,
GlobalOrdinal  id,
LocalOrdinal  field 
) const

Definition at line 151 of file fei_DofMapper.hpp.

template<class LocalOrdinal , class GlobalOrdinal , class DofOrder >
std::pair< const Dof< LocalOrdinal, GlobalOrdinal > *, LocalOrdinal > fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::getDof ( GlobalOrdinal  global_index) const

Definition at line 167 of file fei_DofMapper.hpp.

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
bool fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::maps_are_valid ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
void fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::set_maps_are_valid ( bool  flag)
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMap::const_iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::begin_dof ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMap::const_iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::end_dof ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMap::iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::begin_dof ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMap::iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::end_dof ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
IdxMap::const_iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::begin_idx ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
IdxMap::const_iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::end_idx ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
IdxMap::iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::begin_idx ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
IdxMap::iterator fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::end_idx ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
const DofMap& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::get_dof_idx_map ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMap& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::get_dof_idx_map ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
const IdxMap& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::get_idx_dof_map ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
IdxMap& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::get_idx_dof_map ( )
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
const FieldSizeMap& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::getFieldSizeMap ( ) const
inline
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
DofMapper& fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::operator= ( const DofMapper< LocalOrdinal, GlobalOrdinal > &  src)
private

Member Data Documentation

template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
std::map<Dof<LocalOrdinal, GlobalOrdinal>, GlobalOrdinal, DofOrder > fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::m_dof_idx
private
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
std::map<GlobalOrdinal, const Dof<LocalOrdinal, GlobalOrdinal>*> fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::m_idx_dof
private
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
bool fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::m_maps_are_valid
private
template<class LocalOrdinal, class GlobalOrdinal, class DofOrder = less_rank_id_field<LocalOrdinal, GlobalOrdinal>>
std::map<LocalOrdinal,LocalOrdinal> fei::DofMapper< LocalOrdinal, GlobalOrdinal, DofOrder >::m_field_sizes
private

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