v0.13.2
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
OpElasticTools::OpRotate Struct Reference

#include <users_modules/multifield_plasticity/src/ElasticOperators.hpp>

Inheritance diagram for OpElasticTools::OpRotate:
[legend]
Collaboration diagram for OpElasticTools::OpRotate:
[legend]

Public Member Functions

 OpRotate (std::string disp_name, VectorDouble &omega, boost::shared_ptr< VectorDouble > c_coords, boost::shared_ptr< Range > ents_ptr)
 
MoFEMErrorCode iNtegrate (EntitiesFieldData::EntData &row_data)
 

Private Attributes

VectorDouble locRes
 
ScalarFun betaCoeff
 
boost::shared_ptr< RangeentsPtr
 
VectorDouble & sourceVec
 
boost::shared_ptr< VectorDouble > centerCoords
 

Detailed Description

Definition at line 1010 of file ElasticOperators.hpp.

Constructor & Destructor Documentation

◆ OpRotate()

OpElasticTools::OpRotate::OpRotate ( std::string  disp_name,
VectorDouble &  omega,
boost::shared_ptr< VectorDouble >  c_coords,
boost::shared_ptr< Range ents_ptr 
)
inline

Definition at line 1012 of file ElasticOperators.hpp.

1015 : BoundaryEleOpAssembly(disp_name, disp_name, OPROW), entsPtr(ents_ptr),
1016 sourceVec(omega), centerCoords(c_coords) {}
constexpr double omega
boost::shared_ptr< Range > entsPtr
boost::shared_ptr< VectorDouble > centerCoords

Member Function Documentation

◆ iNtegrate()

MoFEMErrorCode OpElasticTools::OpRotate::iNtegrate ( EntitiesFieldData::EntData &  row_data)
inline

Definition at line 1018 of file ElasticOperators.hpp.

1018 {
1020 const int nb_row_dofs = row_data.getIndices().size();
1021 const int nb_row_base_functions = row_data.getN().size2();
1022
1023 if (nb_row_dofs) {
1024
1025 EntityHandle ent = getFEEntityHandle();
1026 if (entsPtr->find(ent) == entsPtr->end()) {
1028 }
1029
1030 auto t_coords = getFTensor1CoordsAtGaussPts();
1031
1032 const int nb_integration_pts = getGaussPts().size2();
1033 auto t_row_val = row_data.getFTensor0N();
1034 auto t_w = getFTensor0IntegrationWeight();
1035 const double vol = getMeasure();
1037 auto t_omega = getFTensor1FromArray<3, 3>(sourceVec);
1038 auto t_cen_coords = getFTensor1FromArray<3, 3>(*centerCoords);
1040
1041 auto rot = get_rotation_R(t_omega, 1);
1042
1043 for (int gg = 0; gg != nb_integration_pts; ++gg) {
1044 const double a = vol * t_w;
1045 c_dist(i) = t_cen_coords(i) - t_coords(i);
1046 rot_disp(i) = c_dist(i) - rot(j, i) * c_dist(j);
1047
1048 auto t_nf = getFTensor1FromArray<3, 3>(locF);
1049 int rr = 0;
1050 for (; rr != nb_row_dofs / 3; ++rr) {
1051 t_nf(i) -= a * t_row_val * rot_disp(i);
1052 ++t_row_val;
1053 ++t_nf;
1054 }
1055 for (; rr < nb_row_base_functions; ++rr)
1056 ++t_row_val;
1057
1058 ++t_coords;
1059 ++t_w;
1060 }
1061 }
1063 }
constexpr double a
#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
FTensor::Index< 'i', SPACE_DIM > i
FTensor::Index< 'j', 3 > j
auto get_rotation_R(Tensor1< T, 3 > t1_omega, double tt)

Member Data Documentation

◆ betaCoeff

ScalarFun OpElasticTools::OpRotate::betaCoeff
private

Definition at line 1067 of file ElasticOperators.hpp.

◆ centerCoords

boost::shared_ptr<VectorDouble> OpElasticTools::OpRotate::centerCoords
private

Definition at line 1070 of file ElasticOperators.hpp.

◆ entsPtr

boost::shared_ptr<Range> OpElasticTools::OpRotate::entsPtr
private

Definition at line 1068 of file ElasticOperators.hpp.

◆ locRes

VectorDouble OpElasticTools::OpRotate::locRes
private

Definition at line 1066 of file ElasticOperators.hpp.

◆ sourceVec

VectorDouble& OpElasticTools::OpRotate::sourceVec
private

Definition at line 1069 of file ElasticOperators.hpp.


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