X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FFDM%2FJSBSim%2Fmodels%2FFGPropagate.h;h=00de83c7f069e6747bad79c2210a7d30cfaba01f;hb=53e8fbfcbb3ddac0dc261043fea7bd24dfa6e62d;hp=be8ebd224ba189a8bd2b2b84cde6b269c96296b3;hpb=4b8fde057be1124c516eb89442eae4bfe4a4db5c;p=flightgear.git diff --git a/src/FDM/JSBSim/models/FGPropagate.h b/src/FDM/JSBSim/models/FGPropagate.h index be8ebd224..00de83c7f 100644 --- a/src/FDM/JSBSim/models/FGPropagate.h +++ b/src/FDM/JSBSim/models/FGPropagate.h @@ -49,7 +49,7 @@ INCLUDES DEFINITIONS %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%*/ -#define ID_PROPAGATE "$Id: FGPropagate.h,v 1.48 2010/09/18 22:48:12 jberndt Exp $" +#define ID_PROPAGATE "$Id: FGPropagate.h,v 1.53 2010/11/28 13:02:43 bcoconni Exp $" /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% FORWARD DECLARATIONS @@ -102,7 +102,7 @@ CLASS DOCUMENTATION @endcode @author Jon S. Berndt, Mathias Froehlich - @version $Id: FGPropagate.h,v 1.48 2010/09/18 22:48:12 jberndt Exp $ + @version $Id: FGPropagate.h,v 1.53 2010/11/28 13:02:43 bcoconni Exp $ */ /*%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -135,6 +135,11 @@ public: units rad/sec */ FGColumnVector3 vPQRi; + /** The angular velocity vector for the vehicle body frame relative to the + ECI frame, expressed in the ECI frame. + units rad/sec */ + FGColumnVector3 vPQRi_i; + /** The current orientation of the vehicle, that is, the orientation of the body frame relative to the local, NED frame. */ FGQuaternion qAttitudeLocal; @@ -147,7 +152,7 @@ public: FGColumnVector3 vInertialPosition; - deque dqPQRdot; + deque dqPQRidot; deque dqUVWidot; deque dqInertialVelocity; deque dqQtrndot; @@ -566,16 +571,6 @@ public: VState.vInertialPosition = GetTec2i() * VState.vLocation; UpdateLocationMatrices(); } - void SetLocation(const FGLocation& l) { - VState.vLocation = l; - VState.vInertialPosition = GetTec2i() * VState.vLocation; - UpdateLocationMatrices(); - } - void SetLocation(const FGColumnVector3& l) { - VState.vLocation = l; - VState.vInertialPosition = GetTec2i() * VState.vLocation; - UpdateLocationMatrices(); - } void SetAltitudeASL(double altASL); void SetAltitudeASLmeters(double altASL) {SetAltitudeASL(altASL/fttom);} void SetSeaLevelRadius(double tt) { SeaLevelRadius = tt; } @@ -588,6 +583,16 @@ public: VehicleRadius = GetRadius(); UpdateLocationMatrices(); } + void SetLocation(const FGLocation& l) { + VState.vLocation = l; + VState.vInertialPosition = GetTec2i() * VState.vLocation; + UpdateLocationMatrices(); + } + void SetLocation(const FGColumnVector3& l) { + VState.vLocation = l; + VState.vInertialPosition = GetTec2i() * VState.vLocation; + UpdateLocationMatrices(); + } void RecomputeLocalTerrainRadius(void); @@ -604,6 +609,8 @@ public: double value; }; + void DumpState(void); + private: // state vector @@ -612,6 +619,7 @@ private: FGColumnVector3 vVel; FGColumnVector3 vPQRdot; + FGColumnVector3 vPQRidot; FGColumnVector3 vUVWdot, vUVWidot; FGColumnVector3 vInertialVelocity; FGColumnVector3 vLocation; @@ -633,7 +641,7 @@ private: FGMatrix33 Tl2i; double LocalTerrainRadius, SeaLevelRadius, VehicleRadius; - FGColumnVector3 LocalTerrainVelocity; + FGColumnVector3 LocalTerrainVelocity, LocalTerrainAngularVelocity; eIntegrateType integrator_rotational_rate; eIntegrateType integrator_translational_rate; eIntegrateType integrator_rotational_position; @@ -658,6 +666,14 @@ private: double dt, eIntegrateType integration_type); + void EvaluateRateToResistTo(FGColumnVector3& vdot, + const FGColumnVector3& Val, + const FGColumnVector3& ValDot, + const FGColumnVector3& LocalTerrainVal, + deque & dqValDot, + const double dt, + const eIntegrateType integration_type); + void ResolveFrictionForces(double dt); void UpdateLocationMatrices(void);