ug4
ug::DoFDistributionInfo Class Reference

#include <dof_distribution_info.h>

+ Inheritance diagram for ug::DoFDistributionInfo:

Classes

struct  FctInfo
 

Public Types

enum  { NOT_DEF_ON_SUBSET = (size_t) - 1 }
 indication that function is not defined on a subset More...
 
enum  { NOT_YET_ASSIGNED = (size_t) - 2 }
 indication that function is not defined on a subset More...
 
enum  { NOT_SPECIFIED = CommonLocalDoFSet::NOT_SPECIFIED }
 indicate not set value More...
 

Public Member Functions

 DoFDistributionInfo (ConstSmartPtr< ISubsetHandler > spSH)
 constructor More...
 
void init ()
 initializes the DoFs More...
 
size_t max_dofs (const GridBaseObjectId gbo) const
 returns the maximum number of dofs on a grid base object type More...
 
size_t max_dofs (const GridBaseObjectId gbo, const int si) const
 returns the maximum number of dofs on a grid base object on a subset More...
 
size_t max_dofs (const int dim) const
 returns the maximum number of dofs on grid objects in a dimension More...
 
size_t max_dofs (const int dim, const int si) const
 returns the maximum number of dofs in a dimension on a subset More...
 
size_t max_dofs (const ReferenceObjectID roid) const
 returns the maximum number of dofs on reference object type More...
 
size_t max_fct_dofs (const size_t fct, const GridBaseObjectId gbo) const
 returns the maximal number of dofs on a base object type for a function component More...
 
size_t max_fct_dofs (const size_t fct, const GridBaseObjectId gbo, const int si) const
 returns the maximum number of dofs on a grid base object on a subset for a function component More...
 
size_t max_fct_dofs (const size_t fct, const int dim, const int si) const
 returns the maximum number of dofs in a dimension on a subset for a function component More...
 
size_t max_fct_dofs (const size_t fct, const ReferenceObjectID roid) const
 returns the number of dofs on a reference object for a function component More...
 
size_t max_fct_dofs (const size_t fct, int dim) const
 returns the maximal number of dofs on a dimension for a function component More...
 
size_t num_dofs (const ReferenceObjectID roid, const int si) const
 returns the number of dofs on a Reference Object on a subset More...
 
size_t num_fct_dofs (const size_t fct, const ReferenceObjectID roid, const int si) const
 returns the number of dofs on a Reference Object on a subset for a function component More...
 
size_t offset (const ReferenceObjectID roid, const int si, const size_t fct) const
 returns the offset for reference element, subset and function More...
 
void print_local_dof_statistic () const
 prints statistic on local dof distribution More...
 
void print_local_dof_statistic (int verboseLev) const
 prints informations More...
 
- Public Member Functions inherited from ug::FunctionPattern
void add (const std::vector< std::string > &vName, LFEID id)
 add single solutions of LocalShapeFunctionSetID to the entire domain More...
 
void add (const std::vector< std::string > &vName, LFEID id, const std::vector< std::string > &vSubset)
 add single solutions of LocalShapeFunctionSetID to selected subsets More...
 
SubsetGroup all_subsets_grp_except_for (const char *names) const
 returns a subset group consisting of all the subsets in the domain except for the specified ones More...
 
void clear ()
 clear all functions More...
 
int dim (size_t fct) const
 returns the dimension in which solution lives More...
 
int dim_subset (int si) const
 dimension of subset More...
 
size_t fct_id (size_t loc_fct, int si) const
 returns function id of the loc_fct's function on subset si More...
 
size_t fct_id_by_name (const char *name) const
 returns the function id if function with given name found in pattern, exception else More...
 
 FunctionPattern (ConstSmartPtr< ISubsetHandler > spSH)
 Default Constructor. More...
 
bool is_def_everywhere (size_t fct) const
 returns true if the discrete function nr_fct is defined on all subsets More...
 
bool is_def_in_subset (size_t fct, int si) const
 returns true if the discrete function nr_fct is defined on subset si More...
 
bool is_locked () const
 returns if pattern is locked More...
 
void lock ()
 lock pattern (i.e. can not be changed then) More...
 
