|
LRAUV
revA
|
Though far simpler than ActuatorModel, the intent is the same, to encapsulate some of the complexity of the thruster modeling and remove it from the main simulator body. More...
#include <ThrusterModel.h>
Public Member Functions | |
| ThrusterModel () | |
| ~ThrusterModel () | |
| void | initialize (float designSpeed, float designPropEff, float designOmega, float designThrust, float designTorque) |
| float | currentPropOmega (void) |
| void | setPrevious (const float previous) |
| void | project (float propOmega, float u, float dt, float &thrust, float &torque) |
| Unlike the actuator model, the thruster model is very simple, with no time delay. More... | |
| void | advance (float propOmega, float u, float dt) |
| float | thrusterTorque (float omegaP, float u) |
| float | thrusterForce (float omegaP, float u) |
Private Attributes | |
| float | prevThrust_ |
| float | prevTorque_ |
| float | currentPropOmega_ |
| float | kWash_ |
| float | kThrust_ |
| float | kTorque_ |
Though far simpler than ActuatorModel, the intent is the same, to encapsulate some of the complexity of the thruster modeling and remove it from the main simulator body.
Unlike the ActuatorModel there is no delay, but it has the same "project" and "advance" functions. If given a dt of 0.0, the project() function will return the previous iteration's values, since the thruster can't change instantaneously.
| ThrusterModel::ThrusterModel | ( | ) |
|
inline |
| void ThrusterModel::advance | ( | float | propOmega, |
| float | u, | ||
| float | dt | ||
| ) |
References currentPropOmega_, prevThrust_, prevTorque_, thrusterForce(), and thrusterTorque().
Referenced by Simulator::motion().
|
inline |
References currentPropOmega_.
Referenced by Simulator::publishState(), and Simulator::run().
| void ThrusterModel::initialize | ( | float | designSpeed, |
| float | designPropEff, | ||
| float | designOmega, | ||
| float | designThrust, | ||
| float | designTorque | ||
| ) |
References kThrust_, kTorque_, and kWash_.
Referenced by Simulator::loadParams().
| void ThrusterModel::project | ( | float | propOmega, |
| float | u, | ||
| float | dt, | ||
| float & | thrust, | ||
| float & | torque | ||
| ) |
Unlike the actuator model, the thruster model is very simple, with no time delay.
Rather, if asked for behavior at dt=0, will give previous results. If asked for results at dt>0 will give new calculations
References prevThrust_, prevTorque_, thrusterForce(), and thrusterTorque().
Referenced by Simulator::calcForce().
|
inline |
References currentPropOmega_.
Referenced by Simulator::setPropOmega().
| float ThrusterModel::thrusterForce | ( | float | omegaP, |
| float | u | ||
| ) |
| float ThrusterModel::thrusterTorque | ( | float | omegaP, |
| float | u | ||
| ) |
|
private |
Referenced by advance(), currentPropOmega(), and setPrevious().
|
private |
Referenced by initialize(), and thrusterForce().
|
private |
Referenced by initialize(), and thrusterTorque().
|
private |
Referenced by initialize(), thrusterForce(), and thrusterTorque().