8#ifndef __FIELD_ENTSMULTIINDICES_HPP__
9#define __FIELD_ENTSMULTIINDICES_HPP__
39 FieldEntity(
const boost::shared_ptr<Field> field_ptr,
40 const boost::shared_ptr<RefEntity> ref_ents_ptr,
41 boost::shared_ptr<double *const> field_data_adaptor_ptr,
42 boost::shared_ptr<const int> t_max_order_ptr);
60 const boost::shared_ptr<Field> &field_ptr,
61 const boost::shared_ptr<RefEntity> &ref_ents_ptr);
171 (
static_cast<UId>(owner_proc) |
179 return static_cast<int>(
206 constexpr int bit_field_mask = ~(char(0));
207 return static_cast<char>(
231 static_cast<UId>(std::numeric_limits<EntityHandle>::max())
287 template <
typename T = EntityStorage>
307inline boost::shared_ptr<EntityStorage>
308FieldEntity::getSharedStoragePtr<EntityStorage>()
const {
329 return this->
sPtr->getEntFieldData();
334 return this->
sPtr->getOrderNbDofs(order);
339 return this->
sPtr->getOrderNbDofsDiff(order);
344 return this->
sPtr->getMaxOrder();
349 return this->
sPtr->getGlobalUniqueId();
354 return this->
sPtr->getLocalUniqueId();
359 return this->
sPtr->getRefEntityPtr();
376 return this->
sPtr->getDofOrderMap();
380 template <
typename S = EntityStorage>
382 return this->
sPtr->template getSharedStoragePtr<S>();
386 return this->
sPtr->getWeakStoragePtr();
397 const bool reduce_tag_size =
false)
417 boost::shared_ptr<FieldEntity>,
419 ordered_unique<tag<Unique_mi_tag>,
420 member<FieldEntity, UId, &FieldEntity::localUId>>,
421 ordered_non_unique<tag<Ent_mi_tag>,
437 boost::shared_ptr<FieldEntity>,
442 const_mem_fun<FieldEntity, UId, &FieldEntity::getGlobalUniqueId>>
447 boost::shared_ptr<FieldEntity>,
452 ordered_non_unique<tag<Ent_mi_tag>,
459 boost::shared_ptr<FieldEntity>,
465 tag<Composite_EntType_and_Space_mi_tag>,
481 boost::shared_ptr<FieldEntity>,
483 ordered_unique<tag<Unique_mi_tag>,
484 member<FieldEntity, UId, &FieldEntity::localUId>>,
485 ordered_non_unique<tag<Ent_mi_tag>,
#define MAX_DOFS_ON_ENTITY
Maximal number of DOFs on entity.
#define MAX_PROCESSORS_NUMBER
Maximal number of processors.
FieldSpace
approximation spaces
multi_index_container< boost::shared_ptr< FieldEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, const_mem_fun< FieldEntity, UId, &FieldEntity::getGlobalUniqueId > > > > FieldEntity_multiIndex_global_uid_view
multi-index view on DofEntity by uid
multi_index_container< boost::shared_ptr< FieldEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, member< FieldEntity, UId, &FieldEntity::localUId > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< FieldEntity::interface_type_RefEntity, EntityHandle, &FieldEntity::getEnt > > > > FieldEntity_multiIndex
MultiIndex container keeps FieldEntity.
FieldEntity_multiIndex::index< Unique_mi_tag >::type FieldEntityByUId
Entity index by field name.
int ApproximationOrder
Approximation on the entity.
VectorShallowArrayAdaptor< double > VectorAdaptor
char FieldBitNumber
Field bit number.
implementation of Data Operators for Forces and Sources
auto getVectorAdaptor(T1 ptr, const size_t n)
Get Vector adaptor.
multi_index_container< boost::shared_ptr< FieldEntity >, indexed_by< sequenced<>, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< FieldEntity::interface_type_RefEntity, EntityHandle, &FieldEntity::getEnt > > > > FieldEntity_multiIndex_ent_view
std::vector< boost::weak_ptr< FieldEntity > > FieldEntity_vector_view
multi_index_container< boost::shared_ptr< FieldEntity >, indexed_by< sequenced<>, ordered_non_unique< tag< Composite_EntType_and_Space_mi_tag >, composite_key< FieldEntity, const_mem_fun< FieldEntity::interface_type_RefEntity, EntityType, &FieldEntity::getEntType >, const_mem_fun< FieldEntity::interface_type_Field, FieldSpace, &FieldEntity::getSpace > > > > > FieldEntity_multiIndex_spaceType_view
multi_index_container< boost::shared_ptr< FieldEntity >, indexed_by< ordered_unique< tag< Unique_mi_tag >, member< FieldEntity, UId, &FieldEntity::localUId > >, ordered_non_unique< tag< Ent_mi_tag >, const_mem_fun< FieldEntity::interface_type_RefEntity, EntityHandle, &FieldEntity::getEnt > > > > FieldEntity_multiIndex
virtual ~EntityStorage()=default
structure to change FieldEntity order
FieldEntity_change_order(const ApproximationOrder order, const bool reduce_tag_size=false)
const ApproximationOrder order
void operator()(boost::shared_ptr< FieldEntity > &e)
std::vector< FieldData > data
Struct keeps handle to entity in the field.
static constexpr int dof_shift
static UId getHiBitNumberUId(const FieldBitNumber bit_number)
friend std::ostream & operator<<(std::ostream &os, const FieldEntity &e)
static auto getHandleFromUniqueId(const UId uid)
Get the Handle From Unique Id.
static auto getFieldBitNumberFromUniqueId(const UId uid)
Get the Field Bit Number From Unique Id.
int getOrderNbDofsDiff(ApproximationOrder order) const
Get difference of number of DOFs between order and order-1.
int getNbDofsOnEnt() const
Get number of active DOFs on entity.
UId getLocalUniqueIdCalculate()
Get the Local Unique Id Calculate object.
static UId getHiFieldEntityUId(const UId &uid)
boost::shared_ptr< FieldData *const > fieldDataAdaptorPtr
static boost::shared_ptr< FieldData *const > makeSharedFieldDataAdaptorPtr(const boost::shared_ptr< Field > &field_ptr, const boost::shared_ptr< RefEntity > &ref_ents_ptr)
Return shared pointer to entity field data vector adaptor.
static UId getLoBitNumberUId(const FieldBitNumber bit_number)
static constexpr int proc_shift
static UId getLoLocalEntityBitNumber(const char bit_number, const EntityHandle ent)
boost::shared_ptr< FieldData *const > & getEntFieldDataPtr() const
Get shared ptr to vector adaptor pointing to the field tag data on entity.
boost::weak_ptr< EntityStorage > & getWeakStoragePtr() const
boost::weak_ptr< EntityCacheDofs > entityCacheDataDofs
interface_Field< Field, RefEntity > interface_type_Field
ApproximationOrder getMaxOrder() const
Get order set to the entity (Allocated tag size for such number)
const ApproximationOrder * getMaxOrderPtr() const
Get pinter to Tag keeping approximation order.
interface_RefEntity< RefEntity > interface_type_RefEntity
void getHiFieldEntityUId(T &uid)=delete
UId localUId
Local unique id for this entity. Unique on CPU partition.
static UId getGlobalUniqueIdCalculate(const int owner_proc, const char bit_number, const EntityHandle moab_owner_handle)
Calculate UId for field entity.
void getLoFieldEntityUId(T &uid)=delete
static constexpr int ent_shift
static UId getLoFieldEntityUId(const UId &uid)
boost::weak_ptr< EntityCacheNumeredDofs > entityCacheRowDofs
const UId & getLocalUniqueId() const
Get global unique id.
boost::weak_ptr< EntityCacheNumeredDofs > entityCacheColDofs
boost::weak_ptr< EntityStorage > weakStoragePtr
int getOrderNbDofs(ApproximationOrder order) const
Get number of DOFs on entity for given order of approximation.
virtual ~FieldEntity()=default
static UId getLocalUniqueIdCalculate(const char bit_number, const EntityHandle handle)
Get the Local Unique Id Calculate.
UId getGlobalUniqueId() const
Get global unique id.
static UId getHiLocalEntityBitNumber(const char bit_number, const EntityHandle ent)
static auto getOwnerFromUniqueId(const UId uid)
const std::array< int, MAX_DOFS_ON_ENTITY > & getDofOrderMap() const
get hash-map relating dof index on entity with its order
VectorAdaptor getEntFieldData() const
Get vector of DOFs active values on entity.
boost::shared_ptr< const ApproximationOrder > tagMaxOrderPtr
UId getGlobalUniqueIdCalculate() const
Calculate global UId.
boost::shared_ptr< T > getSharedStoragePtr() const
Get the Weak Storage pointer.
const std::array< ApproximationOrder, MAX_DOFS_ON_ENTITY > & getDofOrderMap(const EntityType type) const
get hash-map relating dof index on entity with its order
Interface to FieldEntity.
interface_FieldEntity(const boost::shared_ptr< T > &sptr)
const std::array< int, MAX_DOFS_ON_ENTITY > & getDofOrderMap() const
get hash-map relating dof index on entity with its order
boost::weak_ptr< EntityStorage > & getWeakStoragePtr() const
int getOrderNbDofsDiff(ApproximationOrder order) const
boost::shared_ptr< S > getSharedStoragePtr() const
Get the Weak Storage pointer.
boost::shared_ptr< FieldEntity > & getFieldEntityPtr() const
UId getGlobalUniqueId() const
int getOrderNbDofs(ApproximationOrder order) const
ApproximationOrder getMaxOrder() const
VectorAdaptor getEntFieldData() const
int getNbDofsOnEnt() const
UId & getLocalUniqueId() const
boost::shared_ptr< RefEntity > & getRefEntityPtr() const
FieldBitNumber getBitNumber() const
FieldCoefficientsNumber getNbOfCoeffs() const
const Field * getFieldRawPtr() const
FieldSpace getSpace() const
boost::shared_ptr< T > sPtr
EntityHandle getOwnerEnt() const
EntityType getEntType() const
boost::shared_ptr< REFENT > & getRefEntityPtr() const
EntityHandle getEnt() const