v0.14.0
Public Member Functions | Protected Attributes | List of all members
ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp > Struct Template Reference

#include <users_modules/adolc-plasticity/src/ADOLCPlasticity.hpp>

Inheritance diagram for ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >:
[legend]
Collaboration diagram for ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >:
[legend]

Public Member Functions

 OpLhsImpl (std::string field_name, boost::shared_ptr< CommonData > common_data_ptr)
 [OpRhsImpl integrate] More...
 
MoFEMErrorCode iNtegrate (DataForcesAndSourcesCore::EntData &row_data, DataForcesAndSourcesCore::EntData &col_data)
 
- Public Member Functions inherited from MoFEM::OpBaseImpl< A, EleOp >
 OpBaseImpl (const std::string row_field_name, const std::string col_field_name, const OpType type, boost::shared_ptr< Range > ents_ptr=nullptr)
 
MoFEMErrorCode doWork (int row_side, int col_side, EntityType row_type, EntityType col_type, EntData &row_data, EntData &col_data)
 Do calculations for the left hand side. More...
 
MoFEMErrorCode doWork (int row_side, EntityType row_type, EntData &row_data)
 Do calculations for the right hand side. More...
 

Protected Attributes

boost::shared_ptr< CommonDatacommonDataPtr
 
MatrixDouble baseRowStorage
 Store tensorial base functions. More...
 
MatrixDouble baseColStorage
 Store tensorial base functions. More...
 
- Protected Attributes inherited from MoFEM::OpBaseImpl< A, EleOp >
int nbRows
 number of dofs on rows More...
 
int nbCols
 number if dof on column More...
 
int nbIntegrationPts
 number of integration points More...
 
int nbRowBaseFunctions
 number or row base functions More...
 
int rowSide
 row side number More...
 
int colSide
 column side number More...
 
EntityType rowType
 row type More...
 
EntityType colType
 column type More...
 
bool assembleTranspose
 
bool onlyTranspose
 
MatrixDouble locMat
 local entity block matrix More...
 
MatrixDouble locMatTranspose
 local entity block matrix More...
 
VectorDouble locF
 local entity vector More...
 

Additional Inherited Members

- Public Types inherited from MoFEM::OpBaseImpl< A, EleOp >
using OpType = typename EleOp::OpType
 
using EntData = EntitiesFieldData::EntData
 
using MatSetValuesHook = boost::function< MoFEMErrorCode(ForcesAndSourcesCore::UserDataOperator *op_ptr, const EntitiesFieldData::EntData &row_data, const EntitiesFieldData::EntData &col_data, MatrixDouble &m)>
 
- Public Attributes inherited from MoFEM::OpBaseImpl< A, EleOp >
TimeFun timeScalingFun
 assumes that time variable is set More...
 
FEFun feScalingFun
 assumes that time variable is set More...
 
boost::shared_ptr< RangeentsPtr
 Entities on which element is run. More...
 
- Static Public Attributes inherited from MoFEM::OpBaseImpl< A, EleOp >
static MatSetValuesHook matSetValuesHook
 
- Protected Member Functions inherited from MoFEM::OpBaseImpl< A, EleOp >
template<int DIM>
FTensor::Tensor1< FTensor::PackPtr< double *, DIM >, DIM > getNf ()
 
template<int DIM>
FTensor::Tensor2< FTensor::PackPtr< double *, DIM >, DIM, DIM > getLocMat (const int rr)
 
virtual MoFEMErrorCode iNtegrate (EntData &row_data, EntData &col_data)
 Integrate grad-grad operator. More...
 
virtual MoFEMErrorCode aSsemble (EntData &row_data, EntData &col_data, const bool trans)
 
virtual MoFEMErrorCode iNtegrate (EntData &data)
 Class dedicated to integrate operator. More...
 
virtual MoFEMErrorCode aSsemble (EntData &data)
 
virtual size_t getNbOfBaseFunctions (EntitiesFieldData::EntData &data)
 Get number of base functions. More...
 

Detailed Description

template<int DIM, typename AssemblyDomainEleOp>
struct ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >

Definition at line 545 of file ADOLCPlasticity.hpp.

Constructor & Destructor Documentation

◆ OpLhsImpl()

template<int DIM, typename AssemblyDomainEleOp >
ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::OpLhsImpl ( std::string  field_name,
boost::shared_ptr< CommonData common_data_ptr 
)

[OpRhsImpl integrate]

Examples
ADOLCPlasticity.hpp.

Definition at line 593 of file ADOLCPlasticity.hpp.

596  AssemblyDomainEleOp::OPROWCOL),
597  commonDataPtr(common_data_ptr) {
598  this->sYmm = false; // It has to be false for not-associtive plasticity
599 }

Member Function Documentation

◆ iNtegrate()

template<int DIM, typename AssemblyDomainEleOp >
MoFEMErrorCode ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::iNtegrate ( DataForcesAndSourcesCore::EntData row_data,
DataForcesAndSourcesCore::EntData col_data 
)
Examples
ADOLCPlasticity.hpp.