const char * name (size_t fct) const
 returns the name of a discrete function More...
 
std::vector< std::string > names () const
 returns the names of a discrete function More...
 
size_t num_fct () const
 number of discrete functions this dof distributor handles More...
 
size_t num_fct (int si) const
 number of discrete functions on a subset More...
 
int num_subsets () const
 number of subsets More...
 
void set_subset_handler (ConstSmartPtr< ISubsetHandler > spSH)
 sets new subsets handler More...
 
SubsetGroup subset_grp_by_name (const char *names) const
 returns a subset group consisting of the subsets specified by their names More...
 
ConstSmartPtr< ISubsetHandlersubset_handler () const
 get underlying subset handler More...
 
int subset_id_by_name (const char *name) const
 returns the subset id More...
 
const char * subset_name (int si) const
 returns the name of a subset More...
 
virtual ~FunctionPattern ()
 virtual destructor More...
 
const LFEIDlocal_finite_element_id (size_t fct) const
 
const LFEIDlfeid (size_t fct) const
 

Protected Member Functions

void create_offsets ()
 creates offset arrays More...
 

Protected Attributes

std::vector< FctInfom_vFctInfo
 infos for a function component More...
 
size_t m_vMaxDoFsInDim [NUM_GEOMETRIC_BASE_OBJECTS]
 maximum number of DoFs on geometric objects in a dimension More...
 
size_t m_vMaxDoFsOnROID [NUM_REFERENCE_OBJECTS]
 maximum number of DoFs on a reference type More...
 
std::vector< size_t > m_vvMaxDoFsInDimPerSubset [NUM_GEOMETRIC_BASE_OBJECTS]
 maximum number of DoFs on geometric objects in a dimension per subset More...
 
std::vector< size_t > m_vvNumDoFsOnROIDPerSubset [NUM_REFERENCE_OBJECTS]
 number of DoFs on a reference element type on a subset More...
 
- Protected Attributes inherited from ug::FunctionPattern
bool m_bLocked
 
ConstSmartPtr< ISubsetHandlerm_spSH
 
std::vector< Functionm_vFunction
 

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

indication that function is not defined on a subset

Enumerator
NOT_DEF_ON_SUBSET 

◆ anonymous enum

anonymous enum

indication that function is not defined on a subset

Enumerator
NOT_YET_ASSIGNED 

◆ anonymous enum

anonymous enum

indicate not set value

Enumerator
NOT_SPECIFIED 

Constructor & Destructor Documentation

◆ DoFDistributionInfo()

ug::DoFDistributionInfo::DoFDistributionInfo ( ConstSmartPtr< ISubsetHandler spSH)

constructor

Member Function Documentation

◆ create_offsets()

◆ init()

void ug::DoFDistributionInfo::init ( )

initializes the DoFs

References create_offsets(), ug::FunctionPattern::lock(), and PROFILE_FUNC.

◆ max_dofs() [1/5]

size_t ug::DoFDistributionInfo::max_dofs ( const GridBaseObjectId  gbo) const
inline

returns the maximum number of dofs on a grid base object type

References m_vMaxDoFsInDim.

◆ max_dofs() [2/5]

size_t ug::DoFDistributionInfo::max_dofs ( const GridBaseObjectId  gbo,
const int  si 
) const
inline

returns the maximum number of dofs on a grid base object on a subset

References m_vvMaxDoFsInDimPerSubset.

◆ max_dofs() [3/5]

size_t ug::DoFDistributionInfo::max_dofs ( const int  dim) const
inline

returns the maximum number of dofs on grid objects in a dimension

References ug::FunctionPattern::dim(), and m_vMaxDoFsInDim.

◆ max_dofs() [4/5]

size_t ug::DoFDistributionInfo::max_dofs ( const int  dim,
const int  si 
) const
inline

returns the maximum number of dofs in a dimension on a subset

References ug::FunctionPattern::dim(), and m_vvMaxDoFsInDimPerSubset.

◆ max_dofs() [5/5]

size_t ug::DoFDistributionInfo::max_dofs ( const ReferenceObjectID  roid) const
inline

returns the maximum number of dofs on reference object type

