【问题标题】:Calculating the shortest distance between n GPS points [closed]计算 n 个 GPS 点之间的最短距离
【发布时间】:2016-09-20 18:31:57
【问题描述】:

例如,我有 4 个点:A (latitute1, longitude1), B (latitute2, longitude2), C (latitute3, longitude3), D (latitute4, longitude4)。

如果我是一名司机,我从 A 点出发,我需要一种算法来计算从 A 开始访问所有 B、C、D 点的最有效方式。这样距离尽可能小。

算法应该告诉我最有效的顺序:A --> C --> B --> D(例如)。

重要的是行驶的总距离尽可能短。

非常感谢!!! :)

【问题讨论】:

    标签: math gps geolocation geometry geography


    【解决方案1】:

    也许研究一下 Dijkstras 算法?
    https://en.m.wikipedia.org/wiki/Dijkstra%27s_algorithm

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-02-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-01-19
      • 1970-01-01
      相关资源
      最近更新 更多