MBDyn-1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
ViscoElasticBeam2 Class Reference

#include <beam2.h>

Inheritance diagram for ViscoElasticBeam2:
Collaboration diagram for ViscoElasticBeam2:

Public Member Functions

 ViscoElasticBeam2 (unsigned int uL, const StructNode *pN1, const StructNode *pN2, const Vec3 &F1, const Vec3 &F2, const Mat3x3 &R1, const Mat3x3 &R2, const Mat3x3 &r, const ConstitutiveLaw6D *pd, OrientationDescription ood, flag fOut)
 
virtual ~ViscoElasticBeam2 (void)
 
virtual Beam::Type GetBeamType (void) const
 
void SetValue (DataManager *pDM, VectorHandler &, VectorHandler &, SimulationEntity::Hints *ph=0)
 
virtual void AfterPredict (VectorHandler &, VectorHandler &)
 
virtual void AfterConvergence (const VectorHandler &X, const VectorHandler &XP)
 
virtual doublereal dGetPrivData (unsigned int i) const
 
- Public Member Functions inherited from Elem
 Elem (unsigned int uL, flag fOut)
 
virtual ~Elem (void)
 
virtual unsigned int iGetNumDof (void) const
 
virtual std::ostream & DescribeDof (std::ostream &out, const char *prefix="", bool bInitial=false) const
 
virtual void DescribeDof (std::vector< std::string > &desc, bool bInitial=false, int i=-1) const
 
virtual std::ostream & DescribeEq (std::ostream &out, const char *prefix="", bool bInitial=false) const
 
virtual void DescribeEq (std::vector< std::string > &desc, bool bInitial=false, int i=-1) const
 
virtual DofOrder::Order GetDofType (unsigned int) const
 
