/******************************************************************************/
// Run an iteration of the EOM (equations of motion)
-# include <fenv.h>
void FGJSBsim::update( double dt )
{
if(crashed) {
double Lmb, Exp, Tmb, deltaH, factor;
double numRows = StdAtmosTemperatureTable->GetNumRows();
- if (altitude > 328084) // Karman line
- altitude = 328084;
+//if (altitude > 328084) // Karman line
+// altitude = 328084;
// Iterate through the altitudes to find the current Base Altitude
// in the table. That is, if the current altitude (the argument passed in)
factor = Tmb/(Tmb + Lmb*deltaH);
pressure = PressureBreakpointVector[b]*pow(factor, Exp);
} else {
- pressure = PressureBreakpointVector[b]*exp(Mair*deltaH/(Rstar*Tmb));
+ pressure = PressureBreakpointVector[b]*exp(-Mair*deltaH/(Rstar*Tmb));
}
return pressure;