v0.15.5
Loading...
Searching...
No Matches
Public Member Functions | List of all members
EshelbianPlasticity::dJ_dTractionImpl Struct Reference
Inheritance diagram for EshelbianPlasticity::dJ_dTractionImpl:
[legend]
Collaboration diagram for EshelbianPlasticity::dJ_dTractionImpl:
[legend]

Public Member Functions

MoFEMErrorCode iNtegrate (EntData &data)
 
- Public Member Functions inherited from EshelbianPlasticity::OpAssembleBrokenFaceTopologicalDerivativeImplBase
 OpAssembleBrokenFaceTopologicalDerivativeImplBase (boost::shared_ptr< std::vector< BrokenBaseSideData > > broken_base_side_data, boost::shared_ptr< TopologicalData > topo_ptr, boost::shared_ptr< double > J_ptr, SmartPetscObj< Vec > assemble_vec, Tag topo_tag, boost::shared_ptr< Range > ents_ptr=nullptr)
 
MoFEMErrorCode aSsemble (EntData &data) override
 

Additional Inherited Members

- Public Types inherited from EshelbianPlasticity::OpAssembleBrokenFaceTopologicalDerivativeImplBase
using OP = typename FormsIntegrators< FaceUserDataOperator >::Assembly< A >::OpBrokenBase
 
- Protected Attributes inherited from EshelbianPlasticity::OpAssembleBrokenFaceTopologicalDerivativeImplBase
boost::shared_ptr< doubleJPtr
 
SmartPetscObj< Vec > assembleVec
 
Tag topoTag
 
boost::shared_ptr< TopologicalDatatopoData
 

Detailed Description

Definition at line 177 of file EshelbianTopologicalDerivativeOperators.cpp.

Member Function Documentation

◆ iNtegrate()

MoFEMErrorCode EshelbianPlasticity::dJ_dTractionImpl::iNtegrate ( EntData data)

Definition at line 652 of file EshelbianTopologicalDerivativeOperators.cpp.

652 {
654
655#ifndef NDEBUG
656 if (!topoData)
657 SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
658 "Topological data pointer is null");
659#endif // NDEBUG
660
661 const int nb_dofs = data.getIndices().size();
662 if (!nb_dofs)
664
665 const int nb_integration_pts = OP::getGaussPts().size2();
666
667#ifndef NDEBUG
668 const int traction_rows = topoData->objDDisplacementAtPts.size1();
669 const int traction_cols = topoData->objDDisplacementAtPts.size2();
670 if (traction_cols != nb_integration_pts)
671 SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
672 "objDDisplacementAtPts columns (%d) != nb integration points (%d)",
673 traction_cols, nb_integration_pts);
674
675 if (traction_rows != SPACE_DIM) {
676 SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
677 "objDDisplacementAtPts row size is %d, expected %d", traction_rows,
678 SPACE_DIM);
679 }
680#endif // NDEBUG
681
682 auto t_normal = OP::getFTensor1NormalsAtGaussPts();
683 auto t_w = OP::getFTensor0IntegrationWeight();
684 const int nb_base_functions = data.getN().size2() / SPACE_DIM;
685 auto t_row_base_fun = data.getFTensor1N<SPACE_DIM>();
686 auto t_obj_dtraction =
687 getFTensor1FromMat<SPACE_DIM>(topoData->objDDisplacementAtPts);
688
691
692 for (int gg = 0; gg != nb_integration_pts; ++gg) {
693 auto t_nf = getFTensor1FromPtr<SPACE_DIM>(&*OP::locF.begin());
694 int bb = 0;
695 for (; bb != nb_dofs / SPACE_DIM; ++bb) {
696 t_nf(i) +=
697 t_w * (t_row_base_fun(j) * t_normal(j)) * t_obj_dtraction(i) * 0.5;
698 ++t_nf;
699 ++t_row_base_fun;
700 }
701 for (; bb != nb_base_functions; ++bb)
702 ++t_row_base_fun;
703
704 ++t_w;
705 ++t_normal;
706 ++t_obj_dtraction;
707 }
708
710}
#define FTENSOR_INDEX(DIM, I)
constexpr int SPACE_DIM
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
@ MOFEM_DATA_INCONSISTENCY
Definition definitions.h:31
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
FTensor::Index< 'i', SPACE_DIM > i
FTensor::Index< 'j', 3 > j
MatrixDouble & getN(const FieldApproximationBase base)
get base functions this return matrix (nb. of rows is equal to nb. of Gauss pts, nb....
FTensor::Tensor1< FTensor::PackPtr< double *, Tensor_Dim >, Tensor_Dim > getFTensor1N(FieldApproximationBase base)
Get base functions for Hdiv/Hcurl spaces.
const VectorInt & getIndices() const
Get global indices of degrees of freedom on entity.

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