v0.8.17
Pointers to multi-indices

Get direct access to multi-indices in database. More...

Collaboration diagram for Pointers to multi-indices:

Get pointers to multi-index database

virtual MoFEMErrorCode MoFEM::CoreInterface::get_fields (const Field_multiIndex **fields_ptr) const =0
 Get fields multi-index from database. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_ref_ents (const RefEntity_multiIndex **refined_ents_ptr) const =0
 Get ref entities multi-index from database. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_ref_finite_elements (const RefElement_multiIndex **refined_finite_elements_ptr) const =0
 Get ref finite elements multi-index form database. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_finite_elements (const FiniteElement_multiIndex **fe_ptr) const =0
 Get finite elements multi-index. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_ents_finite_elements (const EntFiniteElement_multiIndex **fe_ent_ptr) const =0
 Get entities finite elements multi-index. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_problem (const std::string &problem_name, const Problem **problem_ptr) const =0
 Get problem database (data structure) More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_problems (const Problem_multiIndex **problems_ptr) const =0
 Get pointer to problems multi-index. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_field_ents (const FieldEntity_multiIndex **field_ents) const =0
 Get field multi index. More...
 
virtual MoFEMErrorCode MoFEM::CoreInterface::get_dofs (const DofEntity_multiIndex **dofs_ptr) const =0
 Get dofs multi index. More...
 
virtual EntFiniteElementByName::iterator MoFEM::CoreInterface::get_fe_by_name_begin (const std::string &fe_name) const =0
 get begin iterator of finite elements of given name (instead you can use IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT) More...
 
virtual EntFiniteElementByName::iterator MoFEM::CoreInterface::get_fe_by_name_end (const std::string &fe_name) const =0
 get end iterator of finite elements of given name (instead you can use IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT) More...
 
virtual FieldEntityByFieldName::iterator MoFEM::CoreInterface::get_ent_field_by_name_begin (const std::string &field_name) const =0
 get begin iterator of filed ents of given name (instead you can use IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT) More...
 
virtual FieldEntityByFieldName::iterator MoFEM::CoreInterface::get_ent_field_by_name_end (const std::string &field_name) const =0
 get begin iterator of filed dofs of given name (instead you can use IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... } More...
 
virtual DofEntityByFieldName::iterator MoFEM::CoreInterface::get_dofs_by_name_begin (const std::string &field_name) const =0
 get begin iterator of filed dofs of given name (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... } More...
 
virtual DofEntityByFieldName::iterator MoFEM::CoreInterface::get_dofs_by_name_end (const std::string &field_name) const =0
 get begin iterator of filed dofs of given name (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... } More...
 
virtual DofEntityByNameAndEnt::iterator MoFEM::CoreInterface::get_dofs_by_name_and_ent_begin (const std::string &field_name, const EntityHandle ent) const =0
 get begin iterator of filed dofs of given name and ent(instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,ENT,IT) More...
 
virtual DofEntityByNameAndEnt::iterator MoFEM::CoreInterface::get_dofs_by_name_and_ent_end (const std::string &field_name, const EntityHandle ent) const =0
 get begin iterator of filed dofs of given name and ent (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,ENT,IT)for(IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP(MFIELD,NAME,ENT,IT)) { ... } More...
 
template<typename DIT >
MoFEMErrorCode MoFEM::CoreInterface::get_field_dof_data (const std::string &name, const EntityHandle *ent, const int num_ents, DIT dit, int *count=NULL)
 get field data from entity and fieldthis function is not recommended to be used in finite element implementation More...
 
template<typename DIT >
MoFEMErrorCode MoFEM::CoreInterface::get_field_dof_data (const std::string &name, const Range &ents, DIT dit, int *count=NULL)
 get field data from entity and fieldthis function is not recommended to be used in finite element implementation More...
 
virtual DofEntityByNameAndType::iterator MoFEM::CoreInterface::get_dofs_by_name_and_type_begin (const std::string &field_name, const EntityType type) const =0
 get begin iterator of filed dofs of given name and ent type (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,TYPE,IT) More...
 
virtual DofEntityByNameAndType::iterator MoFEM::CoreInterface::get_dofs_by_name_and_type_end (const std::string &field_name, const EntityType type) const =0
 get begin iterator of filed dofs of given name end ent type(instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,TYPE,IT) More...
 
#define _IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_(MFIELD, NAME, ENT, IT)
 loop over all dofs from a moFEM field and particular field More...
 
#define _IT_GET_FES_BY_NAME_FOR_LOOP_(MFIELD, NAME, IT)
 loop over all finite elements from a moFEM field and FE More...
 
#define _IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP_(MFIELD, NAME, IT)
 loop over all dofs from a moFEM field and particular field More...
 
#define _IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP_(MFIELD, NAME, IT)
 
#define _IT_GET_DOFS_FIELD_BY_NAME_AND_TYPE_FOR_LOOP_(MFIELD, NAME, TYPE, IT)
 loop over all dofs from a moFEM field and particular field More...
 

