简体   繁体   English

PostgreSQL和Postgis在两个端口之间的距离计算

[英]distance calculation between two ports with PostgreSQL and Postgis

I'm using PostgreSQL with PostGis and have shapes of all countries loaded. 我在PostGis中使用PostgreSQL,并且加载了所有国家/地区的图形。

How can I calculate the shortes sea route between two ports (without intersecting a country shape) 我如何计算两个港口之间的短途海运路线(不与国家形状相交)

is there a 'standard solution'? 有没有“标准解决方案”?

you could use graph theory so long as you have a set of sea-lane type way-points defined. 只要定义了一组航道类型的航路点,就可以使用图论。 these would be points along the ship travel lanes with maybe nautical miles between each one indicated. 这些将是沿着船舶行进路线的各个点,每条指示点之间可能有海里。 then use a min path algorithm to find the best travel lane. 然后使用最小路径算法找到最佳行驶车道。

of course inreal life this problem has many more variables than just distance i would think. 当然,在现实生活中,这个问题比我想象的距离要多得多。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM