213#include "SimObject.h"
214#include "sfh/timers/StopWatch.h"
215#include <IBasicBottom.h>
216#include <ICurrentVel.h>
217#include "cable/subroutines/CInternalCableWithBottomContact.h"
219#ifdef FH_VISUALIZATION
220# ifdef USE_BILLBOARD_LABELS
221# include "CMovableText.h"
231 CCableBranched(std::string sSimObjectName): SimObject(sSimObjectName) {}
232 virtual void aFunction(std::string sSimObjectName, ISimObjectCreator* pCreator);
237 virtual void OdeFcn(
const double dT,
const double*
const adX,
double*
const adXDot,
const bool bIsMajorTimeStep);
238 void FinalSetup(
const double dT,
const double *
const adX, ISimObjectCreator*
const pCreator);
239 void InitialConditionSetup(
const double dT,
const double *
const adCurrentIC,
double*
const adUpdatedIC, ISimObjectCreator*
const pCreator);
240#ifdef FH_VISUALIZATION
242 void RenderInit(Ogre::Root*
const pOgreRoot, ISimObjectCreator*
const pCreator);
245 void RenderUpdate(
const double dT,
const double*
const adX);
249 virtual void CreateStates(ISimObjectCreator* pCreator);
250 void CalcOutput(
const double dT,
const double*
const adX);
251 void OutputExternalConnForces(
double dT,
const double* adX);
252 void GetPosAndVelPointer(
255 const double *
const adX,
256 const double**
const padPos,
257 const double**
const padVel);
259 const double * GetPosPointer(
262 const double *
const adX);
267 virtual void CreateDataStructures();
268 virtual void CreateInputports(ISimObjectCreator* pCreator);
269 virtual void CreateOutputports(ISimObjectCreator* pCreator);
273 void CheckNodeNumber(
int iNodeNumber, std::string sNodeDescription, ISimObjectCreator* pCreator);
279 const double* ExternalForce(
const double dT,
const double*
const adX,
int i);
280 const double* ExternalTension(
const double dT,
const double*
const adX,
int i);
281 const double* SectionLength(
const double dT,
const double*
const adX,
int i);
324 double* m_adExternalTensions;
327 const double* m_padVelWater;
331#ifdef FH_VISUALIZATION
332#ifdef USE_BILLBOARD_LABELS
333 Ogre::SceneNode** m_aRenderNode;
334 Ogre::CMovableText** m_aBBTxt;
Definition: CCableBranched.h:227
int m_iNumExternalConn
The number of external connections.
Definition: CCableBranched.h:289
int * m_aiNodeConnections
The nodes connected to each cable section.
Definition: CCableBranched.h:290
double * m_dDampingRatio
The damping ratio to specify the internal damping.
Definition: CCableBranched.h:310
CInternalCable ** m_apCableSections
An array holding the cable sections.
Definition: CCableBranched.h:325
double m_dMaxLengthChangeSpeed
The maximum speed of the cable length change.
Definition: CCableBranched.h:309
double * m_adLengths
The lengths of the cable elements.
Definition: CCableBranched.h:321
int m_iNumCableSections
The number of cable sections in the branched cable, where each section may be comprised of one or mor...
Definition: CCableBranched.h:287
double m_dStepSafetyFactor
The safety factor when calculating the Young modulus of the element.
Definition: CCableBranched.h:299
double * m_dMaxTension
The maximum tension in the cable.
Definition: CCableBranched.h:314
ICommonComputation * m_pCommonCalc
Calculations necessary for more than one output port.
Definition: CCableBranched.h:278
double * m_dDensity
The density of the cable material.
Definition: CCableBranched.h:311
double m_dMaxAcceleration
The value to truncate the acceleration of each node to.
Definition: CCableBranched.h:303
double m_dNumericalDamping
The numerical damping of the cable.
Definition: CCableBranched.h:301
double * m_adNodeInertia
The inertia of the calculation nodes belonging to this simObject.
Definition: CCableBranched.h:315
int * m_aIStateVel
An array of indices to the node velocity states.
Definition: CCableBranched.h:283
int m_iNumNodesGlobal
The number of nodes of the branched cable used for conecting the internal cable sections.
Definition: CCableBranched.h:288
double * m_adNodeForce
The force on the calculation nodes belonging to this simObject.
Definition: CCableBranched.h:318
double m_dFluidRho
The density of the surrounding fluid.
Definition: CCableBranched.h:302
ISignalPort ** m_apInPos
The position input ports.
Definition: CCableBranched.h:276
double * m_adRelaxedLength_d
The desired relaxed length of the cable.
Definition: CCableBranched.h:308
ISignalPort ** m_apInLength
The cable sections length port.
Definition: CCableBranched.h:277
double m_dDrawScale
The scale for which to draw the cable diameter.
Definition: CCableBranched.h:323
double * m_dStiffness
The linear stiffness of the cable.
Definition: CCableBranched.h:306
virtual void AddBottomForces(double dT, const double *const adX)
Adds the bottom forces to the main nodes.
double * m_dDiameter
The diameter of the cable.
Definition: CCableBranched.h:313
double * m_dMeanTension
The mean tension of the cable.
Definition: CCableBranched.h:305
int m_iNumNodesCalc
The number of nodes of the cable between the cable elements.
Definition: CCableBranched.h:286
CCableBranched(std::string sSimObjectName, ISimObjectCreator *pCreator)
The constructor sets the pointer to the output object and the parser object.
int m_iCableFaces
The number of faces of the cable visuaization.
Definition: CCableBranched.h:291
int m_iNumElements
The number of elements to divide the cable into.
Definition: CCableBranched.h:285
double * m_adRelaxedLength
The relaxed length of the cable.
Definition: CCableBranched.h:307
~CCableBranched()
The destructor deletes dynamically allocated memory.
double * m_dE
The stiffness of the cable material.
Definition: CCableBranched.h:312
std::string m_sMaterialName
The material name of the cable;.
Definition: CCableBranched.h:322
int * m_aIStatePos
An array of indices to the node position states.
Definition: CCableBranched.h:282
ISignalPort ** m_apInVel
The velocity input port s.
Definition: CCableBranched.h:275
void CheckNodeNumber(int iNodeNumber, std::string sNodeDescription, ISimObjectCreator *pCreator)
Checks to see if a specified nodenumber is ok.
double m_dEAdaptationPeriod
The time constant of the adaptation of the mean tension.
Definition: CCableBranched.h:300
double m_dMaxStep
The maximum steplength of the simulation.
Definition: CCableBranched.h:304
int * m_aIStateCable
An array of indices to the cable sections states.
Definition: CCableBranched.h:284
Definition: CInternalCable.h:195
Interface for calculating the bottom force on various objects.
Definition: IBasicBottom.h:23
Definition: ICurrentVel.h:12