v0.14.0
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
SimpleContactProblem::OpGetLagMulAtGaussPtsSlave Struct Reference

Operator for the simple contact element. More...

#include <users_modules/mortar_contact/src/SimpleContact.hpp>

Inheritance diagram for SimpleContactProblem::OpGetLagMulAtGaussPtsSlave:
[legend]
Collaboration diagram for SimpleContactProblem::OpGetLagMulAtGaussPtsSlave:
[legend]

Public Member Functions

 OpGetLagMulAtGaussPtsSlave (const string lagrange_field_name, boost::shared_ptr< CommonDataSimpleContact > common_data_contact)
 
MoFEMErrorCode doWork (int side, EntityType type, EntData &data)
 

Public Attributes

boost::shared_ptr< CommonDataSimpleContactcommonDataSimpleContact
 

Detailed Description

Operator for the simple contact element.

Calculates Lagrange multipliers at the gauss points on the slave triangle.

Definition at line 897 of file SimpleContact.hpp.

Constructor & Destructor Documentation

◆ OpGetLagMulAtGaussPtsSlave()

SimpleContactProblem::OpGetLagMulAtGaussPtsSlave::OpGetLagMulAtGaussPtsSlave ( const string  lagrange_field_name,
boost::shared_ptr< CommonDataSimpleContact common_data_contact 
)
inline

Definition at line 900 of file SimpleContact.hpp.

903 : ContactOp(lagrange_field_name, UserDataOperator::OPROW,
904 ContactOp::FACESLAVE),
905 commonDataSimpleContact(common_data_contact) {}
boost::shared_ptr< CommonDataSimpleContact > commonDataSimpleContact
ContactPrismElementForcesAndSourcesCore::UserDataOperator ContactOp

Member Function Documentation

◆ doWork()

MoFEMErrorCode SimpleContactProblem::OpGetLagMulAtGaussPtsSlave::doWork ( int  side,
EntityType  type,
EntData data 
)

Definition at line 729 of file SimpleContact.cpp.

730 {
732
733 if (data.getFieldData().size() == 0)
735
736 const int nb_gauss_pts = data.getN().size1();
737
738 if (type == MBVERTEX) {
739 commonDataSimpleContact->lagMultAtGaussPtsPtr.get()->resize(nb_gauss_pts);
740 commonDataSimpleContact->lagMultAtGaussPtsPtr.get()->clear();
741 }
742
743 int nb_base_fun_row = data.getFieldData().size();
744
745 auto t_lagrange_slave =
746 getFTensor0FromVec(*commonDataSimpleContact->lagMultAtGaussPtsPtr);
747
748 for (int gg = 0; gg != nb_gauss_pts; ++gg) {
749 FTensor::Tensor0<double *> t_base_lambda(&data.getN()(gg, 0));
750
751 FTensor::Tensor0<double *> t_field_data_slave(&data.getFieldData()[0]);
752 for (int bb = 0; bb != nb_base_fun_row; ++bb) {
753 t_lagrange_slave += t_base_lambda * t_field_data_slave;
754 ++t_base_lambda;
755 ++t_field_data_slave;
756 }
757 ++t_lagrange_slave;
758 }
759
761}
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:447
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:346
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:416
static auto getFTensor0FromVec(ublas::vector< T, A > &data)
Get tensor rank 0 (scalar) form data vector.
Definition: Templates.hpp:135
MatrixDouble & getN(const FieldApproximationBase base)
get base functions this return matrix (nb. of rows is equal to nb. of Gauss pts, nb....
const VectorDouble & getFieldData() const
get dofs values

Member Data Documentation

◆ commonDataSimpleContact

boost::shared_ptr<CommonDataSimpleContact> SimpleContactProblem::OpGetLagMulAtGaussPtsSlave::commonDataSimpleContact

Definition at line 899 of file SimpleContact.hpp.


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