FhSim  3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
ToTrawlDoor.h
1#pragma once
2
122#include "TrawlDoorBase.h"
123
124#include <fhsim_environment/EnvironmentProvider.h>
125#include <fhsim_environment/SeafloorForcesInterface.h>
126
128{
129public:
131 ToTrawlDoor(std::string simObjectName, ISimObjectCreator* creator);
132
134 const double* OutRoll(const double dT, const double* const adX);
135
136 // Output port returning the pitch angle of the trawl door.
137 const double* OutPitch(const double dT, const double* const adX);
138
139 // Output port returning the angle of attack of the trawl door.
140 const double* OutAngleOfAttack(const double dT, const double* const adX);
141
143 const double* OutHydroLoad(const double dT, const double* const adX);
144
146 const double* OutSeabedLoad(const double dT, const double* const adX);
147
148#ifdef FH_VISUALIZATION
150 virtual void RenderInit(Ogre::Root* const ogreRoot, ISimObjectCreator* const creator);
151
153 virtual void RenderUpdate(const double dT, const double* const adX);
154#endif
155
156protected:
158 void FinalSetup(const double dT, const double* const adX, ISimObjectCreator* const creator);
159
161 void AddBottomForces(const hydro_body::FlowFrame& frame, hydro_body::Wrench& wrench) const override;
162
164 environment::seabed::ContactLoad<double> SeabedLoadOf(const hydro_body::FlowFrame& frame) const;
165
168 bool HasJacobians() const override { return false; }
169
175 ISimObjectCreator* m_creator = nullptr;
176 environment::SeafloorForcesInterface* m_seafloorForces = nullptr;
177 double m_shoeWidth;
178 double m_outHydroLoad[6] = {0, 0, 0, 0, 0, 0};
179 double m_outSeabedLoad[6] = {0, 0, 0, 0, 0, 0};
180 double m_roll;
181 double m_pitch;
182};
Definition ToTrawlDoor.h:128
environment::SeafloorForcesInterface * m_seafloorForces
The shared "SeafloorForces", from FinalSetup.
Definition ToTrawlDoor.h:176
void AddBottomForces(const hydro_body::FlowFrame &frame, hydro_body::Wrench &wrench) const override
Adds the seabed load of the evaluator to the trawl door, in the body frame.
const double * OutSeabedLoad(const double dT, const double *const adX)
Output port returning the seabed load on the door: NED force then NED moment about the door origin.
double m_outHydroLoad[6]
Output port HydroLoad.
Definition ToTrawlDoor.h:178
bool HasJacobians() const override
Definition ToTrawlDoor.h:168
const double * OutRoll(const double dT, const double *const adX)
Output port returning the roll angle of the trawl door.
double m_shoeWidth
Width of the shoe [m], from ShoeWidth.
Definition ToTrawlDoor.h:177
double m_outSeabedLoad[6]
Output port SeabedLoad.
Definition ToTrawlDoor.h:179
const double * OutHydroLoad(const double dT, const double *const adX)
Output port returning the hydrodynamic load on the door: NED force then NED moment about the door ori...
ToTrawlDoor(std::string simObjectName, ISimObjectCreator *creator)
The constructor sets the pointer to the output object and the parser object.
environment::seabed::ContactLoad< double > SeabedLoadOf(const hydro_body::FlowFrame &frame) const
The seabed load of the door in the pose and with the velocity of frame: NED, moment about the door or...
void FinalSetup(const double dT, const double *const adX, ISimObjectCreator *const creator)
Resolves the SeafloorForces resource after the base class has resolved the environment.
ISimObjectCreator * m_creator
Definition ToTrawlDoor.h:175
Definition TrawlDoorBase.h:191
Definition HydroBody.h:42
The sum of the loads on a body: the force [0..2] and the moment about the origin [3....
Definition HydroBody.h:57