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

#include <node.h>

Inheritance diagram for Node:
Collaboration diagram for Node:

Classes

class  ErrGeneric
 

Public Types

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 }
 

Public Member Functions

 Node (unsigned int uL, const DofOwner *pDO, flag fOut)
 
virtual ~Node (void)
 
const NodeGetNode (void) const
 
virtual Node::Type GetNodeType (void) const =0
 
virtual std::ostream & Restart (std::ostream &out) const =0
 
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 const doublerealdGetDofValue (int iDof, int iOrder=0) const =0
 
virtual const doublerealdGetDofValuePrev (int iDof, int iOrder=0) const =0
 
virtual void SetDofValue (const doublereal &dValue, unsigned int iDof, unsigned int iOrder=0)=0
 
virtual unsigned int iGetNumPrivData (void) const
 
virtual unsigned int iGetPrivDataIdx (const char *s) 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 unsigned int iGetNumDof (void) const =0
 
virtual bool bIsValidIndex (unsigned int i) const
 
virtual DofOrder::Order GetDofType (unsigned int i) const =0
 
virtual DofOrder::Order GetEqType (unsigned int i) const
 
virtual void SetValue (DataManager *pDM, VectorHandler &X, VectorHandler &XP, SimulationEntity::Hints *h=0)
 
virtual HintParseHint (DataManager *pDM, const char *s) const
 
virtual void BeforePredict (VectorHandler &, VectorHandler &, VectorHandler &, VectorHandler &) const
 
virtual void AfterPredict (VectorHandler &X, VectorHandler &XP)
 
virtual void Update (const VectorHandler &XCurr, const VectorHandler &XPrimeCurr)
 
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
 
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))
 

Additional Inherited Members

- Protected Attributes inherited from WithLabel
unsigned int uLabel
 
std::string sName
 
- Protected Attributes inherited from ToBeOutput
flag fOutput
 

Detailed Description

Definition at line 67 of file node.h.

Member Enumeration Documentation

enum Node::Type
Enumerator
UNKNOWN 
ABSTRACT 
STRUCTURAL 
ELECTRIC 
THERMAL 
PARAMETER 
HYDRAULIC 
LASTNODETYPE 

Definition at line 71 of file node.h.

71  {
72  UNKNOWN = -1,
73 
74  /* Should be Node::SCALAR; keep using Node::ABSTRACT
75  * for backward compatibility */
76  ABSTRACT = 0,
77 
78  STRUCTURAL,
79  ELECTRIC,
80  THERMAL,
81  PARAMETER,
82  HYDRAULIC,
83 
85  };

Constructor & Destructor Documentation

Node::Node ( unsigned int  uL,
const DofOwner pDO,
flag  fOut 
)

Definition at line 42 of file node.cc.

References NO_OP.

43 : WithLabel(uL), DofOwnerOwner(pDO), ToBeOutput(fOut)
44 {
45  NO_OP;
46 }
ToBeOutput(flag fOut=fDefaultOut)
Definition: output.cc:851
DofOwnerOwner(const DofOwner *pDO)
Definition: dofown.cc:49
#define NO_OP
Definition: myassert.h:74
WithLabel(unsigned int uL=0, const std::string &sN="")
Definition: withlab.cc:38
Node::~Node ( void  )
virtual

Definition at line 49 of file node.cc.

References NO_OP.

50 {
51  NO_OP;
52 }
#define NO_OP
Definition: myassert.h:74

Member Function Documentation

std::ostream & Node::DescribeDof ( std::ostream &  out,
const char *  prefix = "",
bool  bInitial = false 
) const
virtual

Implements SimulationEntity.

Reimplemented in ModalNode, DynamicStructNode, StructNode, DynamicStructDispNode, and StructDispNode.

Definition at line 55 of file node.cc.

56 {
57  return out;
58 }
void Node::DescribeDof ( std::vector< std::string > &  desc,
bool  bInitial = false,
int  i = -1 
) const
virtual

Implements SimulationEntity.

Reimplemented in ModalNode, DynamicStructNode, StructNode, DynamicStructDispNode, and StructDispNode.

Definition at line 61 of file node.cc.

References ASSERT.

62 {
63  ASSERT(i <= 0);
64  desc.resize(0);
65 }
#define ASSERT(expression)
Definition: colamd.c:977
std::ostream & Node::DescribeEq ( std::ostream &  out,
const char *  prefix = "",
bool  bInitial = false 
) const
virtual

Implements SimulationEntity.

Reimplemented in ModalNode, DynamicStructNode, StructNode, DynamicStructDispNode, and StructDispNode.

Definition at line 68 of file node.cc.

69 {
70  return out;
71 }
void Node::DescribeEq ( std::vector< std::string > &  desc,
bool  bInitial = false,
int  i = -1 
) const
virtual

Implements SimulationEntity.

Reimplemented in ModalNode, DynamicStructNode, StructNode, DynamicStructDispNode, and StructDispNode.

Definition at line 74 of file node.cc.

