97#include <fhsim/simobject/ISimObjectCreator.h>
98#include <fhsim_environment/EnvironmentProvider.h>
100#ifdef FH_VISUALIZATION
101#include "sfh/ogre/CDynamicLines.h"
103#include "./Ship/Actuators/IPropellerCalculator.h"
104#include "./Ship/Actuators/OpenWaterPropeller.h"
105#include "./Ship/Actuators/TableLookup.h"
106#include "PropulsorWakeField.h"
114 double position[3] = {0,0,0};
115 double axis[3] = {1,0,0};
128 Propeller(
const std::string simObjectName, ISimObjectCreator*
const creator);
129 void FinalSetup(
const double T,
const double *
const X, ISimObjectCreator*
const creator );
130 void OdeFcn(
const double T,
const double*
const X,
double*
const XDot)
const;
134 #ifdef FH_VISUALIZATION
135 void RenderInit(Ogre::Root*
const ogreRoot, ISimObjectCreator*
const creator);
136 void RenderUpdate(
const double T,
const double*
const X);
142 const double*
ForceNED(
const double T,
const double*
const X);
144 const double*
TorqueNED(
const double T,
const double*
const X);
146 const double*
Us(
const double T,
const double*
const X);
148 const double*
Rs(
const double T,
const double*
const X);
152 double Ct(
double U,
double F);
156 double Coefficient(
double pitchRatio,
double J,
bool torque);
162 bool m_DummyPropeller;
165 ISignalPort *m_InForceDirectionNED =
nullptr;
167 ISignalPort *m_InMyRPS =
nullptr;
169 ISignalPort *m_InMyPD =
nullptr;
171 ISignalPort *m_InVelocityNED =
nullptr;
173 ISignalPort *m_InPositionNED =
nullptr;
175 ISignalPort *m_InMyPropellerForce =
nullptr;
177 ISignalPort *m_InMyPropellerTorque =
nullptr;
179 std::vector<double> PDlist;
180 double m_BladeTop[3] = {0,0,0};
181 double m_Force[3] = {0,0,0};
182 double m_MyThrust[3] = {0,0,0};
183 double m_MyTorque[3] = {0,0,0};
190 std::vector<std::unique_ptr<OpenWaterPropeller> > m_PropellerCalculator;
192 WarnOnce m_tableWarning;
193 environment::EnvironmentProvider *m_Environment =
nullptr;
194 std::shared_ptr<PropellerCurrentField> m_currentField = std::make_shared<PropellerCurrentField>(
PropellerJet);
196 int m_RotateAngle = -1;
198 #ifdef FH_VISUALIZATION
199 std::string m_Material;
200 Ogre::SceneNode* m_RenderNode;
201 CDynamicLines* m_lines;
Definition Propeller.h:126
const double * ForceNED(const double T, const double *const X)
void AcceptedStep(double T, const double *X) override
Copies the wake state of the accepted state into the jet field (G4).
const double * Us(const double T, const double *const X)
const double * BladeTopNED(const double T, const double *const X)
const double * Rs(const double T, const double *const X)
const double * TorqueNED(const double T, const double *const X)
Definition PropulsorWakeField.h:25
Status
Definition marenv.h:44
Simple waypoint object.
Definition CableAttach.h:58
marenv::Status PropellerJet(const PropellerWakeState &state, double T, const double position[3], double currentVelocity[3])
The jet behind the propeller (G4: reads only the copy of the state).
The state the propeller jet needs, copied after each accepted step (zero jet by default: Us = Rs = 0)...
Definition Propeller.h:113