pathdist

简单地计算距离沿着纬度/经度的道路

1.7 k下载

更新2015年1月13日

查看许可协议

pathdist返回一个数组的累积距离沿着一条路径。
语法
pathDistance = pathdist(纬度、经度)
LengthUnit pathDistance = pathdist (…)
跟踪pathDistance = pathdist (…)
pathDistance = pathdist (…,'refpoint',[reflat reflon])

描述
pathDistance = pathdist(纬度、经度)返回的累积距离沿着路径(lat, | |离子)。距离是米在默认情况下,引用WGS84椭球。pathDistance数组大小相同的纬度和经度。

LengthUnit pathDistance = pathdist(…),指定任何有效长度单位。以下是几个LengthUnit选项。看到文档validateLengthUnit选项的完整列表。

计“m”,“米(s)”,“米(s)”(默认)
公里“公里”,'公里(s) ', '公里(s) '
海里“海里”,“naut mi”、“海里(s)”
脚“英尺”,“国际金融时报》”,“脚”,“国际脚”,“脚”,“国际脚”
英寸的“在”,“寸”,“英寸”
院子里‘码’,‘码’,“院子里(s)”
英里的“小姐”,“英里(s)”,“国际英里(s)”

pathDistance = pathdist输入字符串(…,追踪)使用跟踪指定一个大圆/测地线或恒向线弧。如果跟踪= ' gc(默认值),然后计算球面上大圆距离,测地线距离计算WGS84椭球。如果跟踪等于rh,那么恒向线距离计算WGS84椭球。

pathDistance = pathdist (…,'refpoint',[reflat reflon]) references the path distance to the point along the path nearest to [reflat reflon]. For this calculation, pathdist finds the point in lat and lon which is nearest to [reflat reflon] and assumes this point along lat,|lon| is the zero point. This is only an approximation, and may give erroneous results in cases of very sharply-curving, crossing, or otherwise spaghetti-like paths; where [reflat reflon] lies far from any point along the path, or where points along the path are spaced far apart.

引用作为

乍得格林(2023)。pathdist(//www.tianjin-qmedu.com/matlabcentral/fileexchange/47042-pathdist), MATLAB中央文件交换。检索

MATLAB版本兼容性
创建R2012b
兼容任何释放
平台的兼容性
窗户 macOS Linux

社区寻宝

找到宝藏在MATLAB中央,发现社区如何帮助你!

开始狩猎!

pathdistdemo / html /

版本 发表 发布说明
1.4

在今天早上的版本我不小心设置默认单位公里。现在默认单位是米。

1.3.0.0

现在包括支持英里,脚,海里万博1manbetx,更多的长度单位。

1.2.0.0

错误修复。

1.1.0.0

现在接受NaN输入。

1.0.0.0