🗺️ Geographic Distance Calculator (Lat/Lon)
Compute the great-circle distance between two points with the Haversine formula, accepting decimal degrees or degrees-minutes-seconds.
📐 計算公式
地理距離(Haversine,R=6371km):a = sin²(Δφ÷2)+cosφ₁·cosφ₂·sin²(Δλ÷2),d = R×2·atan2(√a,√(1−a))(km),另出英里 ×0.621371、海里 ÷1.852;初始方位角 = atan2(sinΔλ·cosφ₂, cosφ₁·sinφ₂−sinφ₁·cosφ₂·cosΔλ) 歸一到 0~360° 並按 8 向查表(round(b÷45)%8),中點經緯度按向量法(Bx/By)求,飛行時間 ≈ d ÷ 900(h)。校驗:座標解析失敗報「座標格式無效」,|φ|>90、|λ|>180 分別報錯返回。
基於 Haversine 公式計算地球表面兩點間的大圓距離,支援十進位制度與度分秒輸入
📍 點 A(起點)
📍 點 B(終點)
💡 Haversine:a=sin²(Δφ/2)+cosφ1·cosφ2·sin²(Δλ/2);d=R·2·atan2(√a,√(1−a)),R=6371km
Formula & Standard References
| Item | Formula / Note | Source / Standard |
|---|---|---|
| Great-circle distance | d = R·arccos(sinφ1·sinφ2 + cosφ1·cosφ2·cosΔλ) | Spherical trigonometry; WGS84 R=6371 km |
⚠️ 使用說明與注意事項
- 緯度北正南負(−90~90),經度東正西負(−180~180)
- 預設示例為北京→上海,結果為大圓距離(球面近似),未考慮地形高差
- 按 Enter 快速計算,Ctrl/Cmd + Enter 複製結果
- 本工具純前端執行,資料不會上傳到伺服器
🕘 最近計算
暫無計算記錄