7#ifndef __DOFSMULTIINDICES_HPP__
8#define __DOFSMULTIINDICES_HPP__
26 const boost::shared_ptr<FieldEntity> &ent_ptr) {
28 (
static_cast<ShortId>(ent_ptr->getBitNumber()) << 9);
31 DofEntity(
const boost::shared_ptr<FieldEntity> &entity_ptr,
46 return this->
sPtr->getLocalUniqueId();
51 return this->
sPtr->getGlobalUniqueId();
60 const boost::shared_ptr<FieldEntity> &ent_ptr) {
94 const boost::shared_ptr<FieldEntity> &ent_ptr) {
164 return this->
sPtr->getGlobalUniqueId();
169 return this->
sPtr->getEntGlobalUniqueId();
177 return this->
sPtr->getEntLocalUniqueId();
182 return this->
sPtr->getNonNonuniqueShortId();
196 return this->
sPtr->getDofOrder();
201 return this->
sPtr->getDofCoeffIdx();
214 return this->
sPtr->getFieldEntityPtr();
258 const int dof_idx = -1,
const int petsc_gloabl_dof_idx = -1,
259 const int petsc_local_dof_idx = -1,
const int part = -1);
292 friend std::ostream &
operator<<(std::ostream &os,
303typedef multi_index_container<
304 boost::shared_ptr<DofEntity>,
309 const_mem_fun<DofEntity, UId, &DofEntity::getLocalUniqueId>>,
314 const_mem_fun<DofEntity, EntityHandle, &DofEntity::getEnt>>
331 multi_index_container<boost::shared_ptr<DofEntity>,
334 ordered_unique<const_mem_fun<
343 boost::shared_ptr<DofEntity>,
347 const_mem_fun<DofEntity, UId, &DofEntity::getGlobalUniqueId>>
359typedef multi_index_container<
360 boost::shared_ptr<DofEntity>,
364 const_mem_fun<DofEntity, UId, &DofEntity::getLocalUniqueId>>,
367 const_mem_fun<DofEntity, char, &DofEntity::getActive>>
378typedef multi_index_container<
379 boost::shared_ptr<FEDofEntity>,
382 ordered_unique<tag<Unique_mi_tag>,
386 ordered_non_unique<tag<Ent_mi_tag>,
405typedef multi_index_container<
406 boost::shared_ptr<FENumeredDofEntity>,
407 indexed_by<ordered_unique<
424 FENumeredDofEntity_multiIndex::index<Unique_mi_tag>::type;
431 FENumeredDofEntity_multiIndex::index<Ent_mi_tag>::type;
438typedef multi_index_container<
439 boost::shared_ptr<NumeredDofEntity>,
443 ordered_unique<tag<Unique_mi_tag>,
450 member<NumeredDofEntity, unsigned int, &NumeredDofEntity::pArt>>,
455 ordered_non_unique<tag<PetscGlobalIdx_mi_tag>,
459 ordered_non_unique<tag<PetscLocalIdx_mi_tag>,
476 NumeredDofEntity_multiIndex::index<Unique_mi_tag>::type;
483 NumeredDofEntity_multiIndex::index<PetscLocalIdx_mi_tag>::type;
490 NumeredDofEntity_multiIndex::index<Ent_mi_tag>::type;
493 multi_index_container<boost::shared_ptr<NumeredDofEntity>,
496 ordered_unique<const_mem_fun<
506 boost::shared_ptr<NumeredDofEntity>,
511 multi_index_container<boost::shared_ptr<NumeredDofEntity>,
512 indexed_by<ordered_non_unique<const_mem_fun<
517 multi_index_container<
518 boost::shared_ptr<NumeredDofEntity>,
519 indexed_by<ordered_non_unique<const_mem_fun<
530 void operator()(boost::shared_ptr<DofEntity> &dof);
541 const DofIdx petsc_gloabl_dof_idx)
543 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
554 const unsigned int part,
const DofIdx mofem_dof_idx,
555 const DofIdx petsc_gloabl_dof_idx)
558 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
569 const DofIdx petsc_gloabl_dof_idx,
570 const DofIdx petsc_local_dof_idx)
573 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
588 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
601 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
616 const unsigned int part,
const DofIdx mofem_idx,
617 const DofIdx petsc_gloabl_dof_idx,
const DofIdx petsc_local_dof_idx)
621 inline void operator()(boost::shared_ptr<NumeredDofEntity> &dof)
const {
multi_index_container< boost::shared_ptr< DofEntity >, indexed_by< ordered_unique< const_mem_fun< DofEntity, UId, &DofEntity::getLocalUniqueId > >, ordered_non_unique< const_mem_fun< DofEntity, char, &DofEntity::getActive > > > > DofEntity_multiIndex_active_view
multi-index view on DofEntity activity
FENumeredDofEntity_multiIndex::index< Ent_mi_tag >::type FENumeredDofEntityByEnt
Numbered DoF multi-index by entity.
multi_index_container< boost::shared_ptr< FENumeredDofEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, const_mem_fun< FENumeredDofEntity::interface_type_DofEntity, UId, &FENumeredDofEntity::getLocalUniqueId > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< FENumeredDofEntity::interface_type_DofEntity, EntityHandle, &FENumeredDofEntity::getEnt > > > > FENumeredDofEntity_multiIndex
MultiIndex container keeps FENumeredDofEntity.
FEDofEntity_multiIndex::index< Unique_mi_tag >::type FEDofEntityByUId
Dof entity multi-index by UId and entity.
multi_index_container< boost::shared_ptr< DofEntity >, indexed_by< ordered_unique< const_mem_fun< DofEntity, UId, &DofEntity::getLocalUniqueId > > > > DofEntity_multiIndex_uid_view
multi-index view on DofEntity by uid
NumeredDofEntity_multiIndex::index< Unique_mi_tag >::type NumeredDofEntityByUId
Numbered DoF multi-index by UId.
DofEntity_multiIndex::index< Ent_mi_tag >::type DofEntityByEnt
Dof multi-index by entity.
multi_index_container< boost::shared_ptr< NumeredDofEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, const_mem_fun< NumeredDofEntity::interface_type_DofEntity, UId, &NumeredDofEntity::getLocalUniqueId > >, ordered_non_unique< tag< Part_mi_tag >, member< NumeredDofEntity, unsigned int, &NumeredDofEntity::pArt > >, ordered_non_unique< tag< Idx_mi_tag >, member< NumeredDofEntity, DofIdx, &NumeredDofEntity::dofIdx > >, ordered_non_unique< tag< PetscGlobalIdx_mi_tag >, member< NumeredDofEntity, DofIdx, &NumeredDofEntity::petscGloablDofIdx > >, ordered_non_unique< tag< PetscLocalIdx_mi_tag >, member< NumeredDofEntity, DofIdx, &NumeredDofEntity::petscLocalDofIdx > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< NumeredDofEntity::interface_type_DofEntity, EntityHandle, &NumeredDofEntity::getEnt > > > > NumeredDofEntity_multiIndex
MultiIndex container keeps NumeredDofEntity.
multi_index_container< boost::shared_ptr< DofEntity >, indexed_by< ordered_unique< const_mem_fun< DofEntity, UId, &DofEntity::getGlobalUniqueId > > > > DofEntity_multiIndex_global_uid_view
multi-index view on DofEntity by uid
std::vector< boost::weak_ptr< DofEntity > > DofEntity_vector_view
vector view on DofEntity by uid
multi_index_container< boost::shared_ptr< FEDofEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, const_mem_fun< FEDofEntity::DofEntity, UId, &FEDofEntity::getLocalUniqueId > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< FEDofEntity::DofEntity, EntityHandle, &FEDofEntity::getEnt > > > > FEDofEntity_multiIndex
MultiIndex container keeps FEDofEntity.
FENumeredDofEntity_multiIndex::index< Unique_mi_tag >::type FENumeredDofEntityByUId
Dof entity multi-index by UId.
multi_index_container< boost::shared_ptr< DofEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, const_mem_fun< DofEntity, UId, &DofEntity::getLocalUniqueId > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< DofEntity, EntityHandle, &DofEntity::getEnt > > > > DofEntity_multiIndex
MultiIndex container keeps DofEntity.
NumeredDofEntity_multiIndex::index< Ent_mi_tag >::type NumeredDofEntityByEnt
Numbered DoF multi-index by entity.
NumeredDofEntity_multiIndex::index< PetscLocalIdx_mi_tag >::type NumeredDofEntityByLocalIdx
Numbered DoF multi-index by local index.
int ApproximationOrder
Approximation on the entity.
int FieldCoefficientsNumber
Number of field coefficients.
char FieldBitNumber
Field bit number.
int ShortId
Unique Id in the field.
implementation of Data Operators for Forces and Sources
std::ostream & operator<<(std::ostream &os, const EntitiesFieldData::EntData &e)
multi_index_container< boost::shared_ptr< NumeredDofEntity >, indexed_by< hashed_unique< const_mem_fun< NumeredDofEntity, DofIdx, &NumeredDofEntity::getDofIdx > > > > NumeredDofEntity_multiIndex_idx_view_hashed
multi_index_container< boost::shared_ptr< NumeredDofEntity >, indexed_by< ordered_non_unique< const_mem_fun< NumeredDofEntity, DofIdx, &NumeredDofEntity::getPetscLocalDofIdx > > > > NumeredDofEntity_multiIndex_petsc_local_dof_view_ordered_non_unique
multi_index_container< boost::shared_ptr< NumeredDofEntity >, indexed_by< ordered_non_unique< const_mem_fun< NumeredDofEntity::interface_type_DofEntity, FieldCoefficientsNumber, &NumeredDofEntity::getDofCoeffIdx > > > > NumeredDofEntity_multiIndex_coeff_idx_ordered_non_unique
DofEntity_multiIndex::index< Unique_mi_tag >::type DofEntityByUId
multi_index_container< boost::shared_ptr< NumeredDofEntity >, indexed_by< ordered_unique< const_mem_fun< NumeredDofEntity::interface_type_DofEntity, UId, &NumeredDofEntity::getLocalUniqueId > > > > NumeredDofEntity_multiIndex_uid_view_ordered
void operator()(boost::shared_ptr< DofEntity > &dof)
keeps information about DOF on the entity
UId getLocalUniqueId() const
const UId getEntGlobalUniqueId() const
EntityHandle getEnt() const
DofIdx getEntDofIdx() const
static UId getLoFieldEntityUId(const FieldBitNumber bit, const EntityHandle ent)
UId getGlobalUniqueId() const
static UId getHiFieldEntityUId(const FieldBitNumber bit, const EntityHandle ent)
const UId & getEntLocalUniqueId() const
ApproximationOrder getDofOrder() const
FieldData & getFieldData() const
friend std::ostream & operator<<(std::ostream &os, const DofEntity &e)
ShortId getNonNonuniqueShortId() const
get short uid it is unique in combination with entity handle
static ShortId getNonNonuniqueShortId(const DofIdx dof, const boost::shared_ptr< FieldEntity > &ent_ptr)
DofEntity(const boost::shared_ptr< FieldEntity > &entity_ptr, const ApproximationOrder dof_order, const FieldCoefficientsNumber dof_rank, const DofIdx dof)
virtual ~DofEntity()=default
FieldCoefficientsNumber getDofCoeffIdx() const
static UId getUniqueIdCalculate(const DofIdx dof, UId ent_uid)
static UId getGlobalUniqueIdCalculate(const DofIdx dof, const boost::shared_ptr< FieldEntity > &ent_ptr)
Calculate UId for DOF.
static UId getLocalUniqueIdCalculate(const DofIdx dof, const boost::shared_ptr< FieldEntity > &ent_ptr)
keeps information about indexed dofs for the finite element
DofEntity(const boost::shared_ptr< FieldEntity > &entity_ptr, const ApproximationOrder dof_order, const FieldCoefficientsNumber dof_rank, const DofIdx dof)
friend std::ostream & operator<<(std::ostream &os, const FEDofEntity &e)
keeps information about indexed dofs for the finite element
FENumeredDofEntity()=delete
friend std::ostream & operator<<(std::ostream &os, const FENumeredDofEntity &e)
UId getLocalUniqueIdCalculate()
Get the Local Unique Id Calculate object.
static UId getHiFieldEntityUId(const UId &uid)
static UId getLoFieldEntityUId(const UId &uid)
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
NumeredDofEntity_local_idx_change(const DofIdx petsc_local_dof_idx)
const DofIdx petscLocalDofIdx
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
NumeredDofEntity_mofem_index_change(const DofIdx mofem_idx)
NumeredDofEntity_part_and_all_indices_change(const unsigned int part, const DofIdx mofem_idx, const DofIdx petsc_gloabl_dof_idx, const DofIdx petsc_local_dof_idx)
const DofIdx petscGloablDofIdx
const DofIdx petscLocalDofIdx
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
NumeredDofEntity_part_and_glob_idx_change(const unsigned int part, const DofIdx petsc_gloabl_dof_idx)
const DofIdx petscGloablDofIdx
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
const DofIdx petscLocalDofIdx
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
const DofIdx petscGloablDofIdx
NumeredDofEntity_part_and_indices_change(const unsigned int part, const DofIdx petsc_gloabl_dof_idx, const DofIdx petsc_local_dof_idx)
NumeredDofEntity_part_and_mofem_glob_idx_change(const unsigned int part, const DofIdx mofem_dof_idx, const DofIdx petsc_gloabl_dof_idx)
void operator()(boost::shared_ptr< NumeredDofEntity > &dof) const
const DofIdx petscGloablDofIdx
keeps information about indexed dofs for the problem
virtual ~NumeredDofEntity()=default
DofIdx getPetscLocalDofIdx() const
NumeredDofEntity(const boost::shared_ptr< DofEntity > &dof_entity_ptr, const int dof_idx=-1, const int petsc_gloabl_dof_idx=-1, const int petsc_local_dof_idx=-1, const int part=-1)
DofIdx getPetscGlobalDofIdx() const
friend std::ostream & operator<<(std::ostream &os, const NumeredDofEntity &e)
unsigned int getPart() const
interface_DofEntity< DofEntity > interface_type_DofEntity
bool getHasLocalIndex() const
ShortId getNonNonuniqueShortId() const
UId getLocalUniqueId() const
const UId & getEntLocalUniqueId() const
FieldCoefficientsNumber getDofCoeffIdx() const
interface_DofEntity(const boost::shared_ptr< T > &sptr)
virtual ~interface_DofEntity()=default
DofIdx getEntDofIdx() const
boost::shared_ptr< FieldEntity > & getFieldEntityPtr() const
UId getGlobalUniqueId() const
EntityHandle getEnt() const
const UId & getEntGlobalUniqueId() const
boost::shared_ptr< DofEntity > & getDofEntityPtr() const
FieldData & getFieldData() const
ApproximationOrder getDofOrder() const
Interface to FieldEntity.
const std::array< int, MAX_DOFS_ON_ENTITY > & getDofOrderMap() const
get hash-map relating dof index on entity with its order
boost::shared_ptr< FieldEntity > & getFieldEntityPtr() const
UId & getLocalUniqueId() const
FieldCoefficientsNumber getNbOfCoeffs() const
boost::shared_ptr< REFENT > sPtr
EntityHandle getEnt() const