在C++中计算经纬度(附34个城市两两间的距离计算结果)

文章目录

  • 计算说明
  • C++实现代码
  • 计算结果

计算说明

本文使用C++根据输出两个城市的经纬度计算两地间的距离。
几点说明:

  • 经度为E,如果开头为W则取负值;
  • 纬度为N,如果开头为S则取负值;
  • 为了避免中文问题,城市名均使用拼音;
  • 结果单位为公里

C++实现代码

#include 
#include "math.h"
#include 

using namespace std;

double getDistance(double lat1, double long1, double lat2, double long2) {
     
    return 6371 * acos( sin(lat1*0.01745329) * sin(lat2*0.01745329)  + cos(lat1*0.01745329) * cos(lat2*0.01745329) * cos((long1 - long2)*0.01745329));
}

int main(){
     
    vector<string> cities {
     "Heilongjiang", "Jilin", "Xinjiang", "Liaoning", "Inner Mongolia", "Beijing",
                           "Tianjin", "Ningxia", "Hebei", "Shanxi", "Shandong", "Qinghai", "Gansu", "Henan",
                           "Shaanxi", "Jiangsu", "Anhui", "Shanghai", "Hubei", "Sichuan", "Zhejiang", "Tibet",
                           "Chongqing", "Jiangxi", "Hunan", "Guizhou", "Fujian", "Yunnan", "Taiwan", "Guangdong",
                           "Guangxi", "Macao", "Hong Kong", "Hainan" };
    vector<double> lons {
     126.4,125.35,87.68,123.3,111.4,116.2,117.2,106.27,114.3,112.3,117.0,101.5,103.5,113.65,108.6,118.78,117.27,
                         121.3,114.32,104.0,120.2,91.1,106.3,115.9,112.6,106.4,119.2,102.73,121.5,113.1,108.3,113.5,115.1,110.2};
    vector<double> lats {
     45.4,43.88,43.77,41.5,40.5,39.6,39.13,38.47,38.0,37.5,36.65,36.4,36.0,34.77,34.2,32.05,31.87,
                         31.1,30.52,30.4,30.27,29.4,29.4,28.68,28.1,26.4,26.1,25.05,25.05,23.1,22.8,22.2,21.2,20.0};

    for(int i = 0; i < cities.size(); i++){
     
        for (int j = 0; j < cities.size(); ++j) {
     
            if(i == j) continue;
            cout << cities[i] << "->" << cities[j] << ": " << getDistance(lats[i], lons[i], lats[j], lons[j]) << endl;
        }
    }
}

计算结果

