Marine systems simulation
System::CCableRM Class Reference

#include <CCable.h>

+ Inheritance diagram for System::CCableRM:
+ Collaboration diagram for System::CCableRM:

Classes

struct  element
 

Public Member Functions

 CCableRM (const string &simObjectName, ISimObjectCreator *const creator)
 Reads parameters, registers states, input/output ports and shared resources. More...
 
void OdeFcn (const double T, const double *const X, double *const XDot, const bool bIsMajorTimeStep)
 Computes object derivatives as a function of time, states and input ports. More...
 
void InitialConditionSetup (const double T, const double *const currentIC, double *const updatedIC, ISimObjectCreator *const creator)
 
void FinalSetup (const double T, const double *const X, ISimObjectCreator *const creator)
 
const double * forceA (const double T, const double *const X)
 Output port. Returns current force in endpoint A of cable. More...
 
const double * forceB (const double T, const double *const X)
 Output port. Returns current force in endpoint B of cable. More...
 
void calculations (const double T, const double *const X)
 Performs a series of computations within the cable object. More...
 
const double * OutPos (const double T, const double *const X, const int i)
 

Protected Types

typedef Eigen::Matrix< double, 3, 3 > mat3
 
typedef Eigen::Matrix< double, 3, 1 > vec3
 

Protected Member Functions

void DistributeCatenary (Eigen::Matrix< double, 3, 1 > P1, Eigen::Matrix< double, 3, 1 > P2, double L, double *states, int i1, int i2, ISimObjectCreator *creator)
 

Protected Attributes

CPrintDuringExec * m_print
 
CEnvironmentm_environment
 
int m_numElements
 
double m_totalLength
 
double m_radius
 
double m_weight
 
double m_alphaN
 
double m_betaN
 
double m_epsilonN
 
double m_alphaM
 
double m_betaM
 
double m_epsilonM
 
double m_alphaT
 
double m_betaT
 
double m_epsilonT
 
double m_bending_epsilon [3]
 
double m_length
 
double m_mass
 
double m_Ixy
 
double m_Iz
 
bool m_kelp
 
double m_wKelp
 
elementm_el
 
ISignalPort * m_posA
 
ISignalPort * m_posB
 
ISignalPort * m_velA
 
ISignalPort * m_velB
 
ISignalPort * m_retractedLengthA
 
ISignalPort * m_retractedLengthB
 
ISignalPort * m_retractedSpeedA
 
ISignalPort * m_retractedSpeedB
 
int m_retractedNodesA
 
int m_retractedNodesB
 
int m_numFreeNodes
 
vec3 m_ka
 
vec3 m_kb
 
ICommonComputation * m_calcDynamics
 
Eigen::Matrix< double, Eigen::Dynamic, 1 > m_lambda
 
Eigen::Matrix< double, Eigen::Dynamic, 1 > m_F_MDotV
 
double m_forceA [3]
 
double m_forceB [3]
 
int m_numAddedForce
 
std::unique_ptr< int[]> m_addElement
 
std::unique_ptr< double[]> m_addForce
 
int m_numOutElePos
 
std::unique_ptr< int[]> m_OutEleIndex
 

Detailed Description

Author
Jørgen Haavind Jensen

Simobject name for use in input file: Cable.

Retains the same structural properties as the simObject CFlexibleBottomRing, but has a simpler interface where Young's and shear moduluses are provided rather than using the \(\alpha\), \(\beta\) and \(\epsilon\) values used in CFlexibleBottomRing.

Parameters
ParameterDefaultComment
cableLength-total length of the cable [m]
numElements-number of rigid elements in the cable [#]
diameter-diameter of the cable. [m]
cableWeight-weight of the cable [kg/m]
E-modulus-Young's modulus for cable material[GPa]
G-modulus\(\frac{E-modulus}{2.6}\)shear modulus for cable material[GPa]
damping1structural damping in the cable [-]
updateFreq-parameter which preserves simulation stability [-]
stabilityFactor-

parameter which preserves simulation stability [-]

Input ports
TagSizeComment
PositionA3position of end-connection point A
PositionB3position of end-connection point B
VelocityA3velocity of end-connection point A
VelocityB3velocity of end-connection point B
RetractedLengthA1length of cable retracted on side A
RetractedLengthB1length of cable retracted on side B
RetractedSpeedA1retraction rate of cable retracted on side A
RetractedSpeedB1retraction rate of cable retracted on side B
Output ports
TagSizeComment
ForceA3Reaction force on side A
ForceB3Reaction force on side B
States
TagSizeComment
pos<i>3Position (x,y,z) of element with index <i>
vel<i>3Velocity of element with index <i>
theta<i>4Quaternion of element with index <i>
omega<i>3

Angular derivatives of element (?) <i>

Note
The hydrodynamic load model does not currently support the effect of added mass.
 \par Revision history:
                    Q3 2011 JHJ: Initial version.

Constructor & Destructor Documentation

◆ CCableRM()

System::CCableRM::CCableRM ( const string &  simObjectName,
ISimObjectCreator *const  creator 
)

The constructor performs all initial setup for a cable simobject. Reading in parameters, setting up communication interface i.e. output ports, input ports, and states, plus additional 'one time only' resource setup.

Parameters
[in]simObjectName-> The name of the simobject
[in]creator-> Retrieve parameters. Register states, ports and shared resources reads parameters, registers states, output and intput ports.

Member Function Documentation

◆ calculations()

void System::CCableRM::calculations ( const double  T,
const double *const  X 
)

Computations that are important for the cable object dynamics, but only should be called once during each time step when simulating. Results are stored in member variables in the object.

Parameters
[in]T-> Current simulation time
[in]X-> Current simulation state

◆ forceA()

const double * System::CCableRM::forceA ( const double  T,
const double *const  X 
)

See PortDefs.h

Parameters
[in]T-> Current simulation time
[in]X-> Current simulation state
Returns
-> Address of current force in endpoint A of cable

◆ forceB()

const double * System::CCableRM::forceB ( const double  T,
const double *const  X 
)

See PortDefs.h

Parameters
[in]T-> Current simulation time
[in]X-> Current simulation state
Returns
-> Address of current force in endpoint B of cable

◆ OdeFcn()

void System::CCableRM::OdeFcn ( const double  T,
const double *const  X,
double *const  XDot,
const bool  bIsMajorTimeStep 
)

Returns state derivatives.

Parameters
[in]T-> Current simulation time
[in]X-> Current simulation state
[out]XDot-> State derivatives
[in]bIsMajorTimeStep-> Is this a major time step?

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