v0.14.0
Public Member Functions | Private Attributes | List of all members
EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU Struct Reference

#include <users_modules/eshelbian_plasticit/src/EshelbianContact.hpp>

Inheritance diagram for EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU:
[legend]
Collaboration diagram for EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU:
[legend]

Public Member Functions

 OpConstrainBoundaryHDivLhs_dU (const std::string row_field_name, const std::string col_field_name, boost::shared_ptr< ContactOps::CommonData > common_data_ptr, boost::shared_ptr< ContactTree > contact_tree_ptr)
 
MoFEMErrorCode iNtegrate (EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
 

Private Attributes

boost::shared_ptr< ContactOps::CommonDatacommonDataPtr
 
boost::shared_ptr< ContactTreecontactTreePtr
 

Detailed Description

Examples
EshelbianPlasticity.cpp.

Definition at line 177 of file EshelbianContact.hpp.

Constructor & Destructor Documentation

◆ OpConstrainBoundaryHDivLhs_dU()

EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::OpConstrainBoundaryHDivLhs_dU ( const std::string  row_field_name,
const std::string  col_field_name,
boost::shared_ptr< ContactOps::CommonData common_data_ptr,
boost::shared_ptr< ContactTree contact_tree_ptr 
)

Definition at line 773 of file EshelbianContact.cpp.

777  : ContactOps::AssemblyBoundaryEleOp(row_field_name, col_field_name,
779  commonDataPtr(common_data_ptr), contactTreePtr(contact_tree_ptr) {
780  sYmm = false;
781 }

Member Function Documentation

◆ iNtegrate()

MoFEMErrorCode EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::iNtegrate ( EntitiesFieldData::EntData row_data,
EntitiesFieldData::EntData col_data 
)

Definition at line 784 of file EshelbianContact.cpp.

785  {
787 
788  using namespace ContactOps;
789 
793 
794  auto nb_rows = row_data.getIndices().size();
795  auto nb_cols = col_data.getIndices().size();
796 
797  auto &locMat = AssemblyBoundaryEleOp::locMat;
798  locMat.resize(nb_rows, nb_cols, false);
799  locMat.clear();
800 
801  if (nb_cols && nb_rows) {
802 
803  const size_t nb_gauss_pts = getGaussPts().size2();
804 
805  auto t_w = getFTensor0IntegrationWeight();
806  auto t_disp = getFTensor1FromMat<3>(commonDataPtr->contactDisp);
807  auto t_traction = getFTensor1FromMat<3>(commonDataPtr->contactTraction);
808  auto t_coords = getFTensor1CoordsAtGaussPts();
809  auto t_material_normal = getFTensor1NormalsAtGaussPts();
810 
811  auto next = [&]() {
812  ++t_w;
813  ++t_disp;
814  ++t_traction;
815  ++t_coords;
816  ++t_material_normal;
817  };
818 
819  constexpr auto t_kd = FTensor::Kronecker_Delta<int>();
820 
821  auto face_data_vec_ptr =
822  contactTreePtr->findFaceDataVecPtr(getFEEntityHandle());
823  auto face_gauss_pts_it = face_data_vec_ptr->begin();
824 
825  auto t_row_base = row_data.getFTensor1N<3>();
826  auto nb_face_functions = row_data.getN().size2() / 3;
827  for (size_t gg = 0; gg != nb_gauss_pts; ++gg) {
828 
829  const auto alpha = t_w / 2.;
830 
831  size_t rr = 0;
832  for (; rr != nb_rows / 3; ++rr) {
833 
834  auto row_base = alpha * (t_row_base(i) * t_material_normal(i));
835 
836  auto t_mat = getFTensor2FromArray<3, 3, 3>(locMat, 3 * rr);
837  auto t_col_base = col_data.getFTensor0N(gg, 0);
838 
839  for (size_t cc = 0; cc != nb_cols / 3; ++cc) {
840  const auto beta = row_base * t_col_base;
841  t_mat(i, j) -= beta * t_kd(i, j);
842  ++t_col_base;
843  ++t_mat;
844  }
845 
846  ++t_row_base;
847  }
848  for (; rr < nb_face_functions; ++rr)
849  ++t_row_base;
850 
851  next();
852  }
853  }
854 
856 }

Member Data Documentation

◆ commonDataPtr

boost::shared_ptr<ContactOps::CommonData> EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::commonDataPtr
private

Definition at line 189 of file EshelbianContact.hpp.

◆ contactTreePtr

boost::shared_ptr<ContactTree> EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::contactTreePtr
private

Definition at line 190 of file EshelbianContact.hpp.


The documentation for this struct was generated from the following files:
MoFEM::OpBaseImpl::locMat
MatrixDouble locMat
local entity block matrix
Definition: FormsIntegrators.hpp:239
ContactOps
Definition: EshelbianContact.hpp:10
FTensor::Kronecker_Delta
Kronecker Delta class.
Definition: Kronecker_Delta.hpp:15
EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::commonDataPtr
boost::shared_ptr< ContactOps::CommonData > commonDataPtr
Definition: EshelbianContact.hpp:189
MoFEM::ForcesAndSourcesCore::UserDataOperator::OPROWCOL
@ OPROWCOL
operator doWork is executed on FE rows &columns
Definition: ForcesAndSourcesCore.hpp:569
ContactOps::AssemblyBoundaryEleOp
FormsIntegrators< BoundaryEleOp >::Assembly< A >::OpBase AssemblyBoundaryEleOp
Definition: EshelbianContact.hpp:17
i
FTensor::Index< 'i', SPACE_DIM > i
Definition: hcurl_divergence_operator_2d.cpp:27
t_kd
constexpr auto t_kd
Definition: free_surface.cpp:137
EshelbianPlasticity::OpConstrainBoundaryHDivLhs_dU::contactTreePtr
boost::shared_ptr< ContactTree > contactTreePtr
Definition: EshelbianContact.hpp:190
FTensor::Index< 'i', 3 >
j
FTensor::Index< 'j', 3 > j
Definition: matrix_function.cpp:19
k
FTensor::Index< 'k', 3 > k
Definition: matrix_function.cpp:20
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