diff --git a/mission_analysis/src/standard_mission/fuel_handling/fuel_handling.cpp b/mission_analysis/src/standard_mission/fuel_handling/fuel_handling.cpp index 4aa835a65955d325d01496c64b5b654716ce7068..a8771954f984d64bbeae756ca4b9f8bba78eb6fb 100644 --- a/mission_analysis/src/standard_mission/fuel_handling/fuel_handling.cpp +++ b/mission_analysis/src/standard_mission/fuel_handling/fuel_handling.cpp @@ -209,23 +209,23 @@ void standard_mission::set_alternate_fuel(double* aircraft_mass) { EndnodeReadOnly<int>("energy_carrier_ID").read(rtIO->acxml.at("requirements_and_specifications/design_specification/propulsion/energy_provider/cruise")).value(); /* Alternate fuel: Calculation of the flight altitude from alternate */ double alternate_FL = this->mission_file->alternate_distance * 0.8 / (1. / tan(convertUnit(DEGREE, RADIAN, 5.)) + 1. / tan(convertUnit(DEGREE, RADIAN, 3.))); - if (alternate_FL > convertUnit(FOOT, METER, 30000.)) { - alternate_FL = convertUnit(FOOT, METER, 30000.); + if (alternate_FL > convertUnit(FOOT, METER, 10000.)) { + alternate_FL = convertUnit(FOOT, METER, 10000.); } - double climb_mach(convertUnit(CALIBRATEDAIRSPEED, MACH, convertUnit(FOOT, METER, 10000.), this->atm, this->climb_speed_below_FL100)); + double climb_mach(convertUnit(CALIBRATEDAIRSPEED, MACH, alternate_FL, this->atm, this->climb_speed_below_FL100)); /* Alternate climbing: Estimation with the values at 10.000 ft */ - this->engine.calculate_N1_with_penalties(energy_carrier_id, convertUnit(FOOT, METER, 10000.), climb_mach, this->atm, 1., "climb", 0., 0.); + this->engine.calculate_N1_with_penalties(energy_carrier_id, alternate_FL, climb_mach, this->atm, 1., "climb", 0., 0.); /* Calculate aerodynamics */ - double L_over_D(this->aero.getCruiseLoverD(climb_mach, convertUnit(FOOT, METER, 10000.), 0., *aircraft_mass, "clean", this->atm)); + double L_over_D(this->aero.getCruiseLoverD(climb_mach, alternate_FL, 0., *aircraft_mass, "clean", this->atm)); if (sophistication_level != UNSOPHISTICATED) { double current_cg(get_current_cg()); L_over_D = this->interpolateViaCoG(current_cg, L_over_D, - getAlternativeAero(current_cg)->getCruiseLoverD(climb_mach, convertUnit(FOOT, METER, 10000.), 0., *aircraft_mass, "clean", this->atm)); + getAlternativeAero(current_cg)->getCruiseLoverD(climb_mach, alternate_FL, 0., *aircraft_mass, "clean", this->atm)); } /* Calculate the specific fuel consumption */ double SFC = this->engine.get_aircraft_fuelflow(energy_carrier_id) / this->engine.get_thrust_aircraft(energy_carrier_id); /* Alternate climbing: Estimate the climbing duration with 5 deg climb angle */ - double climb_time_altn = alternate_FL / (tan(convertUnit(DEGREE, RADIAN, 5.)) * convertUnit(MACH, CALIBRATEDAIRSPEED, convertUnit(FOOT, METER, 10000.), this->atm, climb_mach)); + double climb_time_altn = alternate_FL / (tan(convertUnit(DEGREE, RADIAN, 5.)) * convertUnit(MACH, CALIBRATEDAIRSPEED, alternate_FL, this->atm, climb_mach)); /* Calculate the alternate climbing fuel mass */ double m_climb_altn = *aircraft_mass * expm1(climb_time_altn * SFC * G_FORCE / L_over_D); /* Calculate the alternate fuel mass */