v0.13.1
Loading...
Searching...
No Matches
Public Member Functions | List of all members
FreeSurfaceOps::OpNormalConstrainLhs Struct Reference

#include <users_modules/tutorials/vec-5/src/FreeSurfaceOps.hpp>

Inheritance diagram for FreeSurfaceOps::OpNormalConstrainLhs:
[legend]
Collaboration diagram for FreeSurfaceOps::OpNormalConstrainLhs:
[legend]

Public Member Functions

 OpNormalConstrainLhs (const std::string field_name_row, const std::string field_name_col)
 
MoFEMErrorCode iNtegrate (EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
 

Detailed Description

Examples
free_surface.cpp.

Definition at line 138 of file FreeSurfaceOps.hpp.

Constructor & Destructor Documentation

◆ OpNormalConstrainLhs()

FreeSurfaceOps::OpNormalConstrainLhs::OpNormalConstrainLhs ( const std::string  field_name_row,
const std::string  field_name_col 
)
inline

Definition at line 140 of file FreeSurfaceOps.hpp.

142 : AssemblyBoundaryEleOp(field_name_row, field_name_col,
143 AssemblyBoundaryEleOp::OPROWCOL) {
144 assembleTranspose = true;
145 sYmm = false;
146 }
FormsIntegrators< BoundaryEleOp >::Assembly< PETSC >::OpBase AssemblyBoundaryEleOp
Definition: contact.cpp:59

Member Function Documentation

◆ iNtegrate()

MoFEMErrorCode FreeSurfaceOps::OpNormalConstrainLhs::iNtegrate ( EntitiesFieldData::EntData &  row_data,
EntitiesFieldData::EntData &  col_data 
)
inline

Definition at line 148 of file FreeSurfaceOps.hpp.

149 {
151
152 auto t_w = getFTensor0IntegrationWeight();
153 auto t_normal = getFTensor1Normal();
154 auto t_row_base = row_data.getFTensor0N();
155 auto t_coords = getFTensor1CoordsAtGaussPts();
156
157 for (int gg = 0; gg != nbIntegrationPts; ++gg) {
158
159 auto t_mat = getFTensor1FromPtr<U_FIELD_DIM>(&locMat(0, 0));
160
161 const double r = t_coords(0);
162 const double alpha = t_w * cylindrical(r);
163
164 int rr = 0;
165 for (; rr != nbRows; ++rr) {
166
167 auto t_col_base = col_data.getFTensor0N(gg, 0);
168 const double a = alpha * t_row_base;
169
170 for (int cc = 0; cc != nbCols / U_FIELD_DIM; ++cc) {
171 t_mat(i) += (a * t_col_base) * t_normal(i);
172 ++t_col_base;
173 ++t_mat;
174 }
175 ++t_row_base;
176 }
177
178 for (; rr < nbRowBaseFunctions; ++rr)
179 ++t_row_base;
180
181 ++t_w;
182 ++t_coords;
183 }
184
186 };
constexpr double a
#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
auto cylindrical
constexpr int U_FIELD_DIM
FTensor::Index< 'i', SPACE_DIM > i
const double r
rate factor

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