v0.15.0
Loading...
Searching...
No Matches
KelvinVoigtDamper Struct Reference

Implementation of Kelvin Voigt Damper. More...

#include "users_modules/basic_finite_elements/src/KelvinVoigtDamper.hpp"

Collaboration diagram for KelvinVoigtDamper:
[legend]

Classes

struct  AssembleMatrix
 
struct  AssembleVector
 
struct  BlockMaterialData
 Dumper material parameters. More...
 
struct  CommonData
 Common data for nonlinear_elastic_elem model. More...
 
struct  ConstitutiveEquation
 Constitutive model functions. More...
 
struct  DamperFE
 definition of volume element More...
 
struct  OpGetDataAtGaussPts
 
struct  OpJacobian
 
struct  OpLhsdxdot
 Assemble matrix. More...
 
struct  OpLhsdxdx
 Assemble matrix. More...
 
struct  OpRhsStress
 Assemble internal force vector. More...
 

Public Types

enum  TagEvaluate { DAMPERSTRESS }
 
typedef boost::ptr_map< int, KelvinVoigtDamper::ConstitutiveEquation< adouble > > ConstitutiveEquationMap
 

Public Member Functions

 KelvinVoigtDamper (MoFEM::Interface &m_field)
 
MoFEMErrorCode setBlockDataMap ()
 
MoFEMErrorCode setOperators (const int tag)
 

Public Attributes

MoFEM::InterfacemField
 
std::map< int, BlockMaterialDatablockMaterialDataMap
 
ConstitutiveEquationMap constitutiveEquationMap
 
CommonData commonData
 
DamperFE feRhs
 
DamperFE feLhs
 

Detailed Description

Implementation of Kelvin Voigt Damper.

Examples
nonlinear_dynamics.cpp.

Definition at line 20 of file KelvinVoigtDamper.hpp.

Member Typedef Documentation

◆ ConstitutiveEquationMap

Member Enumeration Documentation

◆ TagEvaluate

Enumerator
DAMPERSTRESS 

Definition at line 22 of file KelvinVoigtDamper.hpp.

Constructor & Destructor Documentation

◆ KelvinVoigtDamper()

KelvinVoigtDamper::KelvinVoigtDamper ( MoFEM::Interface & m_field)
inline

Definition at line 249 of file KelvinVoigtDamper.hpp.

250 : mField(m_field), feRhs(m_field, commonData),
251 feLhs(m_field, commonData) {}
MoFEM::Interface & mField

Member Function Documentation

◆ setBlockDataMap()

MoFEMErrorCode KelvinVoigtDamper::setBlockDataMap ( )
inline

Definition at line 793 of file KelvinVoigtDamper.hpp.

793 {
795
797 if (it->getName().compare(0, 6, "DAMPER") == 0) {
798 std::vector<double> data;
799 CHKERR it->getAttributes(data);
800 if (data.size() < 2) {
801 SETERRQ(PETSC_COMM_SELF, 1, "Data inconsistency");
802 }
803 CHKERR mField.get_moab().get_entities_by_type(
804 it->meshset, MBTET, blockMaterialDataMap[it->getMeshsetId()].tEts,
805 true);
806 blockMaterialDataMap[it->getMeshsetId()].gBeta = data[0];
807 blockMaterialDataMap[it->getMeshsetId()].vBeta = data[1];
808 }
809 }
811 }
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
@ BLOCKSET
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
#define _IT_CUBITMESHSETS_BY_SET_TYPE_FOR_LOOP_(MESHSET_MANAGER, CUBITBCTYPE, IT)
Iterator that loops over a specific Cubit MeshSet having a particular BC meshset in a moFEM field.
std::map< int, BlockMaterialData > blockMaterialDataMap
virtual moab::Interface & get_moab()=0

◆ setOperators()

MoFEMErrorCode KelvinVoigtDamper::setOperators ( const int tag)
inline

Definition at line 813 of file KelvinVoigtDamper.hpp.

813 {
815
816 for (auto &&fe_ptr : {&feRhs, &feLhs}) {
817 // CHKERR addHOOpsVol(commonData.meshNodePositionName, *fe_ptr, true, false,
818 // false, false);
819 fe_ptr->getOpPtrVector().push_back(
820 new OpCalculateVectorFieldGradient<3, 3>(
823 fe_ptr->getOpPtrVector().push_back(new OpGetDataAtGaussPts(
824 commonData.spatialPositionName, commonData, false, true, false));
825 fe_ptr->getOpPtrVector().push_back(
826 new OpCalculateVectorFieldGradientDot<3, 3>(
829 fe_ptr->getOpPtrVector().push_back(new OpGetDataAtGaussPts(
830 commonData.spatialPositionName, commonData, false, true, true));
831 }
832
833 // attach tags for each recorder
834 std::vector<int> tags;
835 tags.push_back(tag);
836
837 ConstitutiveEquationMap::iterator mit = constitutiveEquationMap.begin();
838 for (; mit != constitutiveEquationMap.end(); mit++) {
839 ConstitutiveEquation<adouble> &ce =
840 constitutiveEquationMap.at(mit->first);
841 // Right hand side operators
842 feRhs.getOpPtrVector().push_back(new OpJacobian(
843 commonData.spatialPositionName, tags, ce, commonData, true, false));
844 feRhs.getOpPtrVector().push_back(new OpRhsStress(commonData));
845
846 // Left hand side operators
847 feLhs.getOpPtrVector().push_back(new OpJacobian(
848 commonData.spatialPositionName, tags, ce, commonData, false, true));
849 feLhs.getOpPtrVector().push_back(new OpLhsdxdx(commonData));
850 feLhs.getOpPtrVector().push_back(new OpLhsdxdot(commonData));
851 }
852
854 }
boost::shared_ptr< MatrixDouble > gradDataAtGaussTmpPtr
ConstitutiveEquationMap constitutiveEquationMap
boost::ptr_deque< UserDataOperator > & getOpPtrVector()
Use to push back operator for row operator.

Member Data Documentation

◆ blockMaterialDataMap

std::map<int, BlockMaterialData> KelvinVoigtDamper::blockMaterialDataMap

Definition at line 37 of file KelvinVoigtDamper.hpp.

◆ commonData

CommonData KelvinVoigtDamper::commonData

Definition at line 198 of file KelvinVoigtDamper.hpp.

◆ constitutiveEquationMap

ConstitutiveEquationMap KelvinVoigtDamper::constitutiveEquationMap

Definition at line 164 of file KelvinVoigtDamper.hpp.

◆ feLhs

DamperFE KelvinVoigtDamper::feLhs

Definition at line 247 of file KelvinVoigtDamper.hpp.

◆ feRhs

DamperFE KelvinVoigtDamper::feRhs

Definition at line 247 of file KelvinVoigtDamper.hpp.

◆ mField

MoFEM::Interface& KelvinVoigtDamper::mField

Definition at line 24 of file KelvinVoigtDamper.hpp.


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