public bool QueryDerivatives(IAgFlightBasicManeuverState pCurrentState, IAgFlightBasicManeuverDerivs presultCurrentDerivs, bool vbAllowThresholdDetection) { // the strategy extrapolates the starting flight condition ... // model the effects of coriolis without compensating for it ... presultCurrentDerivs.SetVertPlaneCompensateForCoriolisAccel(false); presultCurrentDerivs.SetHorizPlaneCompensateForCoriolisAccel(false); // totalECFAccel = pitchRateNormalAccel + speedDotLongAccel + coriolisAccel - centripetalAccel pCurrentState.QueryECFCoriolisAccel(m_coriolisAccel); pCurrentState.QueryECFCentripetalAccel(m_centripetalAccel); m_accelCommand.SetToZero(); // pitchRateNormalAccel = speedDotLongAccel = 0 m_accelCommand.Add(m_coriolisAccel); m_accelCommand.Subtract(m_centripetalAccel); presultCurrentDerivs.SetEcfAccelCommand(m_accelCommand); // compute ref axes PQRs pCurrentState.QueryECFToRefAxesAttRefFrame(m_ecfToRefAxesQuat, null); pCurrentState.QueryOmegaEarthInFrame(m_ecfToRefAxesQuat, m_earthOmegaInRefAxes); double dCommandFPADot = 0.0; m_PQR.ConstructFromComponents(0.0, dCommandFPADot, 0.0); m_PQR.Add(m_earthOmegaInRefAxes); presultCurrentDerivs.SetRefAxesOmegaCommand(m_PQR); // Tgo is used for calc progress and to refine stopping condition presultCurrentDerivs.NavTimeToGo = 1.0; presultCurrentDerivs.ProfileTimeToGo = 1.0; return(true); }
public void SetInitialState(AgEFlightPerformanceMode ePerfMode, AgEFlightPhaseOfFlight ePhaseOfFlight, IAgFlightBasicManeuverState pInitState, IAgFlightDoubleArray presultAuxInitState) { AgQuaternion pRefAxesQuat = new AgQuaternion(); AgCartVec3 pRefAxesAngVel = new AgCartVec3(); // generate the default ref axes coordinate frame ... pInitState.ComputeStandardECFToRefAxesFrame( true, AgEFlightAxesOrientation.eFwdRightDown, pRefAxesQuat, pRefAxesAngVel); // tell the system to use that ref axes frame (can only be done during SetInitialState)... pInitState.SetInitialECFToRefAxesFrame(AgEFlightAxesOrientation.eFwdRightDown, pRefAxesQuat, pRefAxesAngVel); }
public bool RefineIntegrateThreshold(AgEFlightIntegThresholdType eThresholdType, IAgFlightBasicManeuverState pLastGoodState, IAgFlightBasicManeuverState pCurrentState) { return(true); }
public bool RefineIntegrateThreshold(AgEFlightIntegThresholdType eThresholdType, IAgFlightBasicManeuverState pLastGoodState, IAgFlightBasicManeuverState pCurrentState) { // nothing to do for this example, all the action gets done in the Nav strategy return(true); }
public bool QueryDerivatives(IAgFlightBasicManeuverState pCurrentState, IAgFlightBasicManeuverDerivs presultCurrentDerivs, bool vbAllowThresholdDetection) { // nothing to do for this example, all the action gets done in the Nav strategy return(true); }
public void SetInitialState(AgEFlightPerformanceMode ePerfMode, AgEFlightPhaseOfFlight ePhaseOfFlight, IAgFlightBasicManeuverState pInitState, IAgFlightDoubleArray presultAuxInitState) { // nothing to do for this example }