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

#include <j2p.h>

Inheritance diagram for StrainGageParam:
Collaboration diagram for StrainGageParam:

Public Member Functions

 StrainGageParam (unsigned int uL, const DofOwner *pDO, doublereal dy, doublereal dz, flag fOut)
 
virtual ~StrainGageParam (void)
 
virtual void Bind (const Elem *pEl, unsigned int i)
 
virtual std::ostream & Restart (std::ostream &out) const
 
virtual const doublerealdGetDofValue (int iDof, int iOrder=0) const
 
virtual const doublerealdGetX (void) const
 
- Public Member Functions inherited from Elem2Param
 Elem2Param (unsigned int uL, const DofOwner *pDO, flag fOut)
 
virtual ~Elem2Param (void)
 
std::ostream & RestartBind (std::ostream &out) const
 
virtual void SetDofValue (const doublereal &dValue, unsigned int iDof, unsigned int iOrder=0)
 
virtual void SetValue (DataManager *pDM, VectorHandler &, VectorHandler &, SimulationEntity::Hints *ph=0)
 
- Public Member Functions inherited from ParameterNode
 ParameterNode (unsigned int uL, const DofOwner *pDO, doublereal dx, flag fOut)
 
virtual ~ParameterNode (void)
 
virtual Node::Type GetNodeType (void) const
 
virtual unsigned int iGetNumDof (void) const
 
virtual DofOrder::Order GetDofType (unsigned int i) const
 
virtual void Output (OutputHandler &OH) const
 
void SetValue (DataManager *pDM, VectorHandler &X, VectorHandler &XP, SimulationEntity::Hints *ph=0)
 
