Update of /cvsroot/gcblue/gcb_wx/src/sim
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5463/src/sim
Modified Files:
tcAeroAirObject.cpp
Log Message:
Modified air model to use thrust factor vs. altitude and fuel efficiency vs. alt tables
Index: tcAeroAirObject.cpp
===================================================================
RCS file: /cvsroot/gcblue/gcb_wx/src/sim/tcAeroAirObject.cpp,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** tcAeroAirObject.cpp 26 May 2005 11:54:11 -0000 1.16
--- tcAeroAirObject.cpp 27 May 2005 00:28:21 -0000 1.17
***************
*** 242,257 ****
// calculate thrust decay factor based on altitude
! float decayFactor = mpDBObject->GetThrustFactor(mcKin.mfAlt_m);
!
if (throttleFraction <= 1.0f)
{
// apply engine thrust and fuel consumption decrease with altitude
! fThrust_N = mpDBObject->mfMaxThrust_N * throttleFraction * decayFactor;
! fuel_kg -= throttleFraction * mpDBObject->mfFuelRate_kgps * dt_s * damagePenalty;
}
else
{
! fThrust_N = mpDBObject->mfAfterburnThrust_N * decayFactor;
fuel_kg -= mpDBObject->mfAfterburnFuelRate_kgps * dt_s * damagePenalty;
}
--- 242,259 ----
// calculate thrust decay factor based on altitude
! float thrustFactor;
! float fuelEfficiencyFactor;
! mpDBObject->GetThrustAndEfficiencyFactors(mcKin.mfAlt_m, thrustFactor, fuelEfficiencyFactor);
if (throttleFraction <= 1.0f)
{
// apply engine thrust and fuel consumption decrease with altitude
! fThrust_N = mpDBObject->mfMaxThrust_N * throttleFraction * thrustFactor;
! fuel_kg -= throttleFraction * fuelEfficiencyFactor * mpDBObject->mfFuelRate_kgps *
! dt_s * damagePenalty;
}
else
{
! fThrust_N = mpDBObject->mfAfterburnThrust_N * thrustFactor;
fuel_kg -= mpDBObject->mfAfterburnFuelRate_kgps * dt_s * damagePenalty;
}
|