virtual void AssMats (VariableSubMatrixHandler &WorkMatA, VariableSubMatrixHandler &WorkMatB, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
void SetInverseDynamicsFlags (unsigned uIDF)
 
unsigned GetInverseDynamicsFlags (void) const
 
bool bIsErgonomy (void) const
 
bool bIsRightHandSide (void) const
 
virtual int GetNumConnectedNodes (void) const
 
- Public Member Functions inherited from WithLabel
 WithLabel (unsigned int uL=0, const std::string &sN="")
 
virtual ~WithLabel (void)
 
void PutLabel (unsigned int uL)
 
void PutName (const std::string &sN)
 
unsigned int GetLabel (void) const
 
const std::string & GetName (void) const
 
- Public Member Functions inherited from SimulationEntity
 SimulationEntity (void)
 
virtual ~SimulationEntity (void)
 
virtual bool bIsValidIndex (unsigned int i) const
 
virtual DofOrder::Order GetEqType (unsigned int i) const
 
virtual HintParseHint (DataManager *pDM, const char *s) const
 
virtual void BeforePredict (VectorHandler &, VectorHandler &, VectorHandler &, VectorHandler &) const
 
virtual void Update (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual void DerivativesUpdate (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual std::ostream & OutputAppend (std::ostream &out) const
 
virtual void ReadInitialState (MBDynParser &HP)
 
- Public Member Functions inherited from ToBeOutput
 ToBeOutput (flag fOut=fDefaultOut)
 
virtual ~ToBeOutput (void)
 
virtual void Output (OutputHandler &OH, const VectorHandler &X, const VectorHandler &XP) const
 
virtual flag fToBeOutput (void) const
 
virtual bool bToBeOutput (void) const
 
virtual void SetOutputFlag (flag f=flag(1))
 
- Public Member Functions inherited from Beam2
 Beam2 (unsigned int uL, const StructNode *pN1, const StructNode *pN2, const Vec3 &F1, const Vec3 &F2, const Mat3x3 &R1, const Mat3x3 &R2, const Mat3x3 &r, const ConstitutiveLaw6D *pd, OrientationDescription ood, flag fOut)
 
virtual ~Beam2 (void)
 
virtual Elem::Type GetElemType (void) const
 
virtual std::ostream & Restart (std::ostream &out) const
 
virtual void WorkSpaceDim (integer *piNumRows, integer *piNumCols) const
 
virtual SubVectorHandlerAssRes (SubVectorHandler &WorkVec, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual VariableSubMatrixHandlerAssJac (VariableSubMatrixHandler &WorkMat, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual void OutputPrepare (OutputHandler &OH)
 
virtual void Output (OutputHandler &OH) const
 
virtual bool bInverseDynamics (void) const
 
VariableSubMatrixHandlerAssJac (VariableSubMatrixHandler &WorkMat, const VectorHandler &XCurr)
 
SubVectorHandlerAssRes (SubVectorHandler &WorkVec, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr, const VectorHandler &XPrimePrimeCurr, InverseDynamics::Order iOrder=InverseDynamics::INVERSE_DYNAMICS)
 
void Update (const VectorHandler &XCurr, InverseDynamics::Order iOrder=InverseDynamics::INVERSE_DYNAMICS)
 
virtual void AfterConvergence (const VectorHandler &X, const VectorHandler &XP, const VectorHandler &XPP)
 
virtual unsigned int iGetInitialNumDof (void) const
 
virtual void InitialWorkSpaceDim (integer *piNumRows, integer *piNumCols) const
 
virtual void SetInitialValue (VectorHandler &)
 
virtual VariableSubMatrixHandlerInitialAssJac (VariableSubMatrixHandler &WorkMat, const VectorHandler &XCurr)
 
virtual SubVectorHandlerInitialAssRes (SubVectorHandler &WorkVec, const VectorHandler &XCurr)
 
virtual unsigned int iGetNumPrivData (void) const
 
virtual unsigned int iGetPrivDataIdx (const char *s) const
 
virtual const StructNodepGetNode (unsigned int i) const
 
virtual void GetConnectedNodes (std::vector< const Node * > &connectedNodes) const
 
- Public Member Functions inherited from ElemGravityOwner
 ElemGravityOwner (unsigned int uL, flag fOut)
 
virtual ~ElemGravityOwner (void)
 
virtual doublereal dGetM (void) const
 
Vec3 GetS (void) const
 
Mat3x3 GetJ (void) const
 
Vec3 GetB (void) const
 
Vec3 GetG (void) const
 
- Public Member Functions inherited from GravityOwner
 GravityOwner (void)
 
virtual ~GravityOwner (void)
 
void PutGravity (const Gravity *pG)
 
virtual bool bGetGravity (const Vec3 &X, Vec3 &Acc) const
 
- Public Member Functions inherited from InitialAssemblyElem
 InitialAssemblyElem (unsigned int uL, flag fOut)
 
virtual ~InitialAssemblyElem (void)
 
- Public Member Functions inherited from SubjectToInitialAssembly
 SubjectToInitialAssembly (void)
 
virtual ~SubjectToInitialAssembly (void)
 

Protected Member Functions

virtual void AssStiffnessMat (FullSubMatrixHandler &WMA, FullSubMatrixHandler &WMB, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual void AssStiffnessVec (SubVectorHandler &WorkVec, doublereal dCoef, const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
- Protected Member Functions inherited from Beam2
virtual Vec3 InterpState (const Vec3 &v1, const Vec3 &v2)
 
virtual Vec3 InterpDeriv (const Vec3 &v1, const Vec3 &v2)
 
virtual void AddInternalForces (Vec6 &)
 
virtual void AssInertiaMat (FullSubMatrixHandler &, FullSubMatrixHandler &, doublereal, const VectorHandler &, const VectorHandler &)
 
virtual void AssInertiaVec (SubVectorHandler &, doublereal, const VectorHandler &, const VectorHandler &)
 
virtual void DsDxi (void)
 
virtual void Omega0 (void)
 
void SetBeamType (Beam::Type T)
 
virtual std::ostream & Restart_ (std::ostream &out) const
 
- Protected Member Functions inherited from ElemGravityOwner
virtual Vec3 GetS_int (void) const
 
virtual Mat3x3 GetJ_int (void) const
 
virtual Vec3 GetB_int (void) const
 
virtual Vec3 GetG_int (void) const
 

Protected Attributes

Vec3 LPrime
 
Vec3 gPrime
 
Vec3 LPrimeRef
 
Vec6 DefPrimeLocRef
 
Mat6x6 ERef
 
- Protected Attributes inherited from WithLabel
unsigned int uLabel
 
std::string sName
 
- Protected Attributes inherited from ToBeOutput
flag fOutput
 
- Protected Attributes inherited from Beam2
unsigned uOutputFlags
 
OrientationDescription od
 
const StructNodepNode [NUMNODES]
 
Vec3 f [NUMNODES]
 
Vec3 fRef [NUMNODES]
 
Mat3x3 RNode [NUMNODES]
 
Mat3x3 R
 
Mat3x3 RRef
 
Mat3x3 RPrev
 
ConstitutiveLaw6DOwnerpD
 
Mat6x6 DRef
 
Vec3 Omega
 
Vec3 OmegaRef
 
Vec6 Az
 
Vec6 AzRef
 
Vec6 AzLoc
 
Vec6 DefLoc
 
Vec6 DefLocRef
 
Vec6 DefLocPrev
 
Vec6 DefPrimeLoc
 
Vec3 p
 
Vec3 g
 
Vec3 L0
 
Vec3 L
 
Vec3 LRef
 
doublereal dsdxi
 
bool bFirstRes
 
bool bFirstIDRes
 
- Protected Attributes inherited from GravityOwner
GravitypGravity
 

Additional Inherited Members

- Public Types inherited from Elem
enum  Type {
  UNKNOWN = -1, AIRPROPERTIES = 0, INDUCEDVELOCITY, AUTOMATICSTRUCTURAL,
  GRAVITY, BODY, JOINT, JOINT_REGULARIZATION,
  BEAM, PLATE, FORCE, INERTIA,
  ELECTRICBULK, ELECTRIC, THERMAL, HYDRAULIC,
  BULK, LOADABLE, DRIVEN, EXTERNAL,
  AEROMODAL, AERODYNAMIC, GENEL, SOCKETSTREAM_OUTPUT,
  RTAI_OUTPUT = SOCKETSTREAM_OUTPUT, LASTELEMTYPE
}
 
- Public Types inherited from SimulationEntity
typedef std::vector< Hint * > Hints
 
- Public Types inherited from ToBeOutput
enum  { OUTPUT = 0x1U, OUTPUT_MASK = 0xFU, OUTPUT_PRIVATE = 0x10U, OUTPUT_PRIVATE_MASK = ~OUTPUT_MASK }
 
- Protected Types inherited from Beam2
enum  NodeName { NODE1 = 0, NODE2 = 1, NUMNODES = 2 }
 
enum  Deformations { STRAIN = 0, CURVAT = 1, NUMDEFORM = 2 }
 

Detailed Description

Definition at line 363 of file beam2.h.

Constructor & Destructor Documentation

ViscoElasticBeam2::ViscoElasticBeam2 ( unsigned int  uL,
const StructNode pN1,
const StructNode pN2,
const Vec3 F1,
const Vec3 F2,
const Mat3x3 R1,
const Mat3x3 R2,
const Mat3x3 r,
const ConstitutiveLaw6D pd,
OrientationDescription  ood,
flag  fOut 
)

Definition at line 945 of file beam2.cc.

References Beam2::DefPrimeLoc, DefPrimeLocRef, ERef, ConstitutiveLawOwner< T, Tder >::GetFDEPrime(), gPrime, LPrime, LPrimeRef, MultRMRt(), Beam2::Omega, Beam2::Omega0(), Beam2::OmegaRef, Beam2::pD, Beam2::RRef, Zero3, and Zero6.

956 : Elem(uL, fOut),
957 Beam2(uL, pN1, pN2, F1, F2, R1, R2, r, pd, ood, fOut)
958 {
959  LPrimeRef = LPrime = Zero3;
960  gPrime = Zero3;
961 
963 
964  /* Nota: DsDxi() viene chiamata dal costruttore di Beam */
965  Beam2::Omega0();
966 
967  OmegaRef = Omega;
969 }
Vec3 LPrimeRef
Definition: beam2.h:370
Mat3x3 MultRMRt(const Mat3x3 &m, const Mat3x3 &R)
Definition: matvec3.cc:1162
Mat3x3 RRef
Definition: beam2.h:93
Vec3 Omega
Definition: beam2.h:103
Vec3 OmegaRef
Definition: beam2.h:104
const Vec3 Zero3(0., 0., 0.)
Mat6x6 ERef
Definition: beam2.h:376
ConstitutiveLaw6DOwner * pD
Definition: beam2.h:97
Vec6 DefPrimeLoc
Definition: beam2.h:115
const Vec6 Zero6(0., 0., 0., 0., 0., 0.)
Vec6 DefPrimeLocRef
Definition: beam2.h:374
virtual void Omega0(void)
Definition: beam2.cc:264
Elem(unsigned int uL, flag fOut)
Definition: elem.cc:41
const Tder & GetFDEPrime(void) const
Definition: constltp.h:303
Beam2(unsigned int uL, const StructNode *pN1, const StructNode *pN2, const Vec3 &F1, const Vec3 &F2, const Mat3x3 &R1, const Mat3x3 &R2, const Mat3x3 &r, const ConstitutiveLaw6D *pd, OrientationDescription ood, flag fOut)
Definition: beam2.cc:65

Here is the call graph for this function:

virtual ViscoElasticBeam2::~ViscoElasticBeam2 ( void  )
inlinevirtual

Definition at line 407 of file beam2.h.

References NO_OP.

407  {
408  NO_OP;
409  };
#define NO_OP
Definition: myassert.h:74

Member Function Documentation

void ViscoElasticBeam2::AfterConvergence ( const VectorHandler X,
const VectorHandler XP 
)
virtual

Reimplemented from Beam2.

Definition at line 972 of file beam2.cc.

References ConstitutiveLawOwner< T, Tder >::AfterConvergence(), Beam2::DefLoc, Beam2::DefLocPrev, Beam2::DefPrimeLoc, Beam2::pD, Beam2::R, and Beam2::RPrev.

974 {
975  RPrev = R;
976  DefLocPrev = DefLoc;
978 }
Mat3x3 RPrev
Definition: beam2.h:94
Vec6 DefLoc
Definition: beam2.h:110
Mat3x3 R
Definition: beam2.h:92
ConstitutiveLaw6DOwner * pD
Definition: beam2.h:97
Vec6 DefPrimeLoc
Definition: beam2.h:115
void AfterConvergence(const T &Eps, const T &EpsPrime=mb_zero< T >())
Definition: constltp.h:288
Vec6 DefLocPrev
Definition: beam2.h:112

Here is the call graph for this function:

void ViscoElasticBeam2::AfterPredict ( VectorHandler ,
VectorHandler  
)
virtual

Reimplemented from Beam2.

Reimplemented in PiezoActuatorVEBeam2.

Definition at line 1221 of file beam2.cc.

References Beam2::AddInternalForces(), Beam2::Az, Beam2::AzLoc, Beam2::AzRef, Beam2::bFirstRes, Vec3::Cross(), grad::Cross(), Beam2::DefLoc, Beam2::DefLocPrev, Beam2::DefLocRef, Beam2::DefPrimeLoc, DefPrimeLocRef, Beam2::DRef, ERef, Beam2::f, Beam2::g, ConstitutiveLawOwner< T, Tder >::GetF(), ConstitutiveLawOwner< T, Tder >::GetFDE(), ConstitutiveLawOwner< T, Tder >::GetFDEPrime(), StructNode::GetgPRef(), StructNode::GetgRef(), StructNode::GetRRef(), StructDispNode::GetVCurr(), Vec6::GetVec2(), StructNode::GetWRef(), StructDispNode::GetXCurr(), gPrime, Beam2::InterpDeriv(), Beam2::InterpState(), Beam2::L, Beam2::L0, LPrime, LPrimeRef, Beam2::LRef, CGR_Rot::MatG, CGR_Rot::MatR, MultRMRt(), MultRV(), Mat3x3::MulTV(), Beam2::NODE1, Beam2::NODE2, Beam2::NUMNODES, Beam2::Omega, Beam2::OmegaRef, Beam2::p, Beam2::pD, Beam2::pNode, Beam2::R, Beam2::RPrev, Beam2::RRef, and ConstitutiveLawOwner< T, Tder >::Update().

Referenced by PiezoActuatorVEBeam2::AfterPredict().

1223 {
1224  /*
1225  * Calcola le deformazioni, aggiorna il legame costitutivo
1226  * e crea la FDE
1227  */
1228 
1229  /* Recupera i dati dei nodi */
1230  Vec3 gNod[NUMNODES];
1231  Vec3 xTmp[NUMNODES];
1232 
1233  Vec3 gPrimeNod[NUMNODES];
1234  Vec3 xPrimeTmp[NUMNODES];
1235 
1236  for (unsigned int i = 0; i < NUMNODES; i++) {
1237  gNod[i] = pNode[i]->GetgRef();
1238  Vec3 fTmp = pNode[i]->GetRRef()*f[i];
1239  xTmp[i] = pNode[i]->GetXCurr() + fTmp;
1240  gPrimeNod[i] = pNode[i]->GetgPRef();
1241  xPrimeTmp[i] = pNode[i]->GetVCurr()
1242  + pNode[i]->GetWRef().Cross(fTmp);
1243  }
1244 
1245  Mat3x3 RDelta;
1246  Vec3 gGrad;
1247  Vec3 gPrimeGrad;
1248 
1249  /* Aggiorna le grandezze della trave nel punto di valutazione */
1250  /* Posizione */
1251  p = InterpState(xTmp[NODE1], xTmp[NODE2]);
1252 
1253  /* Matrici di rotazione */
1254  g = InterpState(gNod[NODE1], gNod[NODE2]);
1255  RDelta = Mat3x3(CGR_Rot::MatR, g);
1256  R = RRef = RDelta*RPrev;
1257 
1258  /* Velocita' angolare della sezione */
1259  gPrime = InterpState(gPrimeNod[NODE1], gPrimeNod[NODE2]);
1261 
1262  /* Derivate della posizione */
1263  L = LRef = InterpDeriv(xTmp[NODE1], xTmp[NODE2]);
1264 
1265  /* Derivate della velocita' */
1266  LPrime = LPrimeRef = InterpDeriv(xPrimeTmp[NODE1], xPrimeTmp[NODE2]);
1267 
1268  /* Derivate dei parametri di rotazione */
1269  gGrad = InterpDeriv(gNod[NODE1], gNod[NODE2]);
1270 
1271  /* Derivate delle derivate spaziali dei parametri di rotazione */
1272  gPrimeGrad = InterpDeriv(gPrimeNod[NODE1], gPrimeNod[NODE2]);
1273 
1274  /*
1275  * Calcola le deformazioni nel sistema locale nel punto di valutazione
1276  */
1277  DefLoc = DefLocRef = Vec6(R.MulTV(L) - L0,
1278  R.MulTV(Mat3x3(CGR_Rot::MatG, g)*gGrad) + DefLocPrev.GetVec2());
1279 
1280  /*
1281  * Calcola le velocita' di deformazione nel sistema locale
1282  * nel punto di valutazione
1283  */
1285  R.MulTV(Mat3x3(CGR_Rot::MatG, g)*gPrimeGrad
1286  + (Mat3x3(CGR_Rot::MatG, g)*gGrad).Cross(Omega)));
1287 
1288  /* Calcola le azioni interne */
1289  pD->Update(DefLoc, DefPrimeLoc);
1290  AzLoc = pD->GetF();
1291 
1292  /* corregge le azioni interne locali (piezo, ecc) */
1294 
1295  /* Porta le azioni interne nel sistema globale */
1296  Az = AzRef = MultRV(AzLoc, R);
1297 
1298  /* Aggiorna il legame costitutivo */
1299  DRef = MultRMRt(pD->GetFDE(), R);
1300  ERef = MultRMRt(pD->GetFDEPrime(), R);
1301 
1302  bFirstRes = true;
1303 }
Vec3 LPrimeRef
Definition: beam2.h:370
Mat3x3 MultRMRt(const Mat3x3 &m, const Mat3x3 &R)
Definition: matvec3.cc:1162
Mat3x3 RRef
Definition: beam2.h:93
Vec3 Omega
Definition: beam2.h:103
Vec6 Az
Definition: beam2.h:107
Vec3 OmegaRef
Definition: beam2.h:104
Vec3 Cross(const Vec3 &v) const
Definition: matvec3.h:218
Vec3 MultRV(const Vec3 &v, const Mat3x3 &R)
Definition: matvec3.cc:1144
virtual const Mat3x3 & GetRRef(void) const
Definition: strnode.h:1006
Definition: matvec3.h:98
const Vec3 & GetVec2(void) const
Definition: matvec6.h:76
Mat3x3 RPrev
Definition: beam2.h:94
Vec3 L
Definition: beam2.h:120
Vec3 L0
Definition: beam2.h:119
const StructNode * pNode[NUMNODES]
Definition: beam2.h:83
const Tder & GetFDE(void) const
Definition: constltp.h:298
virtual const Vec3 & GetWRef(void) const
Definition: strnode.h:1024
Vec6 DefLoc
Definition: beam2.h:110
Vec3 LRef
Definition: beam2.h:122
Vec3 MulTV(const Vec3 &v) const
Definition: matvec3.cc:482
virtual Vec3 InterpState(const Vec3 &v1, const Vec3 &v2)
Definition: beam2.cc:208
Vec6 AzRef
Definition: beam2.h:108
Mat6x6 ERef
Definition: beam2.h:376
bool bFirstRes
Definition: beam2.h:127
Mat3x3 R
Definition: beam2.h:92
Definition: matvec6.h:37
ConstitutiveLaw6DOwner * pD
Definition: beam2.h:97
Vec6 DefPrimeLoc
Definition: beam2.h:115
Vec3 p
Definition: beam2.h:117
Vec6 DefPrimeLocRef
Definition: beam2.h:374
const MatG_Manip MatG
Definition: matvec3.cc:646
Mat6x6 DRef
Definition: beam2.h:100
const MatR_Manip MatR
Definition: matvec3.cc:645
VectorExpression< VectorCrossExpr< VectorLhsExpr, VectorRhsExpr >, 3 > Cross(const VectorExpression< VectorLhsExpr, 3 > &u, const VectorExpression< VectorRhsExpr, 3 > &v)
Definition: matvec.h:3248
virtual const Vec3 & GetXCurr(void) const
Definition: strnode.h:310
const T & GetF(void) const
Definition: constltp.h:293
Vec6 DefLocPrev
Definition: beam2.h:112
virtual const Vec3 & GetgRef(void) const
Definition: strnode.h:976
Vec6 AzLoc
Definition: beam2.h:109
virtual Vec3 InterpDeriv(const Vec3 &v1, const Vec3 &v2)
Definition: beam2.cc:219
virtual const Vec3 & GetVCurr(void) const
Definition: strnode.h:322
virtual void AddInternalForces(Vec6 &)
Definition: beam2.h:154
virtual const Vec3 & GetgPRef(void) const
Definition: strnode.h:988
const Tder & GetFDEPrime(void) const
Definition: constltp.h:303
void Update(const T &Eps, const T &EpsPrime=mb_zero< T >())
Definition: constltp.h:283
Vec6 DefLocRef
Definition: beam2.h:111
Vec3 f[NUMNODES]
Definition: beam2.h:86
Vec3 g
Definition: beam2.h:118

Here is the call graph for this function:

void ViscoElasticBeam2::AssStiffnessMat ( FullSubMatrixHandler WMA,
FullSubMatrixHandler WMB,
doublereal  dCoef,
const VectorHandler XCurr,
const VectorHandler XPrimeCurr 
)
protectedvirtual

Reimplemented from Beam2.

Reimplemented in PiezoActuatorVEBeam2.

Definition at line 983 of file beam2.cc.

References FullSubMatrixHandler::Add(), Beam2::Az, Vec3::Cross(), grad::Cross(), DEBUGCOUTFNAME, dN2, dN2P, Beam2::DRef, Beam2::dsdxi, ERef, Beam2::f, StructNode::GetRCurr(), Vec6::GetVec1(), Vec6::GetVec2(), StructDispNode::GetXCurr(), Beam2::L, LPrime, MatCross, MatCrossCross, mb_deye< Mat3x3 >(), Beam2::NODE1, Beam2::NODE2, Beam2::NUMNODES, Beam2::Omega, Beam2::p, Beam2::pNode, FullSubMatrixHandler::Sub(), Mat6x6::SubMat12(), Mat6x6::SubMat22(), and Zero3x3.

Referenced by PiezoActuatorVEBeam2::AssStiffnessMat().

988 {
989  DEBUGCOUTFNAME("ViscoElasticBeam2::AssStiffnessMat");
990 
991  /*
992  * La matrice arriva gia' dimensionata
993  * e con gli indici di righe e colonne a posto
994  */
995 
996  /* offset nel riferimento globale */
997  Vec3 fTmp[NUMNODES];
998  for (unsigned int i = 0; i < NUMNODES; i++) {
999  fTmp[i] = pNode[i]->GetRCurr()*f[i];
1000  }
1001 
1002  Mat6x6 AzTmp[NUMNODES];
1003  Mat6x6 AzPrimeTmp[NUMNODES];
1004 
1005  for (unsigned int i = 0; i < NUMNODES; i++) {
1006  /* Delta - deformazioni */
1007  AzTmp[i] = AzPrimeTmp[i] = Mat6x6(mb_deye<Mat3x3>(dN2P[i]*dsdxi),
1008  Zero3x3,
1009  Mat3x3(MatCross, L*dN2[i] - fTmp[i]*(dN2P[i]*dsdxi)),
1010  mb_deye<Mat3x3>(dN2P[i]*dsdxi));
1011 
1012  AzTmp[i] = DRef*AzTmp[i]*dCoef;
1013 
1014  AzTmp[i] += ERef*Mat6x6(Mat3x3(MatCross, Omega*(-dN2P[i]*dsdxi*dCoef)),
1015  Zero3x3,
1016  (Mat3x3(MatCross, LPrime) - Mat3x3(MatCrossCross, Omega, L))*(dN2[i]*dCoef)
1017  + Mat3x3(MatCrossCross, Omega, fTmp[i]*(dN2P[i]*dsdxi*dCoef))
1018  + Mat3x3(MatCross, fTmp[i].Cross(pNode[i]->GetWCurr()*(dN2P[i]*dsdxi*dCoef))),
1019  Mat3x3(MatCross, Omega*(-dN2P[i]*dsdxi*dCoef)));
1020 
1021  AzPrimeTmp[i] = ERef*AzPrimeTmp[i];
1022 
1023  /* Correggo per la rotazione da locale a globale */
1024  AzTmp[i].SubMat12(Mat3x3(MatCross, Az.GetVec1()*(dN2[i]*dCoef)));
1025  AzTmp[i].SubMat22(Mat3x3(MatCross, Az.GetVec2()*(dN2[i]*dCoef)));
1026  }
1027 
1028  Vec3 bTmp[NUMNODES];
1029 
1030  bTmp[NODE1] = p-pNode[NODE1]->GetXCurr();
1031  bTmp[NODE2] = p-pNode[NODE2]->GetXCurr();
1032 
1033  for (unsigned int i = 0; i < NUMNODES; i++) {
1034  /* Equazione all'indietro: */
1035  WMA.Sub(1, 6*i + 1, AzTmp[i].GetMat11());
1036  WMA.Sub(1, 6*i + 4, AzTmp[i].GetMat12());
1037 
1038  WMA.Sub(4, 6*i + 1,
1039  AzTmp[i].GetMat21()
1040  - Mat3x3(MatCross, Az.GetVec1()*(dCoef*dN2[i]))
1041  + bTmp[NODE1].Cross(AzTmp[i].GetMat11()));
1042  WMA.Sub(4, 6*i + 4,
1043  AzTmp[i].GetMat22()
1044  - Mat3x3(MatCrossCross, Az.GetVec1()*(-dCoef*dN2[i]), fTmp[i])
1045  + bTmp[NODE1].Cross(AzTmp[i].GetMat12()));
1046 
1047  /* Equazione in avanti: */
1048  WMA.Add(7, 6*i + 1, AzTmp[i].GetMat11());
1049  WMA.Add(7, 6*i + 4, AzTmp[i].GetMat12());
1050 
1051  WMA.Add(10, 6*i + 1,
1052  AzTmp[i].GetMat21()
1053  - Mat3x3(MatCross, Az.GetVec1()*(dCoef*dN2[i]))
1054  + bTmp[NODE2].Cross(AzTmp[i].GetMat11()));
1055  WMA.Add(10, 6*i + 4,
1056  AzTmp[i].GetMat22()
1057  + Mat3x3(MatCrossCross, Az.GetVec1()*(dCoef*dN2[i]), fTmp[i])
1058  + bTmp[NODE2].Cross(AzTmp[i].GetMat12()));
1059 
1060  /* Equazione viscosa all'indietro: */
1061  WMB.Sub(1, 6*i + 1, AzPrimeTmp[i].GetMat11());
1062  WMB.Sub(1, 6*i + 4, AzPrimeTmp[i].GetMat12());
1063 
1064  WMB.Sub(4, 6*i + 1,
1065  AzPrimeTmp[i].GetMat21()
1066  + bTmp[NODE1].Cross(AzPrimeTmp[i].GetMat11()));
1067  WMB.Sub(4, 6*i + 4,
1068  AzPrimeTmp[i].GetMat22()
1069  + bTmp[NODE1].Cross(AzPrimeTmp[i].GetMat12()));
1070 
1071  /* Equazione viscosa in avanti: */
1072  WMB.Add(7, 6*i + 1, AzPrimeTmp[i].GetMat11());
1073  WMB.Add(7, 6*i + 4, AzPrimeTmp[i].GetMat12());
1074 
1075  WMB.Add(10, 6*i + 1,
1076  AzPrimeTmp[i].GetMat21()
1077  + bTmp[NODE2].Cross(AzPrimeTmp[i].GetMat11()));
1078  WMB.Add(10, 6*i + 4,
1079  AzPrimeTmp[i].GetMat22()
1080  + bTmp[NODE2].Cross(AzPrimeTmp[i].GetMat12()));
1081  }
1082 
1083  /* correzione alle equazioni */
1084  Mat3x3 FTmp(MatCross, Az.GetVec1()*dCoef);
1085  WMA.Sub(4, 1, FTmp);
1086  WMA.Add(10, 7, FTmp);
1087 };
Vec3 Omega
Definition: beam2.h:103
Vec6 Az
Definition: beam2.h:107
Vec3 Cross(const Vec3 &v) const
Definition: matvec3.h:218
Definition: matvec3.h:98
#define DEBUGCOUTFNAME(fname)
Definition: myassert.h:256
const Vec3 & GetVec2(void) const
Definition: matvec6.h:76
const MatCross_Manip MatCross
Definition: matvec3.cc:639
virtual const Mat3x3 & GetRCurr(void) const
Definition: strnode.h:1012
Vec3 L
Definition: beam2.h:120
void Add(integer iRow, integer iCol, const Vec3 &v)
Definition: submat.cc:209
const StructNode * pNode[NUMNODES]
Definition: beam2.h:83
Mat3x3 mb_deye< Mat3x3 >(const doublereal d)
Definition: matvec3.h:1584
const Mat3x3 Zero3x3(0., 0., 0., 0., 0., 0., 0., 0., 0.)
Mat6x6 ERef
Definition: beam2.h:376
const Vec3 & GetVec1(void) const
Definition: matvec6.h:72
const doublereal dN2[2]
Definition: shapefnc.cc:52
void SubMat12(const Mat3x3 &x)
Definition: matvec6.h:416
void SubMat22(const Mat3x3 &x)
Definition: matvec6.h:420
Vec3 p
Definition: beam2.h:117
Mat6x6 DRef
Definition: beam2.h:100
doublereal dsdxi
Definition: beam2.h:124
const doublereal dN2P[2]
Definition: shapefnc.cc:56
VectorExpression< VectorCrossExpr< VectorLhsExpr, VectorRhsExpr >, 3 > Cross(const VectorExpression< VectorLhsExpr, 3 > &u, const VectorExpression< VectorRhsExpr, 3 > &v)
Definition: matvec.h:3248
virtual const Vec3 & GetXCurr(void) const
Definition: strnode.h:310
const MatCrossCross_Manip MatCrossCross
Definition: matvec3.cc:640
void Sub(integer iRow, integer iCol, const Vec3 &v)
Definition: submat.cc:215
Vec3 f[NUMNODES]
Definition: beam2.h:86

Here is the call graph for this function:

void ViscoElasticBeam2::AssStiffnessVec ( SubVectorHandler WorkVec,
doublereal  dCoef,
const VectorHandler XCurr,
const VectorHandler XPrimeCurr 
)
protectedvirtual

Reimplemented from Beam2.

Reimplemented in PiezoActuatorVEBeam2.

Definition at line 1092 of file beam2.cc.

References VectorHandler::Add(), Beam2::AddInternalForces(), Beam2::Az, Beam2::AzLoc, Beam2::bFirstRes, Vec3::Cross(), grad::Cross(), DEBUGCOUTFNAME, Beam2::DefLoc, Beam2::DefLocRef, Beam2::DefPrimeLoc, DefPrimeLocRef, Beam2::f, Beam2::g, ConstitutiveLawOwner< T, Tder >::GetF(), StructNode::GetgCurr(), StructNode::GetgPCurr(), StructNode::GetRCurr(), StructDispNode::GetVCurr(), Vec6::GetVec1(), Vec6::GetVec2(), StructNode::GetWCurr(), StructDispNode::GetXCurr(), gPrime, Beam2::InterpDeriv(), Beam2::InterpState(), Beam2::L, Beam2::L0, LPrime, CGR_Rot::MatG, CGR_Rot::MatR, MultRV(), Mat3x3::MulTV(), Beam2::NODE1, Beam2::NODE2, Beam2::NUMNODES, Beam2::Omega, Beam2::OmegaRef, Beam2::p, Beam2::pD, Beam2::pNode, Beam2::R, Beam2::RRef, VectorHandler::Sub(), and ConstitutiveLawOwner< T, Tder >::Update().

Referenced by PiezoActuatorVEBeam2::AssStiffnessVec().

1096 {
1097  DEBUGCOUTFNAME("ViscoElasticBeam2::AssStiffnessVec");
1098 
1099  /*
1100  * Riceve il vettore gia' dimensionato e con gli indici a posto
1101  * per scrivere il residuo delle equazioni di equilibrio dei due nodi
1102  */
1103 
1104  /*
1105  * Per la trattazione teorica, il riferimento e' il file ul-travi.tex
1106  * (ora e' superato)
1107  */
1108 
1109  if (bFirstRes) {
1110  bFirstRes = false; /* AfterPredict ha gia' calcolato tutto */
1111 
1112  } else {
1113  Vec3 gNod[NUMNODES];
1114  Vec3 xTmp[NUMNODES];
1115 
1116  Vec3 gPrimeNod[NUMNODES];
1117  Vec3 xPrimeTmp[NUMNODES];
1118 
1119  for (unsigned int i = 0; i < NUMNODES; i++) {
1120  gNod[i] = pNode[i]->GetgCurr();
1121  Vec3 fTmp = pNode[i]->GetRCurr()*f[i];
1122  xTmp[i] = pNode[i]->GetXCurr() + fTmp;
1123  gPrimeNod[i] = pNode[i]->GetgPCurr();
1124  xPrimeTmp[i] = pNode[i]->GetVCurr()
1125  + pNode[i]->GetWCurr().Cross(fTmp);
1126  }
1127 
1128  Mat3x3 RDelta;
1129  Vec3 gGrad;
1130  Vec3 gPrimeGrad;
1131 
1132  /*
1133  * Aggiorna le grandezze della trave nel punto di valutazione
1134  */
1135 
1136  /* Posizione */
1137  p = InterpState(xTmp[NODE1], xTmp[NODE2]);
1138 
1139  /* Matrici di rotazione */
1140  g = InterpState(gNod[NODE1], gNod[NODE2]);
1141  RDelta = Mat3x3(CGR_Rot::MatR, g);
1142  R = RDelta*RRef;
1143 
1144  /* Velocita' angolare della sezione */
1145  gPrime = InterpState(gPrimeNod[NODE1], gPrimeNod[NODE2]);
1146  Omega = Mat3x3(CGR_Rot::MatG, g)*gPrime + RDelta*OmegaRef;
1147 
1148  /* Derivate della posizione */
1149  L = InterpDeriv(xTmp[NODE1], xTmp[NODE2]);
1150 
1151  /* Derivate della velocita' */
1152  LPrime = InterpDeriv(xPrimeTmp[NODE1], xPrimeTmp[NODE2]);
1153 
1154  /* Derivate dei parametri di rotazione */
1155  gGrad = InterpDeriv(gNod[NODE1], gNod[NODE2]);
1156 
1157  /*
1158  * Derivate delle derivate spaziali dei parametri di rotazione
1159  */
1160  gPrimeGrad = InterpDeriv(gPrimeNod[NODE1], gPrimeNod[NODE2]);
1161 
1162  /*
1163  * Calcola le deformazioni nel sistema locale nel punto
1164  * di valutazione
1165  */
1166  DefLoc = Vec6(R.MulTV(L) - L0,
1167  R.MulTV(Mat3x3(CGR_Rot::MatG, g)*gGrad) + DefLocRef.GetVec2());
1168 
1169  /*
1170  * Calcola le velocita' di deformazione nel sistema locale
1171  * nel punto di valutazione
1172  */
1174  R.MulTV(Mat3x3(CGR_Rot::MatG, g)*gPrimeGrad
1175  + (Mat3x3(CGR_Rot::MatG, g)*gGrad).Cross(Omega))
1176  + DefPrimeLocRef.GetVec2());
1177 
1178  /* Calcola le azioni interne */
1179  pD->Update(DefLoc, DefPrimeLoc);
1180  AzLoc = pD->GetF();
1181 
1182  /* corregge le azioni interne locali (piezo, ecc) */
1184 
1185  /* Porta le azioni interne nel sistema globale */
1186  Az = MultRV(AzLoc, R);
1187  }
1188 
1189  WorkVec.Add(1, Az.GetVec1());
1190  WorkVec.Add(4, (p - pNode[NODE1]->GetXCurr()).Cross(Az.GetVec1()) + Az.GetVec2());
1191  WorkVec.Sub(7, Az.GetVec1());
1192  WorkVec.Sub(10, Az.GetVec2() + (p - pNode[NODE2]->GetXCurr()).Cross(Az.GetVec1()));
1193 }
Mat3x3 RRef
Definition: beam2.h:93
Vec3 Omega
Definition: beam2.h:103
Vec6 Az
Definition: beam2.h:107
Vec3 OmegaRef
Definition: beam2.h:104
Vec3 Cross(const Vec3 &v) const
Definition: matvec3.h:218
Vec3 MultRV(const Vec3 &v, const Mat3x3 &R)
Definition: matvec3.cc:1144
Definition: matvec3.h:98
#define DEBUGCOUTFNAME(fname)
Definition: myassert.h:256
const Vec3 & GetVec2(void) const
Definition: matvec6.h:76
virtual const Vec3 & GetgCurr(void) const
Definition: strnode.h:982
virtual const Mat3x3 & GetRCurr(void) const
Definition: strnode.h:1012
Vec3 L
Definition: beam2.h:120
Vec3 L0
Definition: beam2.h:119
const StructNode * pNode[NUMNODES]
Definition: beam2.h:83
virtual void Sub(integer iRow, const Vec3 &v)
Definition: vh.cc:78
Vec6 DefLoc
Definition: beam2.h:110
Vec3 MulTV(const Vec3 &v) const
Definition: matvec3.cc:482
virtual Vec3 InterpState(const Vec3 &v1, const Vec3 &v2)
Definition: beam2.cc:208
bool bFirstRes
Definition: beam2.h:127
Mat3x3 R
Definition: beam2.h:92
Definition: matvec6.h:37
const Vec3 & GetVec1(void) const
Definition: matvec6.h:72
ConstitutiveLaw6DOwner * pD
Definition: beam2.h:97
Vec6 DefPrimeLoc
Definition: beam2.h:115
Vec3 p
Definition: beam2.h:117
Vec6 DefPrimeLocRef
Definition: beam2.h:374
const MatG_Manip MatG
Definition: matvec3.cc:646
virtual const Vec3 & GetWCurr(void) const
Definition: strnode.h:1030
const MatR_Manip MatR
Definition: matvec3.cc:645
VectorExpression< VectorCrossExpr< VectorLhsExpr, VectorRhsExpr >, 3 > Cross(const VectorExpression< VectorLhsExpr, 3 > &u, const VectorExpression< VectorRhsExpr, 3 > &v)
Definition: matvec.h:3248
virtual const Vec3 & GetXCurr(void) const
Definition: strnode.h:310
virtual void Add(integer iRow, const Vec3 &v)
Definition: vh.cc:63
const T & GetF(void) const
Definition: constltp.h:293
virtual const Vec3 & GetgPCurr(void) const
Definition: strnode.h:994
Vec6 AzLoc
Definition: beam2.h:109
virtual Vec3 InterpDeriv(const Vec3 &v1, const Vec3 &v2)
Definition: beam2.cc:219
virtual const Vec3 & GetVCurr(void) const
Definition: strnode.h:322
virtual void AddInternalForces(Vec6 &)
Definition: beam2.h:154
void Update(const T &Eps, const T &EpsPrime=mb_zero< T >())
Definition: constltp.h:283
Vec6 DefLocRef
Definition: beam2.h:111
Vec3 f[NUMNODES]
Definition: beam2.h:86
Vec3 g
Definition: beam2.h:118

Here is the call graph for this function:

doublereal ViscoElasticBeam2::dGetPrivData ( unsigned int  i) const
virtual

Reimplemented from Beam2.

Definition at line 1306 of file beam2.cc.

References ASSERT, Beam2::DefPrimeLoc, Vec6::dGet(), Beam2::dGetPrivData(), and Beam2::iGetNumPrivData().

1307 {
1308  ASSERT(i > 0 && i <= iGetNumPrivData());
1309 
1310  switch (i) {
1311  case 22:
1312  case 23:
1313  case 24:
1314  case 25:
1315  case 26:
1316  case 27:
1317  return DefPrimeLoc.dGet(i - 21);
1318 
1319  default:
1320  return Beam2::dGetPrivData(i);
1321  }
1322 }
Vec6 DefPrimeLoc
Definition: beam2.h:115
virtual doublereal dGetPrivData(unsigned int i) const
Definition: beam2.cc:164
#define ASSERT(expression)
Definition: colamd.c:977
virtual unsigned int iGetNumPrivData(void) const
Definition: beam2.cc:147
const doublereal & dGet(unsigned short int i) const
Definition: matvec6.h:182

Here is the call graph for this function:

virtual Beam::Type ViscoElasticBeam2::GetBeamType ( void  ) const
inlinevirtual

Reimplemented from Beam2.

Reimplemented in PiezoActuatorVEBeam2.

Definition at line 412 of file beam2.h.

References Beam::VISCOELASTIC.

412  {
413  return Beam::VISCOELASTIC;
414  };
void ViscoElasticBeam2::SetValue ( DataManager pDM,
VectorHandler X,
VectorHandler XP,
SimulationEntity::Hints ph = 0 
)
virtual

Reimplemented from Beam2.

Reimplemented in PiezoActuatorVEBeam2.

Definition at line 1198 of file beam2.cc.

References ASSERT, Beam2::bFirstRes, Beam2::DefPrimeLoc, DefPrimeLocRef, ERef, ConstitutiveLawOwner< T, Tder >::GetFDEPrime(), LPrime, LPrimeRef, MultRMRt(), Beam2::Omega, Beam2::OmegaRef, Beam2::pD, Beam2::RRef, and Beam2::SetValue().

Referenced by PiezoActuatorVEBeam2::SetValue().

1201 {
1202  Beam2::SetValue(pDM, X, XP, ph);
1203 
1204  /* Aggiorna le grandezze della trave nei punti di valutazione */
1205  OmegaRef = Omega;
1206  LPrimeRef = LPrime;
1208 
1209  /*
1210  * Aggiorna il legame costitutivo di riferimento
1211  * (la deformazione e' gia' stata aggiornata dall'ultimo residuo)
1212  */
1213  ERef = MultRMRt(pD->GetFDEPrime(), RRef);
1214 
1215  ASSERT(bFirstRes == true);
1216 }
Vec3 LPrimeRef
Definition: beam2.h:370
Mat3x3 MultRMRt(const Mat3x3 &m, const Mat3x3 &R)
Definition: matvec3.cc:1162
Mat3x3 RRef
Definition: beam2.h:93
Vec3 Omega
Definition: beam2.h:103
Vec3 OmegaRef
Definition: beam2.h:104
void SetValue(DataManager *pDM, VectorHandler &, VectorHandler &, SimulationEntity::Hints *ph=0)
Definition: beam2.cc:543
Mat6x6 ERef
Definition: beam2.h:376
bool bFirstRes
Definition: beam2.h:127
ConstitutiveLaw6DOwner * pD
Definition: beam2.h:97
Vec6 DefPrimeLoc
Definition: beam2.h:115
Vec6 DefPrimeLocRef
Definition: beam2.h:374
#define ASSERT(expression)
Definition: colamd.c:977
const Tder & GetFDEPrime(void) const
Definition: constltp.h:303

Here is the call graph for this function:

Member Data Documentation

Vec6 ViscoElasticBeam2::DefPrimeLocRef
protected

Definition at line 374 of file beam2.h.

Referenced by AfterPredict(), AssStiffnessVec(), SetValue(), and ViscoElasticBeam2().

Mat6x6 ViscoElasticBeam2::ERef
protected

Definition at line 376 of file beam2.h.

Referenced by AfterPredict(), AssStiffnessMat(), SetValue(), and ViscoElasticBeam2().

Vec3 ViscoElasticBeam2::gPrime
protected

Definition at line 368 of file beam2.h.

Referenced by AfterPredict(), AssStiffnessVec(), and ViscoElasticBeam2().

Vec3 ViscoElasticBeam2::LPrime
protected

Definition at line 367 of file beam2.h.

Referenced by AfterPredict(), AssStiffnessMat(), AssStiffnessVec(), SetValue(), and ViscoElasticBeam2().

Vec3 ViscoElasticBeam2::LPrimeRef
protected

Definition at line 370 of file beam2.h.

Referenced by AfterPredict(), SetValue(), and ViscoElasticBeam2().


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