Skip to content

Commit

Permalink
Fix doc issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
kenba committed Mar 29, 2024
1 parent 61b1c49 commit 77c0645
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 9 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/license/mit/)
[![Rust](https://github.com/kenba/icao-wgs84-rs/actions/workflows/rust.yml/badge.svg)](https://github.com/kenba/icao-wgs84-rs/actions)
[![codecov](https://codecov.io/gh/kenba/icao-wgs84-rs/graph/badge.svg?token=G1H1XINERW)](https://codecov.io/gh/kenba/icao-wgs84-rs)
[![codecov](https://codecov.io/gh/kenba/icao-wgs84-rs/graph/badge.svg?token=85TJX5VAHF)](https://codecov.io/gh/kenba/icao-wgs84-rs)

A library for performing geometric calculations on the
[WGS84](https://en.wikipedia.org/wiki/World_Geodetic_System) ellipsoid,
Expand Down Expand Up @@ -51,7 +51,7 @@ by using vectors to solve geodesic intersection and point-to-line problems on
the auxiliary sphere.

This library uses the correspondence between geodesics on an ellipsoid
and great-circles on the auxiliary sphere and 3D vectors to calculate:
and great-circles on the auxiliary sphere together with 3D vectors to calculate:

- the initial azimuth and length of a geodesic between two positions;
- the along track distance and across track distance of a position relative to a geodesic;
Expand Down Expand Up @@ -107,7 +107,7 @@ let wgs84_ellipsoid = Ellipsoid::wgs84();

let istanbul = LatLong::new(Degrees(42.0), Degrees(29.0));
let washington = LatLong::new(Degrees(39.0), Degrees(-77.0));
let g1 = Geodesic::from((&istanbul, &washington, &wgs84_ellipsoid));
let g1 = Geodesic::between_positions(&istanbul, &washington, &wgs84_ellipsoid);

let azimuth_degrees = Degrees::from(g1.azimuth(Metres(0.0)));
println!("Istanbul-Washington initial azimuth: {:?}", azimuth_degrees.0);
Expand Down
17 changes: 11 additions & 6 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
//!
//! [![License](https://img.shields.io/badge/License-MIT-blue)](https://opensource.org/license/mit/)
//! [![Rust](https://github.com/kenba/icao-wgs84-rs/actions/workflows/rust.yml/badge.svg)](https://github.com/kenba/icao-wgs84-rs/actions)
//! [![codecov](https://codecov.io/gh/kenba/icao-wgs84-rs/graph/badge.svg?token=G1H1XINERW)](https://codecov.io/gh/kenba/icao-wgs84-rs)
//! [![codecov](https://codecov.io/gh/kenba/icao-wgs84-rs/graph/badge.svg?token=85TJX5VAHF)](https://codecov.io/gh/kenba/icao-wgs84-rs)
//!
//! A library for performing geometric calculations on the
//! [WGS84](https://en.wikipedia.org/wiki/World_Geodetic_System) ellipsoid,
Expand Down Expand Up @@ -63,9 +63,13 @@
//! solve geodesic intersection and point-to-line problems by using the
//! correspondence between geodesics on an ellipsoid and great-circles on the
//! auxiliary sphere.
//!
//! Nick Korbey and I [Barker and Korbey(2019)](https://www.researchgate.net/publication/335749834_Geodesic_Geometry) developed Baselga and Martinez-Llario's algorithms
//! by using vectors to solve geodesic intersection and point-to-line problems on
//! the auxiliary sphere.
//!
//! This library also uses the correspondence between geodesics on an ellipsoid
//! and great-circles on the auxiliary sphere to calculate:
//! and great-circles on the auxiliary sphere together with 3D vectors to calculate:
//!
//! - the initial azimuth and length of a geodesic between two positions;
//! - the along track distance and across track distance of a position relative to a geodesic;
Expand Down Expand Up @@ -733,7 +737,7 @@ impl<'a> Geodesic<'a> {
///
/// let istanbul = LatLong::new(Degrees(42.0), Degrees(29.0));
/// let washington = LatLong::new(Degrees(39.0), Degrees(-77.0));
/// let g1 = Geodesic::from((&istanbul, &washington, &wgs84_ellipsoid));
/// let g1 = Geodesic::between_positions(&istanbul, &washington, &wgs84_ellipsoid);
///
/// let azimuth_degrees = Degrees::from(g1.azimuth(Metres(0.0)));
/// println!("Istanbul-Washington initial azimuth: {:?}", azimuth_degrees.0);
Expand Down Expand Up @@ -838,12 +842,13 @@ impl<'a> From<(&LatLong, &LatLong, &'a Ellipsoid)> for Geodesic<'a> {
/// closest intersection or reference points.
/// * `g1`, `g2` the Geodesics.
///
/// returns the distances along the Geodesics to the intersection point or to
/// their closest (reference) points if the Geodesics do not intersect.
///
/// # Panics
///
/// The function will panic if the Geodesics are **not** on the same `Ellipsoid`.
///
/// returns the distances along the Geodesics to the intersection point or to
/// their closest (reference) points if the Geodesics do not intersect.
///
/// # Examples
/// ```
/// use icao_wgs84::*;
Expand Down

0 comments on commit 77c0645

Please sign in to comment.