v0.14.0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase > Struct Template Reference

#include <src/boundary_conditions/EssentialDisplacementCubitBcData.hpp>

Inheritance diagram for MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >:
[legend]
Collaboration diagram for MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >:
[legend]

Public Types

using OpSource = typename FormsIntegrators< OpBase >::template Assembly< A >::template LinearForm< I >::template OpSource< 1, FIELD_DIM >
 

Public Member Functions

 OpEssentialRhsImpl (const std::string field_name, boost::shared_ptr< DisplacementCubitBcData > bc_data, boost::shared_ptr< Range > ents_ptr, std::vector< boost::shared_ptr< ScalingMethod > > smv)
 

Private Member Functions

FTensor::Tensor1< double, FIELD_DIMrotFunction (double x, double y, double z)
 

Private Attributes

FTensor::Tensor1< double, FIELD_DIMtVal
 
FTensor::Tensor1< double, 3 > tAngles
 
FTensor::Tensor1< double, 3 > tOffset
 
VecOfTimeScalingMethods vecOfTimeScalingMethods
 
VectorFun< FIELD_DIMdispFunction
 

Detailed Description

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase>
struct MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >

Definition at line 167 of file EssentialDisplacementCubitBcData.hpp.

Member Typedef Documentation

◆ OpSource

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
using MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::OpSource = typename FormsIntegrators<OpBase>::template Assembly< A>::template LinearForm<I>::template OpSource<1, FIELD_DIM>

Definition at line 171 of file EssentialDisplacementCubitBcData.hpp.

Constructor & Destructor Documentation

◆ OpEssentialRhsImpl()

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::OpEssentialRhsImpl ( const std::string  field_name,
boost::shared_ptr< DisplacementCubitBcData bc_data,
boost::shared_ptr< Range ents_ptr,
std::vector< boost::shared_ptr< ScalingMethod > >  smv 
)

Definition at line 198 of file EssentialDisplacementCubitBcData.hpp.

203 : OpSource(
204 field_name, [this](double, double, double) { return tVal; },
205 ents_ptr),
207 static_assert(FIELD_DIM > 1, "Is not implemented for scalar field");
208
210 tVal(i) = 0;
211 tAngles(i) = 0;
212 tOffset(i) = 0;
213
214 if (bc_data->data.flag1 == 1)
215 tVal(0) = -bc_data->data.value1;
216 if (bc_data->data.flag2 == 1 && FIELD_DIM > 1)
217 tVal(1) = -bc_data->data.value2;
218 if (bc_data->data.flag3 == 1 && FIELD_DIM > 2)
219 tVal(2) = -bc_data->data.value3;
220 if (bc_data->data.flag4 == 1 && FIELD_DIM > 2)
221 tAngles(0) = -bc_data->data.value4;
222 if (bc_data->data.flag5 == 1 && FIELD_DIM > 2)
223 tAngles(1) = -bc_data->data.value5;
224 if (bc_data->data.flag6 == 1 && FIELD_DIM > 1)
225 tAngles(2) = -bc_data->data.value6;
226
227 if (auto ext_bc_data =
228 dynamic_cast<DisplacementCubitBcDataWithRotation const *>(
229 bc_data.get())) {
230 for (int a = 0; a != 3; ++a)
231 tOffset(a) = ext_bc_data->rotOffset[a];
232 }
233
234 this->timeScalingFun = [this](const double t) {
235 double s = 1;
236 for (auto &o : vecOfTimeScalingMethods) {
237 s *= o->getScale(t);
238 }
239 return s;
240 };
241 if (bc_data->data.flag4 || bc_data->data.flag5 || bc_data->data.flag6) {
242 this->dispFunction = [this](double x, double y, double z) {
243 return this->rotFunction(x, y, z);
244 };
245 } else {
246 // use default set at construction
247 }
248}
static Index< 'o', 3 > o
constexpr double a
constexpr int FIELD_DIM
T data[Tensor_Dim]
FTensor::Index< 'i', SPACE_DIM > i
constexpr double t
plate stiffness
Definition: plate.cpp:59
constexpr auto field_name
typename FormsIntegrators< OpBase >::template Assembly< A >::template LinearForm< I >::template OpSource< 1, FIELD_DIM > OpSource
FTensor::Tensor1< double, FIELD_DIM > rotFunction(double x, double y, double z)

Member Function Documentation

◆ rotFunction()

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
FTensor::Tensor1< double, FIELD_DIM > MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::rotFunction ( double  x,
double  y,
double  z 
)
inlineprivate

Definition at line 186 of file EssentialDisplacementCubitBcData.hpp.

187 {
192 t_ret(i) = tVal(i) + rot(i);
193 return t_ret;
194 };
static FTensor::Tensor1< double, 3 > GetRotDisp(const FTensor::Tensor1< double, 3 > &angles, FTensor::Tensor1< double, 3 > coordinates, FTensor::Tensor1< double, 3 > offset=FTensor::Tensor1< double, 3 >{ 0., 0., 0.})
Calculates the rotated displacement given the rotation angles, coordinates, and an optional offset.

Member Data Documentation

◆ dispFunction

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
VectorFun<FIELD_DIM> MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::dispFunction
private

Definition at line 184 of file EssentialDisplacementCubitBcData.hpp.

◆ tAngles

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
FTensor::Tensor1<double, 3> MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::tAngles
private

Definition at line 181 of file EssentialDisplacementCubitBcData.hpp.

◆ tOffset

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
FTensor::Tensor1<double, 3> MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::tOffset
private

Definition at line 182 of file EssentialDisplacementCubitBcData.hpp.

◆ tVal

Definition at line 180 of file EssentialDisplacementCubitBcData.hpp.

◆ vecOfTimeScalingMethods

template<int FIELD_DIM, AssemblyType A, IntegrationType I, typename OpBase >
VecOfTimeScalingMethods MoFEM::OpEssentialRhsImpl< DisplacementCubitBcData, 1, FIELD_DIM, A, I, OpBase >::vecOfTimeScalingMethods
private

Definition at line 183 of file EssentialDisplacementCubitBcData.hpp.


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