References m_vMaxDoFsOnROID.

◆ max_fct_dofs() [1/5]

size_t ug::DoFDistributionInfo::max_fct_dofs ( const size_t  fct,
const GridBaseObjectId  gbo 
) const
inline

returns the maximal number of dofs on a base object type for a function component

References m_vFctInfo.

◆ max_fct_dofs() [2/5]

size_t ug::DoFDistributionInfo::max_fct_dofs ( const size_t  fct,
const GridBaseObjectId  gbo,
const int  si 
) const
inline

returns the maximum number of dofs on a grid base object on a subset for a function component

References m_vFctInfo.

◆ max_fct_dofs() [3/5]

size_t ug::DoFDistributionInfo::max_fct_dofs ( const size_t  fct,
const int  dim,
const int  si 
) const
inline

returns the maximum number of dofs in a dimension on a subset for a function component

References ug::FunctionPattern::dim(), and m_vFctInfo.

◆ max_fct_dofs() [4/5]

size_t ug::DoFDistributionInfo::max_fct_dofs ( const size_t  fct,
const ReferenceObjectID  roid 
) const
inline

returns the number of dofs on a reference object for a function component

References m_vFctInfo.

◆ max_fct_dofs() [5/5]

size_t ug::DoFDistributionInfo::max_fct_dofs ( const size_t  fct,
int  dim 
) const
inline

returns the maximal number of dofs on a dimension for a function component

References ug::FunctionPattern::dim(), and m_vFctInfo.

◆ num_dofs()

size_t ug::DoFDistributionInfo::num_dofs ( const ReferenceObjectID  roid,
const int  si 
) const
inline

returns the number of dofs on a Reference Object on a subset

References m_vvNumDoFsOnROIDPerSubset.

◆ num_fct_dofs()

size_t ug::DoFDistributionInfo::num_fct_dofs ( const size_t  fct,
const ReferenceObjectID  roid,
const int  si 
) const
inline

returns the number of dofs on a Reference Object on a subset for a function component

References m_vFctInfo.

◆ offset()

size_t ug::DoFDistributionInfo::offset ( const ReferenceObjectID  roid,
const int  si,
const size_t  fct 
) const
inline

returns the offset for reference element, subset and function

References m_vFctInfo.

◆ print_local_dof_statistic() [1/2]

void ug::DoFDistributionInfo::print_local_dof_statistic ( ) const
inline

prints statistic on local dof distribution

References print_local_dof_statistic().

Referenced by print_local_dof_statistic().

◆ print_local_dof_statistic() [2/2]

Member Data Documentation

◆ m_vFctInfo

std::vector<FctInfo> ug::DoFDistributionInfo::m_vFctInfo
protected

infos for a function component

Referenced by create_offsets(), max_fct_dofs(), num_fct_dofs(), and offset().

◆ m_vMaxDoFsInDim

size_t ug::DoFDistributionInfo::m_vMaxDoFsInDim[NUM_GEOMETRIC_BASE_OBJECTS]
protected

maximum number of DoFs on geometric objects in a dimension

Referenced by create_offsets(), max_dofs(), and print_local_dof_statistic().

◆ m_vMaxDoFsOnROID

size_t ug::DoFDistributionInfo::m_vMaxDoFsOnROID[NUM_REFERENCE_OBJECTS]
protected

maximum number of DoFs on a reference type

Referenced by create_offsets(), max_dofs(), and print_local_dof_statistic().

◆ m_vvMaxDoFsInDimPerSubset

std::vector<size_t> ug::DoFDistributionInfo::m_vvMaxDoFsInDimPerSubset[NUM_GEOMETRIC_BASE_OBJECTS]
protected

maximum number of DoFs on geometric objects in a dimension per subset

Referenced by create_offsets(), and max_dofs().

◆ m_vvNumDoFsOnROIDPerSubset

std::vector<size_t> ug::DoFDistributionInfo::m_vvNumDoFsOnROIDPerSubset[NUM_REFERENCE_OBJECTS]
protected

number of DoFs on a reference element type on a subset

Referenced by create_offsets(), num_dofs(), and print_local_dof_statistic().


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