C:\Users\Hao\CLionProjects\test2\cmake-build-debug\test2.exe
Heilongjiang->Jilin: 188.325
Heilongjiang->Xinjiang: 3042.05
Heilongjiang->Liaoning: 500.588
Heilongjiang->Inner Mongolia: 1334.19
Heilongjiang->Beijing: 1054.63
Heilongjiang->Tianjin: 1027.94
Heilongjiang->Ningxia: 1828.13
Heilongjiang->Hebei: 1296.08
Heilongjiang->Shanxi: 1463.65
Heilongjiang->Shandong: 1250.56
Heilongjiang->Qinghai: 2306.97
Heilongjiang->Gansu: 2184.28
Heilongjiang->Henan: 1600.35
Heilongjiang->Shaanxi: 1957.78
Heilongjiang->Jiangsu: 1623.11
Heilongjiang->Anhui: 1698.01
Heilongjiang->Shanghai: 1650.36
Heilongjiang->Hubei: 1959.54
Heilongjiang->Sichuan: 2561.97
Heilongjiang->Zhejiang: 1766.89
Heilongjiang->Tibet: 3549.33
Heilongjiang->Chongqing: 2499.81
Heilongjiang->Jiangxi: 2075.43
Heilongjiang->Hunan: 2275.68
Heilongjiang->Guizhou: 2760.49
Heilongjiang->Fujian: 2239.93
Heilongjiang->Yunnan: 3098.16
Heilongjiang->Taiwan: 2305.03
Heilongjiang->Guangdong: 2755.97
Heilongjiang->Guangxi: 2999.83
Heilongjiang->Macao: 2833.36
Heilongjiang->Hong Kong: 2881.81
Jilin->Heilongjiang: 188.325
Jilin->Xinjiang: 2995.38
Jilin->Liaoning: 313.199
Jilin->Inner Mongolia: 1207.42
Jilin->Beijing: 895.209
Jilin->Tianjin: 859.274
Jilin->Ningxia: 1701.64
Jilin->Hebei: 1133.73
Jilin->Shanxi: 1306.77
Jilin->Shandong: 1070.42
Jilin->Qinghai: 2181.49
Jilin->Gansu: 2050.22
Jilin->Henan: 1425.17
Jilin->Shaanxi: 1797.37
Jilin->Jiangsu: 1434.79
Jilin->Anhui: 1510.26
Jilin->Shanghai: 1464.8
Jilin->Hubei: 1774.36
Jilin->Sichuan: 2401.63
Jilin->Zhejiang: 1579.97
Jilin->Tibet: 3420.08
Jilin->Chongqing: 2330.4
Jilin->Jiangxi: 1887.48
Jilin->Hunan: 2090.75
Jilin->Guizhou: 2584.65
Jilin->Fujian: 2053.35
Jilin->Yunnan: 2927.83
Jilin->Taiwan: 2122.7
Jilin->Guangdong: 2568.08
Jilin->Guangxi: 2816.32
Jilin->Macao: 2645.18
Jilin->Hong Kong: 2693.59
Xinjiang->Heilongjiang: 3042.05
Xinjiang->Jilin: 2995.38
Xinjiang->Liaoning: 2902.25
Xinjiang->Inner Mongolia: 1982.29
Xinjiang->Beijing: 2400.83
Xinjiang->Tianjin: 2499.8
Xinjiang->Ningxia: 1660.52
Xinjiang->Hebei: 2316.65
Xinjiang->Shanxi: 2181.72
Xinjiang->Shandong: 2596.86
Xinjiang->Qinghai: 1430.09
Xinjiang->Gansu: 1598.45
Xinjiang->Henan: 2435.95
Xinjiang->Shaanxi: 2089.22
Xinjiang->Jiangsu: 2999.85
Xinjiang->Anhui: 2894.93
Xinjiang->Shanghai: 3256.04
Xinjiang->Hubei: 2764.26
Xinjiang->Sichuan: 2067.57
Xinjiang->Zhejiang: 3225.16
Xinjiang->Tibet: 1626.38
Xinjiang->Chongqing: 2295.62
Xinjiang->Jiangxi: 3013.34
Xinjiang->Hunan: 2821.51
Xinjiang->Guizhou: 2562.79
Xinjiang->Fujian: 3447.36
Xinjiang->Yunnan: 2488.88
Xinjiang->Taiwan: 3695.89
Xinjiang->Guangdong: 3267.72
Xinjiang->Guangxi: 3000.65
Xinjiang->Macao: 3371.4
Xinjiang->Hong Kong: 3561.52
Liaoning->Heilongjiang: 500.588
Liaoning->Jilin: 313.199
Liaoning->Xinjiang: 2902.25
Liaoning->Inner Mongolia: 1004.01
Liaoning->Beijing: 635.761
Liaoning->Tianjin: 580.27
Liaoning->Ningxia: 1486.87
Liaoning->Hebei: 861.631
Liaoning->Shanxi: 1042.3
Liaoning->Shandong: 765.475
Liaoning->Qinghai: 1962.51
Liaoning->Gansu: 1817.7
Liaoning->Henan: 1126.67
Liaoning->Shaanxi: 1521.5
Liaoning->Jiangsu: 1124.82
Liaoning->Anhui: 1197.43
Liaoning->Shanghai: 1170.13
Liaoning->Hubei: 1462
Liaoning->Sichuan: 2123.04
Liaoning->Zhejiang: 1279.31
Liaoning->Tibet: 3187.6
Liaoning->Chongqing: 2037.98
Liaoning->Jiangxi: 1574.96
Liaoning->Hunan: 1778.5
Liaoning->Guizhou: 2282.61
Liaoning->Fujian: 1753.22
Liaoning->Yunnan: 2633.01
Liaoning->Taiwan: 1836.67
Liaoning->Guangdong: 2255.43
Liaoning->Guangxi: 2505.13
Liaoning->Macao: 2333.28
Liaoning->Hong Kong: 2384.91
Inner Mongolia->Heilongjiang: 1334.19
Inner Mongolia->Jilin: 1207.42
Inner Mongolia->Xinjiang: 1982.29
Inner Mongolia->Liaoning: 1004.01
Inner Mongolia->Beijing: 420.583
Inner Mongolia->Tianjin: 518.158
Inner Mongolia->Ningxia: 494.632
Inner Mongolia->Hebei: 373.63
Inner Mongolia->Shanxi: 342.525
Inner Mongolia->Shandong: 648.017
Inner Mongolia->Qinghai: 974.4
Inner Mongolia->Gansu: 851.637
Inner Mongolia->Henan: 667.172
Inner Mongolia->Shaanxi: 742.848
Inner Mongolia->Jiangsu: 1148.14
Inner Mongolia->Anhui: 1094.05
Inner Mongolia->Shanghai: 1372.74
Inner Mongolia->Hubei: 1140.57
Inner Mongolia->Sichuan: 1306.69
Inner Mongolia->Zhejiang: 1387.7
Inner Mongolia->Tibet: 2215.45
Inner Mongolia->Chongqing: 1318.24
Inner Mongolia->Jiangxi: 1376.82
Inner Mongolia->Hunan: 1383.17
Inner Mongolia->Guizhou: 1634.25
Inner Mongolia->Fujian: 1755.78
Inner Mongolia->Yunnan: 1897.13
Inner Mongolia->Taiwan: 1957.09
Inner Mongolia->Guangdong: 1941.34
Inner Mongolia->Guangxi: 1989.53
Inner Mongolia->Macao: 2044.44
Inner Mongolia->Hong Kong: 2174.37
Beijing->Heilongjiang: 1054.63
Beijing->Jilin: 895.209
Beijing->Xinjiang: 2400.83
Beijing->Liaoning: 635.761
Beijing->Inner Mongolia: 420.583
Beijing->Tianjin: 100.605
Beijing->Ningxia: 866.365
Beijing->Hebei: 242.397
Beijing->Shanxi: 411.698
Beijing->Shandong: 335.402
Beijing->Qinghai: 1334.55
Beijing->Gansu: 1184.17
Beijing->Henan: 582.572
Beijing->Shaanxi: 903.38
Beijing->Jiangsu: 871.033
Beijing->Anhui: 864.924
Beijing->Shanghai: 1051.78
Beijing->Hubei: 1023.97
Beijing->Sichuan: 1507.74
Beijing->Zhejiang: 1099.32
Beijing->Tibet: 2552.57
Beijing->Chongqing: 1450.35
Beijing->Jiangxi: 1214.56
Beijing->Hunan: 1320.92
Beijing->Guizhou: 1726.44
Beijing->Fujian: 1526.8
Beijing->Yunnan: 2048.99
Beijing->Taiwan: 1691.91
Beijing->Guangdong: 1857.84
Beijing->Guangxi: 2011.34
Beijing->Macao: 1951.59
Beijing->Hong Kong: 2048.66
Tianjin->Heilongjiang: 1027.94
Tianjin->Jilin: 859.274
Tianjin->Xinjiang: 2499.8
Tianjin->Liaoning: 580.27
Tianjin->Inner Mongolia: 518.158
Tianjin->Beijing: 100.605
Tianjin->Ningxia: 949.437
Tianjin->Hebei: 281.69
Tianjin->Shanxi: 464.252
Tianjin->Shandong: 276.321
Tianjin->Qinghai: 1411.12
Tianjin->Gansu: 1255.24
Tianjin->Henan: 578.287
Tianjin->Shaanxi: 942.096
Tianjin->Jiangsu: 800.077
Tianjin->Anhui: 807.3
Tianjin->Shanghai: 967.341
Tianjin->Hubei: 992.662
Tianjin->Sichuan: 1545.06
Tianjin->Zhejiang: 1022.47
Tianjin->Tibet: 2618.82
Tianjin->Chongqing: 1472.13
Tianjin->Jiangxi: 1168.12
Tianjin->Hunan: 1297.83
Tianjin->Guizhou: 1735.83
Tianjin->Fujian: 1460.81
Tianjin->Yunnan: 2070.29
Tianjin->Taiwan: 1616.62
Tianjin->Guangdong: 1824.11
Tianjin->Guangxi: 2001.68
Tianjin->Macao: 1915.01
Tianjin->Hong Kong: 2003.75
Ningxia->Heilongjiang: 1828.13
Ningxia->Jilin: 1701.64
Ningxia->Xinjiang: 1660.52
Ningxia->Liaoning: 1486.87
Ningxia->Inner Mongolia: 494.632
Ningxia->Beijing: 866.365
Ningxia->Tianjin: 949.437
Ningxia->Hebei: 703.07
Ningxia->Shanxi: 539.26
Ningxia->Shandong: 966.603
Ningxia->Qinghai: 479.859
Ningxia->Gansu: 368.156
Ningxia->Henan: 776.179
Ningxia->Shaanxi: 518.596
Ningxia->Jiangsu: 1339.65
Ningxia->Anhui: 1238.76
Ningxia->Shanghai: 1595.53
Ningxia->Hubei: 1150.35
Ningxia->Sichuan: 921.081
Ningxia->Zhejiang: 1567.38
Ningxia->Tibet: 1721.2
Ningxia->Chongqing: 1008.54
Ningxia->Jiangxi: 1405.67
Ningxia->Hunan: 1293.66
Ningxia->Guizhou: 1342.18
Ningxia->Fujian: 1831.63
Ningxia->Yunnan: 1528.94
Ningxia->Taiwan: 2067.91
Ningxia->Guangdong: 1827.89
Ningxia->Guangxi: 1753.08
Ningxia->Macao: 1935.9
Ningxia->Hong Kong: 2098.05
Hebei->Heilongjiang: 1296.08
Hebei->Jilin: 1133.73
Hebei->Xinjiang: 2316.65
Hebei->Liaoning: 861.631
Hebei->Inner Mongolia: 373.63
Hebei->Beijing: 242.397
Hebei->Tianjin: 281.69
Hebei->Ningxia: 703.07
Hebei->Shanxi: 184.417
Hebei->Shandong: 281.994
Hebei->Qinghai: 1146.62
Hebei->Gansu: 983.901
Hebei->Henan: 363.839
Hebei->Shaanxi: 663.683
Hebei->Jiangsu: 777.009
Hebei->Anhui: 733.304
Hebei->Shanghai: 999.143
Hebei->Hubei: 831.74
Hebei->Sichuan: 1267.9
Hebei->Zhejiang: 1016.14
Hebei->Tibet: 2341.13
Hebei->Chongqing: 1208.09
Hebei->Jiangxi: 1046.89
Hebei->Hunan: 1112.11
Hebei->Guizhou: 1487.24
Hebei->Fujian: 1400.88
Hebei->Yunnan: 1806.69
Hebei->Taiwan: 1592.12
Hebei->Guangdong: 1660.74
Hebei->Guangxi: 1784.3
Hebei->Macao: 1758.54
Hebei->Hong Kong: 1869.65
Shanxi->Heilongjiang: 1463.65
Shanxi->Jilin: 1306.77
Shanxi->Xinjiang: 2181.72
Shanxi->Liaoning: 1042.3
Shanxi->Inner Mongolia: 342.525
Shanxi->Beijing: 411.698
Shanxi->Tianjin: 464.252
Shanxi->Ningxia: 539.26
Shanxi->Hebei: 184.417
Shanxi->Shandong: 427.494
Shanxi->Qinghai: 966.929
Shanxi->Gansu: 801.255
Shanxi->Henan: 326.865
Shanxi->Shaanxi: 495.745
Shanxi->Jiangsu: 846.624
Shanxi->Anhui: 773.286
Shanxi->Shanghai: 1089.84
Shanxi->Hubei: 798.097
Shanxi->Sichuan: 1098.78
Shanxi->Zhejiang: 1084.52
Shanxi->Tibet: 2156.71
Shanxi->Chongqing: 1058.21
Shanxi->Jiangxi: 1036.25
Shanxi->Hunan: 1045.61
Shanxi->Guizhou: 1353.18
Shanxi->Fujian: 1424.39
Shanxi->Yunnan: 1654.17
Shanxi->Taiwan: 1635.29
Shanxi->Guangdong: 1603.03
Shanxi->Guangxi: 1678.71
Shanxi->Macao: 1705.17
Shanxi->Hong Kong: 1832.42
Shandong->Heilongjiang: 1250.56
Shandong->Jilin: 1070.42
Shandong->Xinjiang: 2596.86
Shandong->Liaoning: 765.475
Shandong->Inner Mongolia: 648.017
Shandong->Beijing: 335.402
Shandong->Tianjin: 276.321
Shandong->Ningxia: 966.603
Shandong->Hebei: 281.994
Shandong->Shanxi: 427.494
Shandong->Qinghai: 1383.79
Shandong->Gansu: 1210.57
Shandong->Henan: 367.636
Shandong->Shaanxi: 808.056
Shandong->Jiangsu: 536.932
Shandong->Anhui: 532.09
Shandong->Shanghai: 733.573
Shandong->Hubei: 725.33
Shandong->Sichuan: 1389.21
Shandong->Zhejiang: 768.886
Shandong->Tibet: 2536.3
Shandong->Chongqing: 1281.07
Shandong->Jiangxi: 892.164
Shandong->Hunan: 1036.28
Shandong->Guizhou: 1517.21
Shandong->Fujian: 1191.44
Shandong->Yunnan: 1871.83
Shandong->Taiwan: 1359.02
Shandong->Guangdong: 1552.48
Shandong->Guangxi: 1752.25
Shandong->Macao: 1641.77
Shandong->Hong Kong: 1727.77
Qinghai->Heilongjiang: 2306.97
Qinghai->Jilin: 2181.49
Qinghai->Xinjiang: 1430.09
Qinghai->Liaoning: 1962.51
Qinghai->Inner Mongolia: 974.4
Qinghai->Beijing: 1334.55
Qinghai->Tianjin: 1411.12
Qinghai->Ningxia: 479.859
Qinghai->Hebei: 1146.62
Qinghai->Shanxi: 966.929
Qinghai->Shandong: 1383.79
Qinghai->Gansu: 184.885
Qinghai->Henan: 1112.79
Qinghai->Shaanxi: 688.982
Qinghai->Jiangsu: 1658.02
Qinghai->Anhui: 1534.14
Qinghai->Shanghai: 1918.98
Qinghai->Hubei: 1355.43
Qinghai->Sichuan: 706.299
Qinghai->Zhejiang: 1862.21
Qinghai->Tibet: 1243.06
Qinghai->Chongqing: 897.818
Qinghai->Jiangxi: 1596.89
Qinghai->Hunan: 1391.49
Qinghai->Guizhou: 1204.79
Qinghai->Fujian: 2029.94
Qinghai->Yunnan: 1267.49
Qinghai->Taiwan: 2283.21
Qinghai->Guangdong: 1851.74
Qinghai->Guangxi: 1647.73
Qinghai->Macao: 1957.67
Qinghai->Hong Kong: 2142.7
Gansu->Heilongjiang: 2184.28
Gansu->Jilin: 2050.22
Gansu->Xinjiang: 1598.45
Gansu->Liaoning: 1817.7
Gansu->Inner Mongolia: 851.637
Gansu->Beijing: 1184.17
Gansu->Tianjin: 1255.24
Gansu->Ningxia: 368.156
Gansu->Hebei: 983.901
Gansu->Shanxi: 801.255
Gansu->Shandong: 1210.57
Gansu->Qinghai: 184.885
Gansu->Henan: 929.813
Gansu->Shaanxi: 505.208
Gansu->Jiangsu: 1473.19
Gansu->Anhui: 1349.3
Gansu->Shanghai: 1734.14
Gansu->Hubei: 1175.06
Gansu->Sichuan: 624.424
Gansu->Zhejiang: 1677.56
Gansu->Tibet: 1371.13
Gansu->Chongqing: 779.14
Gansu->Jiangxi: 1419.16
Gansu->Hunan: 1226.48
Gansu->Guizhou: 1102.36
Gansu->Fujian: 1852.92
Gansu->Yunnan: 1219.8
Gansu->Taiwan: 2104.8
Gansu->Guangdong: 1706.52
Gansu->Guangxi: 1539.05
Gansu->Macao: 1813.63
Gansu->Hong Kong: 1994.05
Henan->Heilongjiang: 1600.35
Henan->Jilin: 1425.17
Henan->Xinjiang: 2435.95
Henan->Liaoning: 1126.67
Henan->Inner Mongolia: 667.172
Henan->Beijing: 582.572
Henan->Tianjin: 578.287
Henan->Ningxia: 776.179
Henan->Hebei: 363.839
Henan->Shanxi: 326.865
Henan->Shandong: 367.636
Henan->Qinghai: 1112.79
Henan->Gansu: 929.813
Henan->Shaanxi: 467.126
Henan->Jiangsu: 563.975
Henan->Anhui: 465.889
Henan->Shanghai: 821.958
Henan->Hubei: 476.72
Henan->Sichuan: 1025.73
Henan->Zhejiang: 791.821
Henan->Tibet: 2201.38
Henan->Chongqing: 913.831
Henan->Jiangxi: 709.762
Henan->Hunan: 748.314
Henan->Guizhou: 1160.14
Henan->Fujian: 1100.63
Henan->Yunnan: 1506.59
Henan->Taiwan: 1318.21
Henan->Guangdong: 1298.74
Henan->Guangxi: 1428.8
Henan->Macao: 1397.8
Henan->Hong Kong: 1515.56
Shaanxi->Heilongjiang: 1957.78
Shaanxi->Jilin: 1797.37
Shaanxi->Xinjiang: 2089.22
Shaanxi->Liaoning: 1521.5
Shaanxi->Inner Mongolia: 742.848
Shaanxi->Beijing: 903.38
Shaanxi->Tianjin: 942.096
Shaanxi->Ningxia: 518.596
Shaanxi->Hebei: 663.683
Shaanxi->Shanxi: 495.745
Shaanxi->Shandong: 808.056
Shaanxi->Qinghai: 688.982
Shaanxi->Gansu: 505.208
Shaanxi->Henan: 467.126
Shaanxi->Jiangsu: 977.193
Shaanxi->Anhui: 848.38
Shaanxi->Shanghai: 1236.99
Shaanxi->Hubei: 675.132
Shaanxi->Sichuan: 604.389
Shaanxi->Zhejiang: 1174.38
Shaanxi->Tibet: 1735.11
Shaanxi->Chongqing: 576.244
Shaanxi->Jiangxi: 924.883
Shaanxi->Hunan: 777.603
Shaanxi->Guizhou: 892.588
Shaanxi->Fujian: 1358.59
Shaanxi->Yunnan: 1164.34
Shaanxi->Taiwan: 1606.8
Shaanxi->Guangdong: 1309.6
Shaanxi->Guangxi: 1267.96
Shaanxi->Macao: 1417.54
Shaanxi->Hong Kong: 1579.8
Jiangsu->Heilongjiang: 1623.11
Jiangsu->Jilin: 1434.79
Jiangsu->Xinjiang: 2999.85
Jiangsu->Liaoning: 1124.82
Jiangsu->Inner Mongolia: 1148.14
Jiangsu->Beijing: 871.033
Jiangsu->Tianjin: 800.077
Jiangsu->Ningxia: 1339.65
Jiangsu->Hebei: 777.009
Jiangsu->Shanxi: 846.624
Jiangsu->Shandong: 536.932
Jiangsu->Qinghai: 1658.02
Jiangsu->Gansu: 1473.19
Jiangsu->Henan: 563.975
Jiangsu->Shaanxi: 977.193
Jiangsu->Anhui: 143.851
Jiangsu->Shanghai: 261.045
Jiangsu->Hubei: 456.639
Jiangsu->Sichuan: 1416.17
Jiangsu->Zhejiang: 239.642
Jiangsu->Tibet: 2654.92
Jiangsu->Chongqing: 1227.96
Jiangsu->Jiangxi: 465.531
Jiangsu->Hunan: 739.039
Jiangsu->Guizhou: 1354.39
Jiangsu->Fujian: 662.865
Jiangsu->Yunnan: 1747.55
Jiangsu->Taiwan: 822.353
Jiangsu->Guangdong: 1141.32
Jiangsu->Guangxi: 1457.04
Jiangsu->Macao: 1213.02
Jiangsu->Hong Kong: 1260.42
Anhui->Heilongjiang: 1698.01
Anhui->Jilin: 1510.26
Anhui->Xinjiang: 2894.93
Anhui->Liaoning: 1197.43
Anhui->Inner Mongolia: 1094.05
Anhui->Beijing: 864.924
Anhui->Tianjin: 807.3
Anhui->Ningxia: 1238.76
Anhui->Hebei: 733.304
Anhui->Shanxi: 773.286
Anhui->Shandong: 532.09
Anhui->Qinghai: 1534.14
Anhui->Gansu: 1349.3
Anhui->Henan: 465.889
Anhui->Shaanxi: 848.38
Anhui->Jiangsu: 143.851
Anhui->Shanghai: 391.59
Anhui->Hubei: 318.207
Anhui->Sichuan: 1272.71
Anhui->Zhejiang: 330.927
Anhui->Tibet: 2512.75
Anhui->Chongqing: 1084.34
Anhui->Jiangxi: 378.311
Anhui->Hunan: 614.702
Anhui->Guizhou: 1217.43
Anhui->Fujian: 668.451
Anhui->Yunnan: 1608.87
Anhui->Taiwan: 863.532
Anhui->Guangdong: 1058.1
Anhui->Guangxi: 1341.24
Anhui->Macao: 1137.98
Anhui->Hong Kong: 1205.83
Shanghai->Heilongjiang: 1650.36
Shanghai->Jilin: 1464.8
Shanghai->Xinjiang: 3256.04
Shanghai->Liaoning: 1170.13
Shanghai->Inner Mongolia: 1372.74
Shanghai->Beijing: 1051.78
Shanghai->Tianjin: 967.341
Shanghai->Ningxia: 1595.53
Shanghai->Hebei: 999.143
Shanghai->Shanxi: 1089.84
Shanghai->Shandong: 733.573
Shanghai->Qinghai: 1918.98
Shanghai->Gansu: 1734.14
Shanghai->Henan: 821.958
Shanghai->Shaanxi: 1236.99
Shanghai->Jiangsu: 261.045
Shanghai->Anhui: 391.59
Shanghai->Hubei: 669.603
Shanghai->Sichuan: 1653.38
Shanghai->Zhejiang: 139.935
Shanghai->Tibet: 2898.09
Shanghai->Chongqing: 1452.01
Shanghai->Jiangxi: 585.907
Shanghai->Hunan: 904.519
Shanghai->Guizhou: 1542.09
Shanghai->Fujian: 592.527
Shanghai->Yunnan: 1939
Shanghai->Taiwan: 673.015
Shanghai->Guangdong: 1203.34
Shanghai->Guangxi: 1582.88
Shanghai->Macao: 1256.17
Shanghai->Hong Kong: 1262.17
Hubei->Heilongjiang: 1959.54
Hubei->Jilin: 1774.36
Hubei->Xinjiang: 2764.26
Hubei->Liaoning: 1462
Hubei->Inner Mongolia: 1140.57
Hubei->Beijing: 1023.97
Hubei->Tianjin: 992.662
Hubei->Ningxia: 1150.35
Hubei->Hebei: 831.74
Hubei->Shanxi: 798.097
Hubei->Shandong: 725.33
Hubei->Qinghai: 1355.43
Hubei->Gansu: 1175.06
Hubei->Henan: 476.72
Hubei->Shaanxi: 675.132
Hubei->Jiangsu: 456.639
Hubei->Anhui: 318.207
Hubei->Shanghai: 669.603
Hubei->Sichuan: 988.898
Hubei->Zhejiang: 564.583
Hubei->Tibet: 2236.47
Hubei->Chongqing: 782.411
Hubei->Jiangxi: 255.327
Hubei->Hunan: 316.567
Hubei->Guizhou: 899.23
Hubei->Fujian: 685.228
Hubei->Yunnan: 1291.18
Hubei->Taiwan: 931.673
Hubei->Guangdong: 833.881
Hubei->Guangxi: 1045.83
Hubei->Macao: 928.731
Hubei->Hong Kong: 1039.26
Sichuan->Heilongjiang: 2561.97
Sichuan->Jilin: 2401.63
Sichuan->Xinjiang: 2067.57
Sichuan->Liaoning: 2123.04
Sichuan->Inner Mongolia: 1306.69
Sichuan->Beijing: 1507.74
Sichuan->Tianjin: 1545.06
Sichuan->Ningxia: 921.081
Sichuan->Hebei: 1267.9
Sichuan->Shanxi: 1098.78
Sichuan->Shandong: 1389.21
Sichuan->Qinghai: 706.299
Sichuan->Gansu: 624.424
Sichuan->Henan: 1025.73
Sichuan->Shaanxi: 604.389
Sichuan->Jiangsu: 1416.17
Sichuan->Anhui: 1272.71
Sichuan->Shanghai: 1653.38
Sichuan->Hubei: 988.898
Sichuan->Zhejiang: 1553.47
Sichuan->Tibet: 1247.77
Sichuan->Chongqing: 248.021
Sichuan->Jiangxi: 1166.41
Sichuan->Hunan: 872.381
Sichuan->Guizhou: 502.884
Sichuan->Fujian: 1562.18
Sichuan->Yunnan: 607.867
Sichuan->Taiwan: 1819.87
Sichuan->Guangdong: 1213.7
Sichuan->Guangxi: 946.814
Sichuan->Macao: 1313.44
Sichuan->Hong Kong: 1508.67
Zhejiang->Heilongjiang: 1766.89
Zhejiang->Jilin: 1579.97
Zhejiang->Xinjiang: 3225.16
Zhejiang->Liaoning: 1279.31
Zhejiang->Inner Mongolia: 1387.7
Zhejiang->Beijing: 1099.32
Zhejiang->Tianjin: 1022.47
Zhejiang->Ningxia: 1567.38
Zhejiang->Hebei: 1016.14
Zhejiang->Shanxi: 1084.52
Zhejiang->Shandong: 768.886
Zhejiang->Qinghai: 1862.21
Zhejiang->Gansu: 1677.56
Zhejiang->Henan: 791.821
Zhejiang->Shaanxi: 1174.38
Zhejiang->Jiangsu: 239.642
Zhejiang->Anhui: 330.927
Zhejiang->Shanghai: 139.935
Zhejiang->Hubei: 564.583
Zhejiang->Sichuan: 1553.47
Zhejiang->Tibet: 2800.92
Zhejiang->Chongqing: 1343.4
Zhejiang->Jiangxi: 452.198
Zhejiang->Hunan: 776.049
Zhejiang->Guizhou: 1416.37
Zhejiang->Fujian: 473.92
Zhejiang->Yunnan: 1813.44
Zhejiang->Taiwan: 594.373
Zhejiang->Guangdong: 1063.93
Zhejiang->Guangxi: 1444.62
Zhejiang->Macao: 1118.22
Zhejiang->Hong Kong: 1130.11
Tibet->Heilongjiang: 3549.33
Tibet->Jilin: 3420.08
Tibet->Xinjiang: 1626.38
Tibet->Liaoning: 3187.6
Tibet->Inner Mongolia: 2215.45
Tibet->Beijing: 2552.57
Tibet->Tianjin: 2618.82
Tibet->Ningxia: 1721.2
Tibet->Hebei: 2341.13
Tibet->Shanxi: 2156.71
Tibet->Shandong: 2536.3
Tibet->Qinghai: 1243.06
Tibet->Gansu: 1371.13
Tibet->Henan: 2201.38
Tibet->Shaanxi: 1735.11
Tibet->Jiangsu: 2654.92
Tibet->Anhui: 2512.75
Tibet->Shanghai: 2898.09
Tibet->Hubei: 2236.47
Tibet->Sichuan: 1247.77
Tibet->Zhejiang: 2800.92
Tibet->Chongqing: 1471.45
Tibet->Jiangxi: 2407.75
Tibet->Hunan: 2098.01
Tibet->Guizhou: 1538.83
Tibet->Fujian: 2782.69
Tibet->Yunnan: 1246.68
Tibet->Taiwan: 3035.78
Tibet->Guangdong: 2298.76
Tibet->Guangxi: 1865.08
Tibet->Macao: 2376.16
Tibet->Hong Kong: 2572.96
Chongqing->Heilongjiang: 2499.81
Chongqing->Jilin: 2330.4
Chongqing->Xinjiang: 2295.62
Chongqing->Liaoning: 2037.98
Chongqing->Inner Mongolia: 1318.24
Chongqing->Beijing: 1450.35
Chongqing->Tianjin: 1472.13
Chongqing->Ningxia: 1008.54
Chongqing->Hebei: 1208.09
Chongqing->Shanxi: 1058.21
Chongqing->Shandong: 1281.07
Chongqing->Qinghai: 897.818
Chongqing->Gansu: 779.14
Chongqing->Henan: 913.831
Chongqing->Shaanxi: 576.244
Chongqing->Jiangsu: 1227.96
Chongqing->Anhui: 1084.34
Chongqing->Shanghai: 1452.01
Chongqing->Hubei: 782.411
Chongqing->Sichuan: 248.021
Chongqing->Zhejiang: 1343.4
Chongqing->Tibet: 1471.45
Chongqing->Jiangxi: 936.429
Chongqing->Hunan: 630.859
Chongqing->Guizhou: 333.729
Chongqing->Fujian: 1320.54
Chongqing->Yunnan: 598.706
Chongqing->Taiwan: 1577.34
Chongqing->Guangdong: 974.534
Chongqing->Guangxi: 760.525
Chongqing->Macao: 1076.67
Chongqing->Hong Kong: 1269.44
Jiangxi->Heilongjiang: 2075.43
Jiangxi->Jilin: 1887.48
Jiangxi->Xinjiang: 3013.34
Jiangxi->Liaoning: 1574.96
Jiangxi->Inner Mongolia: 1376.82
Jiangxi->Beijing: 1214.56
Jiangxi->Tianjin: 1168.12
Jiangxi->Ningxia: 1405.67
Jiangxi->Hebei: 1046.89
Jiangxi->Shanxi: 1036.25
Jiangxi->Shandong: 892.164
Jiangxi->Qinghai: 1596.89
Jiangxi->Gansu: 1419.16
Jiangxi->Henan: 709.762
Jiangxi->Shaanxi: 924.883
Jiangxi->Jiangsu: 465.531
Jiangxi->Anhui: 378.311
Jiangxi->Shanghai: 585.907
Jiangxi->Hubei: 255.327
Jiangxi->Sichuan: 1166.41
Jiangxi->Zhejiang: 452.198
Jiangxi->Tibet: 2407.75
Jiangxi->Chongqing: 936.429
Jiangxi->Hunan: 329.178
Jiangxi->Guizhou: 970.029
Jiangxi->Fujian: 434.066
Jiangxi->Yunnan: 1366.39
Jiangxi->Taiwan: 686.481
Jiangxi->Guangdong: 680.68
Jiangxi->Guangxi: 1002.96
Jiangxi->Macao: 759.706
Jiangxi->Hong Kong: 835.631
Hunan->Heilongjiang: 2275.68
Hunan->Jilin: 2090.75
Hunan->Xinjiang: 2821.51
Hunan->Liaoning: 1778.5
Hunan->Inner Mongolia: 1383.17
Hunan->Beijing: 1320.92
Hunan->Tianjin: 1297.83
Hunan->Ningxia: 1293.66
Hunan->Hebei: 1112.11
Hunan->Shanxi: 1045.61
Hunan->Shandong: 1036.28
Hunan->Qinghai: 1391.49
Hunan->Gansu: 1226.48
Hunan->Henan: 748.314
Hunan->Shaanxi: 777.603
Hunan->Jiangsu: 739.039
Hunan->Anhui: 614.702
Hunan->Shanghai: 904.519
Hunan->Hubei: 316.567
Hunan->Sichuan: 872.381
Hunan->Zhejiang: 776.049
Hunan->Tibet: 2098.01
Hunan->Chongqing: 630.859
Hunan->Jiangxi: 329.178
Hunan->Guizhou: 641.286
Hunan->Fujian: 690.002
Hunan->Yunnan: 1038.06
Hunan->Taiwan: 947.494
Hunan->Guangdong: 558.228
Hunan->Guangxi: 730.393
Hunan->Macao: 662.266
Hunan->Hong Kong: 807.695
Guizhou->Heilongjiang: 2760.49
Guizhou->Jilin: 2584.65
Guizhou->Xinjiang: 2562.79
Guizhou->Liaoning: 2282.61
Guizhou->Inner Mongolia: 1634.25
Guizhou->Beijing: 1726.44
Guizhou->Tianjin: 1735.83
Guizhou->Ningxia: 1342.18
Guizhou->Hebei: 1487.24
Guizhou->Shanxi: 1353.18
Guizhou->Shandong: 1517.21
Guizhou->Qinghai: 1204.79
Guizhou->Gansu: 1102.36
Guizhou->Henan: 1160.14
Guizhou->Shaanxi: 892.588
Guizhou->Jiangsu: 1354.39
Guizhou->Anhui: 1217.43
Guizhou->Shanghai: 1542.09
Guizhou->Hubei: 899.23
Guizhou->Sichuan: 502.884
Guizhou->Zhejiang: 1416.37
Guizhou->Tibet: 1538.83
Guizhou->Chongqing: 333.729
Guizhou->Jiangxi: 970.029
Guizhou->Hunan: 641.286
Guizhou->Fujian: 1276.43
Guizhou->Yunnan: 397.081
Guizhou->Taiwan: 1519.18
Guizhou->Guangdong: 769.479
Guizhou->Guangxi: 443.984
Guizhou->Macao: 857.529
Guizhou->Hong Kong: 1056.73
Fujian->Heilongjiang: 2239.93
Fujian->Jilin: 2053.35
Fujian->Xinjiang: 3447.36
Fujian->Liaoning: 1753.22
Fujian->Inner Mongolia: 1755.78
Fujian->Beijing: 1526.8
Fujian->Tianjin: 1460.81
Fujian->Ningxia: 1831.63
Fujian->Hebei: 1400.88
Fujian->Shanxi: 1424.39
Fujian->Shandong: 1191.44
Fujian->Qinghai: 2029.94
Fujian->Gansu: 1852.92
Fujian->Henan: 1100.63
Fujian->Shaanxi: 1358.59
Fujian->Jiangsu: 662.865
Fujian->Anhui: 668.451
Fujian->Shanghai: 592.527
Fujian->Hubei: 685.228
Fujian->Sichuan: 1562.18
Fujian->Zhejiang: 473.92
Fujian->Tibet: 2782.69
Fujian->Chongqing: 1320.54
Fujian->Jiangxi: 434.066
Fujian->Hunan: 690.002
Fujian->Guizhou: 1276.43
Fujian->Yunnan: 1654.96
Fujian->Taiwan: 258.546
Fujian->Guangdong: 701.017
Fujian->Guangxi: 1162.25
Fujian->Macao: 722.691
Fujian->Hong Kong: 686.357
Yunnan->Heilongjiang: 3098.16
Yunnan->Jilin: 2927.83
Yunnan->Xinjiang: 2488.88
Yunnan->Liaoning: 2633.01
Yunnan->Inner Mongolia: 1897.13
Yunnan->Beijing: 2048.99
Yunnan->Tianjin: 2070.29
Yunnan->Ningxia: 1528.94
Yunnan->Hebei: 1806.69
Yunnan->Shanxi: 1654.17
Yunnan->Shandong: 1871.83
Yunnan->Qinghai: 1267.49
Yunnan->Gansu: 1219.8
Yunnan->Henan: 1506.59
Yunnan->Shaanxi: 1164.34
Yunnan->Jiangsu: 1747.55
Yunnan->Anhui: 1608.87
Yunnan->Shanghai: 1939
Yunnan->Hubei: 1291.18
Yunnan->Sichuan: 607.867
Yunnan->Zhejiang: 1813.44
Yunnan->Tibet: 1246.68
Yunnan->Chongqing: 598.706
Yunnan->Jiangxi: 1366.39
Yunnan->Hunan: 1038.06
Yunnan->Guizhou: 397.081
Yunnan->Fujian: 1654.96
Yunnan->Taiwan: 1889.28
Yunnan->Guangdong: 1074.57
Yunnan->Guangxi: 618.87
Yunnan->Macao: 1141.63
Yunnan->Hong Kong: 1334.73
Taiwan->Heilongjiang: 2305.03
Taiwan->Jilin: 2122.7
Taiwan->Xinjiang: 3695.89
Taiwan->Liaoning: 1836.67
Taiwan->Inner Mongolia: 1957.09
Taiwan->Beijing: 1691.91
Taiwan->Tianjin: 1616.62
Taiwan->Ningxia: 2067.91
Taiwan->Hebei: 1592.12
Taiwan->Shanxi: 1635.29
Taiwan->Shandong: 1359.02
Taiwan->Qinghai: 2283.21
Taiwan->Gansu: 2104.8
Taiwan->Henan: 1318.21
Taiwan->Shaanxi: 1606.8
Taiwan->Jiangsu: 822.353
Taiwan->Anhui: 863.532
Taiwan->Shanghai: 673.015
Taiwan->Hubei: 931.673
Taiwan->Sichuan: 1819.87
Taiwan->Zhejiang: 594.373
Taiwan->Tibet: 3035.78
Taiwan->Chongqing: 1577.34
Taiwan->Jiangxi: 686.481
Taiwan->Hunan: 947.494
Taiwan->Guizhou: 1519.18
Taiwan->Fujian: 258.546
Taiwan->Yunnan: 1889.28
Taiwan->Guangdong: 879.734
Taiwan->Guangxi: 1364.17
Taiwan->Macao: 874.226
Taiwan->Hong Kong: 781.843
Guangdong->Heilongjiang: 2755.97
Guangdong->Jilin: 2568.08
Guangdong->Xinjiang: 3267.72
Guangdong->Liaoning: 2255.43
Guangdong->Inner Mongolia: 1941.34
Guangdong->Beijing: 1857.84
Guangdong->Tianjin: 1824.11
Guangdong->Ningxia: 1827.89
Guangdong->Hebei: 1660.74
Guangdong->Shanxi: 1603.03
Guangdong->Shandong: 1552.48
Guangdong->Qinghai: 1851.74
Guangdong->Gansu: 1706.52
Guangdong->Henan: 1298.74
Guangdong->Shaanxi: 1309.6
Guangdong->Jiangsu: 1141.32
Guangdong->Anhui: 1058.1
Guangdong->Shanghai: 1203.34
Guangdong->Hubei: 833.881
Guangdong->Sichuan: 1213.7
Guangdong->Zhejiang: 1063.93
Guangdong->Tibet: 2298.76
Guangdong->Chongqing: 974.534
Guangdong->Jiangxi: 680.68
Guangdong->Hunan: 558.228
Guangdong->Guizhou: 769.479
Guangdong->Fujian: 701.017
Guangdong->Yunnan: 1074.57
Guangdong->Taiwan: 879.734
Guangdong->Guangxi: 492.596
Guangdong->Macao: 108.166
Guangdong->Hong Kong: 295.052
Guangxi->Heilongjiang: 2999.83
Guangxi->Jilin: 2816.32
Guangxi->Xinjiang: 3000.65
Guangxi->Liaoning: 2505.13
Guangxi->Inner Mongolia: 1989.53
Guangxi->Beijing: 2011.34
Guangxi->Tianjin: 2001.68
Guangxi->Ningxia: 1753.08
Guangxi->Hebei: 1784.3
Guangxi->Shanxi: 1678.71
Guangxi->Shandong: 1752.25
Guangxi->Qinghai: 1647.73
Guangxi->Gansu: 1539.05
Guangxi->Henan: 1428.8
Guangxi->Shaanxi: 1267.96
Guangxi->Jiangsu: 1457.04
Guangxi->Anhui: 1341.24
Guangxi->Shanghai: 1582.88
Guangxi->Hubei: 1045.83
Guangxi->Sichuan: 946.814
Guangxi->Zhejiang: 1444.62
Guangxi->Tibet: 1865.08
Guangxi->Chongqing: 760.525
Guangxi->Jiangxi: 1002.96
Guangxi->Hunan: 730.393
Guangxi->Guizhou: 443.984
Guangxi->Fujian: 1162.25
Guangxi->Yunnan: 618.87
Guangxi->Taiwan: 1364.17
Guangxi->Guangdong: 492.596
Guangxi->Macao: 538.319
Guangxi->Hong Kong: 723.201
Macao->Heilongjiang: 2833.36
Macao->Jilin: 2645.18
Macao->Xinjiang: 3371.4
Macao->Liaoning: 2333.28
Macao->Inner Mongolia: 2044.44
Macao->Beijing: 1951.59
Macao->Tianjin: 1915.01
Macao->Ningxia: 1935.9
Macao->Hebei: 1758.54
Macao->Shanxi: 1705.17
Macao->Shandong: 1641.77
Macao->Qinghai: 1957.67
Macao->Gansu: 1813.63
Macao->Henan: 1397.8
Macao->Shaanxi: 1417.54
Macao->Jiangsu: 1213.02
Macao->Anhui: 1137.98
Macao->Shanghai: 1256.17
Macao->Hubei: 928.731
Macao->Sichuan: 1313.44
Macao->Zhejiang: 1118.22
Macao->Tibet: 2376.16
Macao->Chongqing: 1076.67
Macao->Jiangxi: 759.706
Macao->Hunan: 662.266
Macao->Guizhou: 857.529
Macao->Fujian: 722.691
Macao->Yunnan: 1141.63
Macao->Taiwan: 874.226
Macao->Guangdong: 108.166
Macao->Guangxi: 538.319
Macao->Hong Kong: 199.219
Hong Kong->Heilongjiang: 2881.81
Hong Kong->Jilin: 2693.59
Hong Kong->Xinjiang: 3561.52
Hong Kong->Liaoning: 2384.91
Hong Kong->Inner Mongolia: 2174.37
Hong Kong->Beijing: 2048.66
Hong Kong->Tianjin: 2003.75
Hong Kong->Ningxia: 2098.05
Hong Kong->Hebei: 1869.65
Hong Kong->Shanxi: 1832.42
Hong Kong->Shandong: 1727.77
Hong Kong->Qinghai: 2142.7
Hong Kong->Gansu: 1994.05
Hong Kong->Henan: 1515.56
Hong Kong->Shaanxi: 1579.8
Hong Kong->Jiangsu: 1260.42
Hong Kong->Anhui: 1205.83
Hong Kong->Shanghai: 1262.17
Hong Kong->Hubei: 1039.26
Hong Kong->Sichuan: 1508.67
Hong Kong->Zhejiang: 1130.11
Hong Kong->Tibet: 2572.96
Hong Kong->Chongqing: 1269.44
Hong Kong->Jiangxi: 835.631
Hong Kong->Hunan: 807.695
Hong Kong->Guizhou: 1056.73
Hong Kong->Fujian: 686.357
Hong Kong->Yunnan: 1334.73
Hong Kong->Taiwan: 781.843
Hong Kong->Guangdong: 295.052
Hong Kong->Guangxi: 723.201
Hong Kong->Macao: 199.219

你可能感兴趣的:(C/C++,算法设计与分析,C++,经纬度计算)