virtual void Update (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual void Update (const VectorHandler &XCurr, const int iOrder)
 
virtual void AfterPredict (VectorHandler &X, VectorHandler &XP)
 
virtual unsigned int iGetNumPrivData (void) const
 
- Public Member Functions inherited from ScalarAlgebraicNode
 ScalarAlgebraicNode (unsigned int uL, const DofOwner *pDO, doublereal dx, flag fOut)
 
virtual ~ScalarAlgebraicNode (void)
 
virtual const doublerealdGetDofValuePrev (int iDof, int iOrder=0) const
 
virtual void SetX (const doublereal &d)
 
virtual void SetXPrime (const doublereal &d)
 
virtual const doublerealdGetXPrime (void) const
 
virtual void Update (const class VectorHandler &, const class VectorHandler &)
 
std::ostream & Restart (std::ostream &out) const
 
virtual unsigned int iGetPrivDataIdx (const char *s) const
 
- Public Member Functions inherited from ScalarNode
 ScalarNode (unsigned int uL, const DofOwner *pDO, flag fOut)
 
virtual ~ScalarNode (void)
 
- Public Member Functions inherited from Node
 Node (unsigned int uL, const DofOwner *pDO, flag fOut)
 
virtual ~Node (void)
 
const NodeGetNode (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 integer iGetFirstRowIndex (void) const
 
virtual integer iGetFirstColIndex (void) const
 
virtual doublereal dGetPrivData (unsigned int i) 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 DerivativesUpdate (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
virtual void Update (const VectorHandler &XCurr, InverseDynamics::Order iOrder)
 
virtual void AfterConvergence (const VectorHandler &X, const VectorHandler &XP)
 
virtual void AfterConvergence (const VectorHandler &X, const VectorHandler &XP, const VectorHandler &XPP)
 
virtual std::ostream & OutputAppend (std::ostream &out) const
 
virtual void ReadInitialState (MBDynParser &HP)
 
- Public Member Functions inherited from DofOwnerOwner
 DofOwnerOwner (const DofOwner *pDO)
 
virtual ~DofOwnerOwner ()
 
virtual const DofOwnerpGetDofOwner (void) const
 
virtual integer iGetFirstIndex (void) const
 
virtual void SetInitialValue (VectorHandler &X)
 
- Public Member Functions inherited from ToBeOutput
 ToBeOutput (flag fOut=fDefaultOut)
 
virtual ~ToBeOutput (void)
 
virtual void OutputPrepare (OutputHandler &OH)
 
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))
 

Protected Attributes

doublereal dY
 
doublereal dZ
 
- Protected Attributes inherited from Elem2Param
const ElempElem
 
unsigned int iNum
 
- Protected Attributes inherited from ScalarAlgebraicNode
doublereal dX
 
doublereal dXPrev
 
- Protected Attributes inherited from WithLabel
unsigned int uLabel
 
std::string sName
 
- Protected Attributes inherited from ToBeOutput
flag fOutput
 

Additional Inherited Members

- Public Types inherited from Node
enum  Type {
  UNKNOWN = -1, ABSTRACT = 0, STRUCTURAL, ELECTRIC,
  THERMAL, PARAMETER, HYDRAULIC, LASTNODETYPE
}
 
- 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 Member Functions inherited from ScalarAlgebraicNode
virtual std::ostream & Output (std::ostream &out) const
 

Detailed Description

Definition at line 101 of file j2p.h.

Constructor & Destructor Documentation

StrainGageParam::StrainGageParam ( unsigned int  uL,
const DofOwner pDO,
doublereal  dy,
doublereal  dz,
flag  fOut 
)

Definition at line 134 of file j2p.cc.

References NO_OP.

136 : Elem2Param(uL, pDO, fOut), dY(dy), dZ(dz)
137 {
138  NO_OP;
139 }
#define NO_OP
Definition: myassert.h:74
doublereal dY
Definition: j2p.h:103
Elem2Param(unsigned int uL, const DofOwner *pDO, flag fOut)
Definition: j2p.cc:40
doublereal dZ
Definition: j2p.h:104
StrainGageParam::~StrainGageParam ( void  )
virtual

Definition at line 141 of file j2p.cc.

References NO_OP.

142 {
143  NO_OP;
144 }
#define NO_OP
Definition: myassert.h:74

Member Function Documentation

void StrainGageParam::Bind ( const Elem pEl,
unsigned int  i 
)
virtual

Reimplemented from Elem2Param.

Definition at line 147 of file j2p.cc.

References ASSERT, Elem::BEAM, Elem2Param::Bind(), Elem::GetElemType(), ParameterNode::iGetNumPrivData(), SimulationEntity::iGetPrivDataIdx(), and MBDYN_EXCEPT_ARGS.

148 {
149  ASSERT(pEl != 0);
150  if (pEl->GetElemType() != Elem::BEAM) {
151  silent_cerr("StrainGageParam::Bind(): must bind to a beam"
152  << std::endl);
154  }
155 
156  /* Nota: ora i == 1 o 2 per punto di valutazione I o II */
157  const char *s;
158  switch (i) {
159  case 1:
160  s = "pI.ex";
161  break;
162 
163  case 2:
164  s = "pII.ex";
165  break;
166 
167  default:
169  }
170 
171  unsigned int idx = pEl->iGetPrivDataIdx(s);
172  ASSERT(idx > 0);
173  ASSERT(idx <= pEl->iGetNumPrivData());
174 
175  Elem2Param::Bind(pEl, idx);
176 }
#define MBDYN_EXCEPT_ARGS
Definition: except.h:63
virtual unsigned int iGetPrivDataIdx(const char *s) const
Definition: simentity.cc:142
virtual Elem::Type GetElemType(void) const =0
virtual unsigned int iGetNumPrivData(void) const
Definition: node.h:563
virtual void Bind(const Elem *pEl, unsigned int i)
Definition: j2p.cc:53
#define ASSERT(expression)
Definition: colamd.c:977

Here is the call graph for this function:

const doublereal & StrainGageParam::dGetDofValue ( int  iDof,
int  iOrder = 0 
) const
inlinevirtual

Reimplemented from Elem2Param.

Definition at line 129 of file j2p.h.

References ASSERT, and dGetX().

130 {
131  ASSERT(iDof == 1);
132  ASSERT(iOrder == 0);
133  return dGetX();
134 }
#define ASSERT(expression)
Definition: colamd.c:977
virtual const doublereal & dGetX(void) const
Definition: j2p.h:140

Here is the call graph for this function:

const doublereal & StrainGageParam::dGetX ( void  ) const
inlinevirtual

Reimplemented from Elem2Param.

Definition at line 140 of file j2p.h.

References SimulationEntity::dGetPrivData(), ScalarAlgebraicNode::dX, dY, dZ, Elem2Param::iNum, and Elem2Param::pElem.

Referenced by dGetDofValue().

141 {
142  unsigned int i = iNum - 1;
143 
144  dX = pElem->dGetPrivData(i + 1)
145  + dZ*pElem->dGetPrivData(i + 5)
146  - dY*pElem->dGetPrivData(i + 6);
147 
148  return dX;
149 }
doublereal dX
Definition: node.h:405
const Elem * pElem
Definition: j2p.h:42
unsigned int iNum
Definition: j2p.h:43
doublereal dY
Definition: j2p.h:103
virtual doublereal dGetPrivData(unsigned int i) const
Definition: simentity.cc:149
doublereal dZ
Definition: j2p.h:104

Here is the call graph for this function:

std::ostream & StrainGageParam::Restart ( std::ostream &  out) const
virtual

Reimplemented from Elem2Param.

Definition at line 180 of file j2p.cc.

181 {
182  return out << "StrainGageParam is not implemented yet" << std::endl;
183 }

Member Data Documentation

doublereal StrainGageParam::dY
protected

Definition at line 103 of file j2p.h.

Referenced by dGetX().

doublereal StrainGageParam::dZ
protected

Definition at line 104 of file j2p.h.

Referenced by dGetX().


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