References ASSERT.

75 {
76  ASSERT(i <= 0);
77  desc.resize(0);
78 }
#define ASSERT(expression)
Definition: colamd.c:977
virtual const doublereal& Node::dGetDofValuePrev ( int  iDof,
int  iOrder = 0 
) const
pure virtual
virtual doublereal Node::dGetPrivData ( unsigned int  i) const
inlinevirtual

Reimplemented from SimulationEntity.

Reimplemented in StructNode, ScalarDifferentialNode, and StructDispNode.

Definition at line 201 of file node.h.

References dGetDofValue().

201  {
202  return dGetDofValue(i);
203  };
virtual const doublereal & dGetDofValue(int iDof, int iOrder=0) const =0

Here is the call graph for this function:

const Node* Node::GetNode ( void  ) const
inline

Definition at line 111 of file node.h.

Referenced by DataManager::DofOwnerInit().

111 { return this; };
integer Node::iGetFirstRowIndex ( void  ) const
virtual

Reimplemented in ModalNode, DynamicStructNode, Node2Scalar, and DynamicStructDispNode.

Definition at line 82 of file node.cc.

References DofOwnerOwner::iGetFirstIndex().

Referenced by ThermalCapacitance::AssJac(), ThermalSource::AssJac(), ThermalResistance::AssJac(), LinearAccelerationJoint::AssJac(), GenelClamp::AssJac(), MinorLoss::AssJac(), Pipe::AssJac(), Control_valve::AssJac(), GenelStateSpaceSISO::AssJac(), Actuator::AssJac(), Accumulator::AssJac(), BulkSpringSupport::AssJac(), Motor::AssJac(), RotorTrimBase::AssJac(), GenelDistance::AssJac(), ThreeWayMinorLoss::AssJac(), AngularAccelerationJoint::AssJac(), Dynamic_pipe::AssJac(), GenelStateSpaceMIMO::AssJac(), Tank::AssJac(), GenelSpring::AssJac(), Orifice::AssJac(), GenelSpringSupport::AssJac(), DynamicPipe::AssJac(), Dynamic_control_valve::AssJac(), GenelCrossSpringSupport::AssJac(), GenelCrossSpringDamperSupport::AssJac(), Pressure_flow_control_valve::AssJac(), GenelSpringDamperSupport::AssJac(), GenelMass::AssJac(), Pressure_valve::AssJac(), Flow_valve::AssJac(), ThermalCapacitance::AssRes(), ThermalSource::AssRes(), ThermalResistance::AssRes(), LinearAccelerationJoint::AssRes(), MinorLoss::AssRes(), GenelClamp::AssRes(), Pipe::AssRes(), Control_valve::AssRes(), GenelStateSpaceSISO::AssRes(), Actuator::AssRes(), Accumulator::AssRes(), Motor::AssRes(), BulkSpringSupport::AssRes(), GenelDistance::AssRes(), ThreeWayMinorLoss::AssRes(), AngularAccelerationJoint::AssRes(), AbstractForce::AssRes(), Dynamic_pipe::AssRes(), GenelStateSpaceMIMO::AssRes(), Tank::AssRes(), Control_valve2::AssRes(), GenelSpring::AssRes(), Orifice::AssRes(), AbstractInternalForce::AssRes(), GenelSpringSupport::AssRes(), DynamicPipe::AssRes(), Dynamic_control_valve::AssRes(), GenelCrossSpringSupport::AssRes(), GenelCrossSpringDamperSupport::AssRes(), Pressure_flow_control_valve::AssRes(), GenelSpringDamperSupport::AssRes(), GenelMass::AssRes(), Pressure_valve::AssRes(), Flow_valve::AssRes(), Node2Scalar::iGetFirstRowIndex(), GenelClamp::SetValue(), and GenelDistance::SetValue().

83 {
84  return iGetFirstIndex();
85 }
virtual integer iGetFirstIndex(void) const
Definition: dofown.h:127

Here is the call graph for this function:

virtual unsigned int Node::iGetNumPrivData ( void  ) const
inlinevirtual

Reimplemented from SimulationEntity.

Reimplemented in StructNode, ParameterNode, ScalarDifferentialNode, and StructDispNode.

Definition at line 184 of file node.h.

References SimulationEntity::iGetNumDof().

184  {
185  return iGetNumDof();
186  };
virtual unsigned int iGetNumDof(void) const =0

Here is the call graph for this function:

virtual unsigned int Node::iGetPrivDataIdx ( const char *  s) const
inlinevirtual

Reimplemented from SimulationEntity.

Reimplemented in StructNode, ScalarAlgebraicNode, ScalarDifferentialNode, and StructDispNode.

Definition at line 193 of file node.h.

193  {
194  return 0;
195  };
virtual std::ostream& Node::Restart ( std::ostream &  out) const
pure virtual
virtual void Node::SetDofValue ( const doublereal dValue,
unsigned int  iDof,
unsigned int  iOrder = 0 
)
pure virtual

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