Crate jgd

Source
Expand description

Transform geodetic datums used in Japan.

§Examples

use jgd::{LatLon, Tokyo};

let LatLon(lat, lon) = Tokyo::new(LatLon(35.0, 135.0))?
    .to_jgd2000()
    .to_jgd2011()
    .degrees();

Transform coordinates of geo crate:

use geo::{Coord, LineString, MapCoords};
use jgd::{DegreesError, LatLon, Tokyo};

let tokyo_datum = LineString::from(vec![(135.0, 35.0), (135.1, 35.1)]);
let jgd2011 = tokyo_datum.try_map_coords(|Coord { x, y }| -> Result<_, DegreesError> {
    let LatLon(y, x) = Tokyo::new(LatLon(y, x))?
        .to_jgd2000()
        .to_jgd2011()
        .degrees();
    Ok(Coord { x, y })
})?;

§Features

Each feature increases the size of the build binary.

§Limitations

対象地域は日本国内の陸地のみ。海上や国外の座標には適さない。

一般に、測地系変換によって、ある測地系で測量・作成された座標を、あたかも別の測地系かのように模擬できる。 異なる測地系で整備された座標同士のズレを低減できても、ズレが消滅することはない。 変換方法によって精度や制約が異なり、詳細はメソッド毎のドキュメントに記載されている。

緯度経度で表される地理座標のみが対応されている。平面直角座標系などの投影座標は対応されていない。

§Compatibility

パラメータグリッドによる変換は、国土地理院の TKY2JGD および PatchJGD と同等。

3パラメータによる変換は、QGIS などで使われる Proj と同等。

オリジナルの実装との差異が 1mm 以内となるようにテストされている。

§References

Structs§

DegreesError
Errors in input LatLon.
Dms
Degrees minutes seconds.
ECEF
Earth-centered, Earth-fixed coordinate.
Ellipsoid
Earth ellipsoid.
Grid
Parameters grid.
Jgd2000
Japanese Geodetic Datum 2000 (JGD2000).
Jgd2011
Japanese Geodetic Datum 2011 (JGD2011).
LatLon
A pair of latitude and longitude.
Tokyo
Tokyo Datum, The older Japanese Datum.
Tokyo97
Tokyo 97, The older Japanese Datum.

Constants§

BESSEL
Bessel ellipsoid.
GRS80
GRS80 ellipsoid.
TKY2JGDtky2jgd
日本測地系から世界測地系への座標変換パラメータ。
TOUHOKUTAIHEIYOUOKI2011patchjgd
平成23年(2011年)東北地方太平洋沖地震の座標補正パラメータ。