Detailed Description

Get direct access to multi-indices in database.

Macro Definition Documentation

◆ _IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_

#define _IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_ (   MFIELD,
  NAME,
  ENT,
  IT 
)
Value:
DofEntityByNameAndEnt::iterator IT = \
(MFIELD).get_dofs_by_name_and_ent_begin(NAME, ENT); \
IT != (MFIELD).get_dofs_by_name_and_ent_end(NAME, ENT); \
IT++

loop over all dofs from a moFEM field and particular field

Definition at line 1756 of file Interface.hpp.

◆ _IT_GET_DOFS_FIELD_BY_NAME_AND_TYPE_FOR_LOOP_

#define _IT_GET_DOFS_FIELD_BY_NAME_AND_TYPE_FOR_LOOP_ (   MFIELD,
  NAME,
  TYPE,
  IT 
)
Value:
DofEntityByNameAndType::iterator IT = \
(MFIELD).get_dofs_by_name_and_type_begin(NAME, TYPE); \
IT != (MFIELD).get_dofs_by_name_and_type_end(NAME, TYPE); \
IT++

loop over all dofs from a moFEM field and particular field

Definition at line 1850 of file Interface.hpp.

◆ _IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP_

#define _IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP_ (   MFIELD,
  NAME,
  IT 
)
Value:
DofEntityByFieldName::iterator IT = (MFIELD).get_dofs_by_name_begin(NAME); \
IT != (MFIELD).get_dofs_by_name_end(NAME); \
IT++

loop over all dofs from a moFEM field and particular field

Definition at line 1717 of file Interface.hpp.

◆ _IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP_

#define _IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP_ (   MFIELD,
  NAME,
  IT 
)
Value:
FieldEntityByFieldName::iterator IT = \
(MFIELD).get_ent_field_by_name_begin(NAME); \
IT != (MFIELD).get_ent_field_by_name_end(NAME); \
IT++

loop over all dofs from a moFEM field and particular field

Examples:
mesh_smoothing.cpp.

Definition at line 1680 of file Interface.hpp.

◆ _IT_GET_FES_BY_NAME_FOR_LOOP_

#define _IT_GET_FES_BY_NAME_FOR_LOOP_ (   MFIELD,
  NAME,
  IT 
)
Value:
EntFiniteElementByName::iterator IT = (MFIELD).get_fe_by_name_begin(NAME); \
IT != (MFIELD).get_fe_by_name_end(NAME); \
IT++

loop over all finite elements from a moFEM field and FE

Definition at line 1889 of file Interface.hpp.

Function Documentation

◆ get_dofs()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_dofs ( const DofEntity_multiIndex **  dofs_ptr) const
pure virtual

Get dofs multi index.

Implemented in MoFEM::Core.

◆ get_dofs_by_name_and_ent_begin()

virtual DofEntityByNameAndEnt::iterator MoFEM::CoreInterface::get_dofs_by_name_and_ent_begin ( const std::string &  field_name,
const EntityHandle  ent 
) const
pure virtual

get begin iterator of filed dofs of given name and ent(instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,ENT,IT)

