do not double optimize the speed until IAF two times
This commit is contained in:
		| @@ -31,10 +31,8 @@ class Inbound: | |||||||
|         flightTime, flightTimeUntilIaf, trackmiles = self.secondsUntilTouchdown(weatherModel) |         flightTime, flightTimeUntilIaf, trackmiles = self.secondsUntilTouchdown(weatherModel) | ||||||
|  |  | ||||||
|         # calculate the maximum time to gain (assumption: 10% speed increase by acceleration and shortcuts) |         # calculate the maximum time to gain (assumption: 10% speed increase by acceleration and shortcuts) | ||||||
|         avgSpeed = self.Report.distanceToIAF / (float(flightTimeUntilIaf.seconds) / 3600.0) |  | ||||||
|         self.MaximumTimeToGain = flightTimeUntilIaf - timedelta(minutes = (self.Report.distanceToIAF / (avgSpeed * 1.1)) * 60) |  | ||||||
|         avgSpeed = trackmiles / (float(flightTime.seconds) / 3600.0) |         avgSpeed = trackmiles / (float(flightTime.seconds) / 3600.0) | ||||||
|         self.MaximumTimeToGain += flightTime - timedelta(minutes = (trackmiles / (avgSpeed * 1.1)) * 60) |         self.MaximumTimeToGain = flightTime - timedelta(minutes = (trackmiles / (avgSpeed * 1.1)) * 60) | ||||||
|  |  | ||||||
|         # calculate the different arrival times |         # calculate the different arrival times | ||||||
|         self.InitialArrivalTime = self.ReportTime + flightTime |         self.InitialArrivalTime = self.ReportTime + flightTime | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user