v0.14.0
Public Member Functions | Public Attributes | List of all members
CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal Struct Reference

Operator calculate gap in local coordinate system. More...

#include <users_modules/basic_finite_elements/cohesive_interface/src/CohesiveInterfaceElement.hpp>

Inheritance diagram for CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal:
[legend]
Collaboration diagram for CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal:
[legend]

Public Member Functions

 OpCalculateGapLocal (const std::string field_name, CommonData &common_data)
 
MoFEMErrorCode doWork (int side, EntityType type, EntitiesFieldData::EntData &data)
 

Public Attributes

CommonDatacommonData
 

Detailed Description

Operator calculate gap in local coordinate system.

Definition at line 400 of file CohesiveInterfaceElement.hpp.

Constructor & Destructor Documentation

◆ OpCalculateGapLocal()

CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal::OpCalculateGapLocal ( const std::string  field_name,
CommonData common_data 
)
inline

Definition at line 403 of file CohesiveInterfaceElement.hpp.

403  :
404  FlatPrismElementForcesAndSourcesCore::UserDataOperator(field_name,ForcesAndSourcesCore::UserDataOperator::OPROW),
405  commonData(common_data) {}

Member Function Documentation

◆ doWork()

MoFEMErrorCode CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal::doWork ( int  side,
EntityType  type,
EntitiesFieldData::EntData data 
)
inline

Definition at line 407 of file CohesiveInterfaceElement.hpp.

407  {
409  try {
410  if(type == MBVERTEX) {
411  int nb_gauss_pts = data.getN().size1();
412  commonData.gapLoc.resize(nb_gauss_pts,3);
413  for(int gg = 0;gg<nb_gauss_pts;gg++) {
414  ublas::matrix_row<MatrixDouble > gap_glob(commonData.gapGlob,gg);
415  ublas::matrix_row<MatrixDouble > gap_loc(commonData.gapLoc,gg);
416  gap_loc = prod(commonData.R[gg],gap_glob);
417  }
418  }
419  } catch (const std::exception& ex) {
420  std::ostringstream ss;
421  ss << "throw in method: " << ex.what() << std::endl;
422  SETERRQ(PETSC_COMM_SELF,1,ss.str().c_str());
423  }
425  }

Member Data Documentation

◆ commonData

CommonData& CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal::commonData

Definition at line 402 of file CohesiveInterfaceElement.hpp.


The documentation for this struct was generated from the following file:
MoFEMFunctionReturnHot
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:460
CohesiveElement::CohesiveInterfaceElement::CommonData::gapLoc
MatrixDouble gapLoc
Definition: CohesiveInterfaceElement.hpp:18
CohesiveElement::CohesiveInterfaceElement::CommonData::gapGlob
MatrixDouble gapGlob
Definition: CohesiveInterfaceElement.hpp:17
convert.type
type
Definition: convert.py:64
field_name
constexpr auto field_name
Definition: poisson_2d_homogeneous.cpp:13
UserDataOperator
ForcesAndSourcesCore::UserDataOperator UserDataOperator
Definition: HookeElement.hpp:75
MoFEMFunctionBeginHot
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:453
CohesiveElement::CohesiveInterfaceElement::OpCalculateGapLocal::commonData
CommonData & commonData
Definition: CohesiveInterfaceElement.hpp:402
CohesiveElement::CohesiveInterfaceElement::CommonData::R
ublas::vector< MatrixDouble > R
Definition: CohesiveInterfaceElement.hpp:19