for(IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP(MFIELD,NAME,ENT,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_dofs_by_name_and_ent_end()

virtual DofEntityByNameAndEnt::iterator MoFEM::CoreInterface::get_dofs_by_name_and_ent_end ( const std::string &  field_name,
const EntityHandle  ent 
) const
pure virtual

get begin iterator of filed dofs of given name and ent (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,ENT,IT)for(IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP(MFIELD,NAME,ENT,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_dofs_by_name_and_type_begin()

virtual DofEntityByNameAndType::iterator MoFEM::CoreInterface::get_dofs_by_name_and_type_begin ( const std::string &  field_name,
const EntityType  type 
) const
pure virtual

get begin iterator of filed dofs of given name and ent type (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,TYPE,IT)

for(IT_GET_DOFS_FIELD_BY_NAME_AND_TYPE_FOR_LOOP(MFIELD,NAME,TYPE,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_dofs_by_name_and_type_end()

virtual DofEntityByNameAndType::iterator MoFEM::CoreInterface::get_dofs_by_name_and_type_end ( const std::string &  field_name,
const EntityType  type 
) const
pure virtual

get begin iterator of filed dofs of given name end ent type(instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,TYPE,IT)

for(IT_GET_DOFS_FIELD_BY_NAME_AND_TYPE_FOR_LOOP(MFIELD,NAME,TYPE,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_dofs_by_name_begin()

virtual DofEntityByFieldName::iterator MoFEM::CoreInterface::get_dofs_by_name_begin ( const std::string &  field_name) const
pure virtual

get begin iterator of filed dofs of given name (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_dofs_by_name_end()

virtual DofEntityByFieldName::iterator MoFEM::CoreInterface::get_dofs_by_name_end ( const std::string &  field_name) const
pure virtual

get begin iterator of filed dofs of given name (instead you can use IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_DOFS_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_ent_field_by_name_begin()

virtual FieldEntityByFieldName::iterator MoFEM::CoreInterface::get_ent_field_by_name_begin ( const std::string &  field_name) const
pure virtual

get begin iterator of filed ents of given name (instead you can use IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)

for(IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_ent_field_by_name_end()

virtual FieldEntityByFieldName::iterator MoFEM::CoreInterface::get_ent_field_by_name_end ( const std::string &  field_name) const
pure virtual

get begin iterator of filed dofs of given name (instead you can use IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)for(IT_GET_ENT_FIELD_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
field_name

Implemented in MoFEM::Core.

◆ get_ents_finite_elements()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_ents_finite_elements ( const EntFiniteElement_multiIndex **  fe_ent_ptr) const
pure virtual

Get entities finite elements multi-index.

Implemented in MoFEM::Core.

◆ get_fe_by_name_begin()

virtual EntFiniteElementByName::iterator MoFEM::CoreInterface::get_fe_by_name_begin ( const std::string &  fe_name) const
pure virtual

get begin iterator of finite elements of given name (instead you can use IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)

for(IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
fe_name

Implemented in MoFEM::Core.

◆ get_fe_by_name_end()

virtual EntFiniteElementByName::iterator MoFEM::CoreInterface::get_fe_by_name_end ( const std::string &  fe_name) const
pure virtual

get end iterator of finite elements of given name (instead you can use IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)

for(IT_GET_FES_BY_NAME_FOR_LOOP(MFIELD,NAME,IT)) { ... }

Parameters
fe_name

Implemented in MoFEM::Core.

◆ get_field_dof_data() [1/2]

template<typename DIT >
MoFEMErrorCode MoFEM::CoreInterface::get_field_dof_data ( const std::string &  name,
const EntityHandle ent,
const int  num_ents,
DIT  dit,
int count = NULL 
)

get field data from entity and fieldthis function is not recommended to be used in finite element implementation

Definition at line 1771 of file Interface.hpp.

1773  {
1775  if (count != NULL)
1776  *count = 0;
1777  for (int nn = 0; nn < num_ents; nn++) {
1778  for (_IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_((*this), name, ent[nn],
1779  it)) {
1780  *(dit++) = (*it)->getFieldData();
1781  if (count != NULL)
1782  (*count)++;
1783  }
1784  }
1786  }
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:491
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:498
#define _IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_(MFIELD, NAME, ENT, IT)
loop over all dofs from a moFEM field and particular field
Definition: Interface.hpp:1756

◆ get_field_dof_data() [2/2]

template<typename DIT >
MoFEMErrorCode MoFEM::CoreInterface::get_field_dof_data ( const std::string &  name,
const Range &  ents,
DIT  dit,
int count = NULL 
)

get field data from entity and fieldthis function is not recommended to be used in finite element implementation

Definition at line 1797 of file Interface.hpp.

1798  {
1800  if (count != NULL)
1801  *count = 0;
1802  for (Range::const_iterator eit = ents.begin(); eit != ents.end(); eit++) {
1803  for (_IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_((*this), name, *eit,
1804  it)) {
1805  *(dit++) = (*it)->getFieldData();
1806  if (count != NULL)
1807  (*count)++;
1808  }
1809  }
1811  }
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:491
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:498
#define _IT_GET_DOFS_FIELD_BY_NAME_AND_ENT_FOR_LOOP_(MFIELD, NAME, ENT, IT)
loop over all dofs from a moFEM field and particular field
Definition: Interface.hpp:1756

◆ get_field_ents()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_field_ents ( const FieldEntity_multiIndex **  field_ents) const
pure virtual

Get field multi index.

Implemented in MoFEM::Core.

◆ get_fields()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_fields ( const Field_multiIndex **  fields_ptr) const
pure virtual

Get fields multi-index from database.

Implemented in MoFEM::Core.

Examples:
field_to_vertices.cpp.

◆ get_finite_elements()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_finite_elements ( const FiniteElement_multiIndex **  fe_ptr) const
pure virtual

Get finite elements multi-index.

Implemented in MoFEM::Core.

◆ get_problem()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_problem ( const std::string &  problem_name,
const Problem **  problem_ptr 
) const
pure virtual

Get problem database (data structure)

Implemented in MoFEM::Core.

Examples:
cell_forces.cpp.

◆ get_problems()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_problems ( const Problem_multiIndex **  problems_ptr) const
pure virtual

Get pointer to problems multi-index.

Implemented in MoFEM::Core.

◆ get_ref_ents()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_ref_ents ( const RefEntity_multiIndex **  refined_ents_ptr) const
pure virtual

Get ref entities multi-index from database.

Implemented in MoFEM::Core.

◆ get_ref_finite_elements()

virtual MoFEMErrorCode MoFEM::CoreInterface::get_ref_finite_elements ( const RefElement_multiIndex **  refined_finite_elements_ptr) const
pure virtual

Get ref finite elements multi-index form database.

Implemented in MoFEM::Core.