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

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

Inheritance diagram for OpRotatingFrameTools::OpRotatingFrameLhs:
[legend]
Collaboration diagram for OpRotatingFrameTools::OpRotatingFrameLhs:
[legend]

Public Member Functions

 OpRotatingFrameLhs (const std::string row_field_name, const std::string col_field_name, boost::shared_ptr< CommonData > common_data_ptr)
 
MoFEMErrorCode iNtegrate (EntData &row_data, EntData &col_data)
 [Stiffness] More...
 

Private Attributes

boost::shared_ptr< CommonDatacommonDataPtr
 

Detailed Description

Definition at line 41 of file RotatingFrameOperators.hpp.

Constructor & Destructor Documentation

◆ OpRotatingFrameLhs()

OpRotatingFrameTools::OpRotatingFrameLhs::OpRotatingFrameLhs ( const std::string  row_field_name,
const std::string  col_field_name,
boost::shared_ptr< CommonData common_data_ptr 
)

Definition at line 104 of file RotatingFrameOperators.cpp.

107 : DomainEleOpAssembly(row_field_name, col_field_name,
109 commonDataPtr(common_data_ptr) {
110 sYmm = false;
111}
FormsIntegrators< DomainEleOp >::Assembly< USER_ASSEMBLE >::OpBase DomainEleOpAssembly
@ OPROWCOL
operator doWork is executed on FE rows &columns
boost::shared_ptr< CommonData > commonDataPtr

Member Function Documentation

◆ iNtegrate()

MoFEMErrorCode OpRotatingFrameTools::OpRotatingFrameLhs::iNtegrate ( EntData row_data,
EntData col_data 
)

[Stiffness]

Definition at line 114 of file RotatingFrameOperators.cpp.

115 {
117
118 const size_t nb_row_dofs = row_data.getIndices().size();
119 const size_t nb_col_dofs = col_data.getIndices().size();
120
121 if (nb_row_dofs && nb_col_dofs) {
122
123 const size_t nb_integration_pts = row_data.getN().size1();
124 const size_t nb_row_base_funcs = row_data.getN().size2();
125 auto t_row_diff_base = row_data.getFTensor1DiffN<3>();
126 auto t_w = getFTensor0IntegrationWeight();
127 auto t_coords = getFTensor1CoordsAtGaussPts();
128 for (size_t gg = 0; gg != nb_integration_pts; ++gg) {
129 double alpha = getMeasure() * t_w * (*cache).density;
130
132 omg(i) = (*cache).Omega(i, j) * t_coords(j);
133
134 size_t rr = 0;
135 for (; rr != nb_row_dofs / 3; ++rr) {
136
137 auto t_mat = getFTensor2FromArray<3, 3, 3>(locMat, 3 * rr);
138
139 auto t_col_diff_base = col_data.getFTensor1DiffN<3>(gg, 0);
140
141 for (size_t cc = 0; cc != nb_col_dofs / 3; ++cc) {
142 t_mat(i, k) -= alpha * t_row_diff_base(j) * omg(j) *
143 t_col_diff_base(l) * omg(l) * kronecker_delta(i, k);
144
145 ++t_col_diff_base;
146 ++t_mat;
147 }
148
149 ++t_row_diff_base;
150 }
151 for (; rr != nb_row_base_funcs; ++rr)
152 ++t_row_diff_base;
153
154 ++t_coords;
155 ++t_w;
156 }
157 }
158
160}
#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< 'l', 3 > l
FTensor::Index< 'j', 3 > j
FTensor::Index< 'k', 3 > k
Tensor2_Expr< Kronecker_Delta< T >, T, Dim0, Dim1, i, j > kronecker_delta(const Index< i, Dim0 > &, const Index< j, Dim1 > &)
Rank 2.
FTensor::Tensor1< FTensor::PackPtr< double *, Tensor_Dim >, Tensor_Dim > getFTensor1DiffN(const FieldApproximationBase base)
Get derivatives of base functions.
MatrixDouble & getN(const FieldApproximationBase base)
get base functions this return matrix (nb. of rows is equal to nb. of Gauss pts, nb....
const VectorInt & getIndices() const
Get global indices of dofs on entity.

Member Data Documentation

◆ commonDataPtr

boost::shared_ptr<CommonData> OpRotatingFrameTools::OpRotatingFrameLhs::commonDataPtr
private

Definition at line 49 of file RotatingFrameOperators.hpp.


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