v0.8.16
Classes | Public Member Functions | Public Attributes | Protected Member Functions | Friends | List of all members
MoFEM::DataForcesAndSourcesCore Struct Reference

data structure for finite element entityIt keeps that about indices of degrees of freedom, dofs data, base functions functions, entity side number, type of entities, approximation order, etc. More...

#include <src/finite_elements/DataStructures.hpp>

Inheritance diagram for MoFEM::DataForcesAndSourcesCore:
[legend]

Classes

struct  EntData
 Data on single entity (This is passed as argument to DataOperator::doWork) More...
 

Public Member Functions

MoFEMErrorCode resetFieldDependentData ()
 
 DataForcesAndSourcesCore (const EntityType type)
 
virtual ~DataForcesAndSourcesCore ()
 
virtual MoFEMErrorCode setElementType (const EntityType type)
 

Public Attributes

std::bitset< LASTSPACEsPace
 spaces on element More...
 
std::bitset< LASTBASEbAse
 bases on element More...
 
ublas::matrix< intfacesNodes
 nodes on finite element faces More...
 
std::bitset< LASTSPACEspacesOnEntities [MBMAXTYPE]
 spaces on entity types More...
 
std::bitset< LASTBASEbasesOnEntities [MBMAXTYPE]
 bases on entity types More...
 
std::bitset< LASTBASEbasesOnSpaces [LASTSPACE]
 base on spaces More...
 
boost::ptr_vector< EntDatadataOnEntities [MBMAXTYPE]
 

Protected Member Functions

 DataForcesAndSourcesCore ()
 

Friends

std::ostream & operator<< (std::ostream &os, const DataForcesAndSourcesCore &e)
 

Detailed Description

data structure for finite element entity

It keeps that about indices of degrees of freedom, dofs data, base functions functions, entity side number, type of entities, approximation order, etc.

Examples:
forces_and_sources_testing_users_base.cpp.

Definition at line 205 of file DataStructures.hpp.

Constructor & Destructor Documentation

◆ DataForcesAndSourcesCore() [1/2]

MoFEM::DataForcesAndSourcesCore::DataForcesAndSourcesCore ( const EntityType  type)

Definition at line 191 of file DataStructures.cpp.

191  {
192  constructor_data(this, type);
193 }
static void constructor_data(DataForcesAndSourcesCore *data, const EntityType type)

◆ ~DataForcesAndSourcesCore()

virtual MoFEM::DataForcesAndSourcesCore::~DataForcesAndSourcesCore ( )
virtual

Definition at line 1291 of file DataStructures.hpp.

1291 {}

◆ DataForcesAndSourcesCore() [2/2]

MoFEM::DataForcesAndSourcesCore::DataForcesAndSourcesCore ( )
protected

Definition at line 1298 of file DataStructures.hpp.

1298 {}

Member Function Documentation

◆ resetFieldDependentData()

MoFEMErrorCode MoFEM::DataForcesAndSourcesCore::resetFieldDependentData ( )

Reset data associated with particular field name

Returns
error code

Definition at line 1279 of file DataStructures.hpp.

1279  {
1281  for (EntityType t = MBVERTEX; t != MBMAXTYPE; t++) {
1282  for (auto &e : dataOnEntities[t]) {
1283  ierr = e.resetFieldDependentData();
1284  CHKERRG(ierr);
1285  }
1286  }
1288  }
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:483
#define CHKERRG(n)
Check error code of MoFEM/MOAB/PETSc function.
Definition: definitions.h:526
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:490
boost::ptr_vector< EntData > dataOnEntities[MBMAXTYPE]
static MoFEMErrorCodeGeneric< PetscErrorCode > ierr
Definition: Common.hpp:80

◆ setElementType()

MoFEMErrorCode MoFEM::DataForcesAndSourcesCore::setElementType ( const EntityType  type)
virtual

Reimplemented in MoFEM::DerivedDataForcesAndSourcesCore.

Definition at line 195 of file DataStructures.cpp.

195  {
197  for (EntityType tt = MBVERTEX; tt != MBMAXTYPE; ++tt)
198  dataOnEntities[tt].clear();
199  constructor_data(this, type);
201 }
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return() ...
Definition: definitions.h:459
static void constructor_data(DataForcesAndSourcesCore *data, const EntityType type)
boost::ptr_vector< EntData > dataOnEntities[MBMAXTYPE]
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:403

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  os,
const DataForcesAndSourcesCore e 
)
friend

Definition at line 263 of file DataStructures.cpp.

263  {
264  for (unsigned int nn = 0; nn < e.dataOnEntities[MBVERTEX].size(); nn++) {
265  os << "dataOnEntities[MBVERTEX][" << nn << "]" << std::endl
266  << e.dataOnEntities[MBVERTEX][nn] << std::endl;
267  }
268  for (unsigned int ee = 0; ee < e.dataOnEntities[MBEDGE].size(); ee++) {
269  os << "dataOnEntities[MBEDGE][" << ee << "]" << std::endl
270  << e.dataOnEntities[MBEDGE][ee] << std::endl;
271  }
272  for (unsigned int ff = 0; ff < e.dataOnEntities[MBTRI].size(); ff++) {
273  os << "dataOnEntities[MBTRI][" << ff << "] " << std::endl
274  << e.dataOnEntities[MBTRI][ff] << std::endl;
275  }
276  for (unsigned int vv = 0; vv < e.dataOnEntities[MBTET].size(); vv++) {
277  os << "dataOnEntities[MBTET][" << vv << "]" << std::endl
278  << e.dataOnEntities[MBTET][vv] << std::endl;
279  }
280  return os;
281 }

Member Data Documentation

◆ bAse

std::bitset<LASTBASE> MoFEM::DataForcesAndSourcesCore::bAse

bases on element

Definition at line 1264 of file DataStructures.hpp.

◆ basesOnEntities

std::bitset<LASTBASE> MoFEM::DataForcesAndSourcesCore::basesOnEntities[MBMAXTYPE]

bases on entity types

Definition at line 1268 of file DataStructures.hpp.

◆ basesOnSpaces

std::bitset<LASTBASE> MoFEM::DataForcesAndSourcesCore::basesOnSpaces[LASTSPACE]

base on spaces

Definition at line 1269 of file DataStructures.hpp.

◆ dataOnEntities

boost::ptr_vector<EntData> MoFEM::DataForcesAndSourcesCore::dataOnEntities[MBMAXTYPE]

data on nodes, base function, dofs values, etc.

Examples:
forces_and_sources_testing_users_base.cpp.

Definition at line 1271 of file DataStructures.hpp.

◆ facesNodes

ublas::matrix<int> MoFEM::DataForcesAndSourcesCore::facesNodes

nodes on finite element faces

Examples:
forces_and_sources_testing_users_base.cpp.

Definition at line 1265 of file DataStructures.hpp.

◆ sPace

std::bitset<LASTSPACE> MoFEM::DataForcesAndSourcesCore::sPace

spaces on element

Definition at line 1263 of file DataStructures.hpp.

◆ spacesOnEntities

std::bitset<LASTSPACE> MoFEM::DataForcesAndSourcesCore::spacesOnEntities[MBMAXTYPE]

spaces on entity types

Definition at line 1267 of file DataStructures.hpp.


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