Definition at line 602 of file ADOLCPlasticity.hpp.

604  {
606  using OP = AssemblyDomainEleOp;
607 
608  double *w_ptr = &(OP::getGaussPts()(DIM, 0));
609  auto t_diff_row = MakeB::getFTensor2SymmetricDiffBase(
610  row_data, baseRowStorage, commonDataPtr->bBar, OP::getGaussPts().size2(),
611  w_ptr, FTensor::Number<DIM>());
612  auto t_diff_col = MakeB::getFTensor2SymmetricDiffBase(
613  col_data, baseColStorage, commonDataPtr->bBar, OP::getGaussPts().size2(),
614  w_ptr, FTensor::Number<DIM>());
615 
616  auto get_ftensor2_symmetric = [&](auto &storage, const auto gg,
617  const auto rr) {
619  &storage(gg, 6 * rr + 0), &storage(gg, 6 * rr + 1),
620  &storage(gg, 6 * rr + 2), &storage(gg, 6 * rr + 3),
621  &storage(gg, 6 * rr + 4), &storage(gg, 6 * rr + 5)};
622  };
623 
628 
629  auto t_Cep =
630  getFTensor4DdgFromMat<3, 3, 1>(commonDataPtr->materialTangentOperator);
631  const auto vol = OP::getMeasure();
632  auto t_w = OP::getFTensor0IntegrationWeight();
633  for (int gg = 0; gg != OP::nbIntegrationPts; ++gg) {
634  const double alpha = vol * t_w;
635  ++t_w;
636 
637  for (auto rr = 0; rr != OP::nbRows; ++rr) {
639  t_rowCep(k, l) = t_Cep(i, j, k, l) * t_diff_row(i, j);
640  auto t_diff_col = get_ftensor2_symmetric(baseColStorage, gg, 0);
641  for (auto cc = 0; cc != OP::nbCols; ++cc) {
642  OP::locMat(rr, cc) += alpha * (t_rowCep(k, l) * t_diff_col(k, l));
643  ++t_diff_col;
644  }
645  ++t_diff_row;
646  }
647 
648  ++t_Cep;
649  }
651 }

Member Data Documentation

◆ baseColStorage

template<int DIM, typename AssemblyDomainEleOp >
MatrixDouble ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::baseColStorage
protected

Store tensorial base functions.

Definition at line 554 of file ADOLCPlasticity.hpp.

◆ baseRowStorage

template<int DIM, typename AssemblyDomainEleOp >
MatrixDouble ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::baseRowStorage
protected

Store tensorial base functions.

Definition at line 553 of file ADOLCPlasticity.hpp.

◆ commonDataPtr

template<int DIM, typename AssemblyDomainEleOp >
boost::shared_ptr<CommonData> ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::commonDataPtr
protected

Definition at line 552 of file ADOLCPlasticity.hpp.


The documentation for this struct was generated from the following file:
ADOLCPlasticity::MakeB::getFTensor2SymmetricDiffBase
static FTensor::Tensor2_symmetric< FTensor::PackPtr< double *, 6 >, 3 > getFTensor2SymmetricDiffBase(DataForcesAndSourcesCore::EntData &data, MatrixDouble &storage, const bool b_bar, const int nb_integration_pts, double *w_ptr, FTensor::Number< 2 >)
Definition: ADOLCPlasticity.cpp:186
FTensor::Tensor2_symmetric
Definition: Tensor2_symmetric_value.hpp:13
FTensor::Number
Definition: Number.hpp:11
ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::baseRowStorage
MatrixDouble baseRowStorage
Store tensorial base functions.
Definition: ADOLCPlasticity.hpp:553
ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::baseColStorage
MatrixDouble baseColStorage
Store tensorial base functions.
Definition: ADOLCPlasticity.hpp:554
i
FTensor::Index< 'i', SPACE_DIM > i
Definition: hcurl_divergence_operator_2d.cpp:27
field_name
constexpr auto field_name
Definition: poisson_2d_homogeneous.cpp:13
FTensor::Index< 'i', 3 >
j
FTensor::Index< 'j', 3 > j
Definition: matrix_function.cpp:19
ADOLCPlasticity::OpLhsImpl< DIM, GAUSS, AssemblyDomainEleOp >::commonDataPtr
boost::shared_ptr< CommonData > commonDataPtr
Definition: ADOLCPlasticity.hpp:552
AssemblyDomainEleOp
FormsIntegrators< DomainEleOp >::Assembly< A >::OpBase AssemblyDomainEleOp
Definition: tensor_divergence_operator.cpp:59
k
FTensor::Index< 'k', 3 > k
Definition: matrix_function.cpp:20
OP
MoFEMFunctionReturn
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:416
MoFEMFunctionBegin
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:346
l
FTensor::Index< 'l', 3 > l
Definition: matrix_function.cpp:21