瀏覽代碼

do not minimize the TTG

Sven Czarnian 2 年之前
父節點
當前提交
357f6e7b11
共有 2 個文件被更改,包括 5 次插入1 次删除
  1. 4 1
      aman/sys/aco/Node.py
  2. 1 0
      aman/types/Inbound.py

+ 4 - 1
aman/sys/aco/Node.py

@@ -209,8 +209,11 @@ class Node:
                 ttg = timedelta(seconds = timeUntilIAF.total_seconds() * ttgRatio)
                 if (ttg.total_seconds() > ttgMax):
                     ttg = timedelta(seconds = ttgMax)
+                if None == self.Inbound.MaximumTimeToGain or ttg > self.Inbound.MaximumTimeToGain:
+                    self.Inbound.MaximumTimeToGain = ttg
+
                 ita = self.Inbound.ReportTime + flightTime
-                earliest = ita - ttg
+                earliest = ita - self.Inbound.MaximumTimeToGain
 
                 self.ArrivalCandidates[identifier.Runway.Name] = ArrivalData(star = star, ita = earliest, route = arrivalRoute,
                                                                              trackmiles = trackmiles)

+ 1 - 0
aman/types/Inbound.py

@@ -17,6 +17,7 @@ class Inbound:
         self.EnrouteArrivalTime = None
         self.InitialArrivalTime = None
         self.RequestedRunway = None
+        self.MaximumTimeToGain = None
         self.PlannedArrivalTime = None
         self.PlannedRunway = None
         self.PlannedStar = None