0.2.0
Loading...
Searching...
No Matches
Ellipsoid.hpp File Reference

Functions concerning the ellipsoid model. More...

Go to the source code of this file.

Functions

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcEarthRadius_E (const Scalar &latitude, const Scalar &a=InsConst< Scalar >::WGS84::a, const Scalar &e_squared=InsConst<>::WGS84::e_squared)
 Calculates the East/West (prime vertical) earth radius.
 
template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcEarthRadius_N (const Scalar &latitude, const Scalar &a=InsConst<>::WGS84::a, const Scalar &e_squared=InsConst<>::WGS84::e_squared)
 Calculates the North/South (meridian) earth radius.
 
template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGeocentricRadius (const Scalar &latitude, const Scalar &R_E, const Scalar &e_squared=InsConst< Scalar >::WGS84::e_squared)
 r_eS^e The distance of a point on the Earth's surface from the center of the Earth
 
template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGeographicalDistance (Scalar lat1, Scalar lon1, Scalar lat2, Scalar lon2)
 Measure the distance between two points over an ellipsoidal-surface.
 
template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGreatCircleDistance (Scalar lat1, Scalar lon1, Scalar lat2, Scalar lon2)
 Measure the distance between two points on a sphere.
 
template<typename Derived >
Eigen::Matrix3< typename Derived::Scalar > NAV::conversionMatrixCartesianCurvilinear (const Eigen::MatrixBase< Derived > &lla_position, const typename Derived::Scalar &R_N, const typename Derived::Scalar &R_E)
 Conversion matrix between cartesian and curvilinear perturbations to the position.
 

Detailed Description

Functions concerning the ellipsoid model.

Author
T. Topp (topp@.nosp@m.ins..nosp@m.uni-s.nosp@m.tutt.nosp@m.gart..nosp@m.de)
Date
2021-11-28

Function Documentation

◆ calcEarthRadius_E()

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcEarthRadius_E ( const Scalar & latitude,
const Scalar & a = InsConst<Scalar>::WGS84::a,
const Scalar & e_squared = InsConst<>::WGS84::e_squared )

Calculates the East/West (prime vertical) earth radius.

Parameters
[in]latitude𝜙 Latitude in [rad]
[in]aSemi-major axis
[in]e_squaredSquare of the first eccentricity of the ellipsoid
Returns
East/West (prime vertical) earth radius [m]
Note
See [17] Groves, ch. 2.4.2, eq. 2.106, p. 59
See [45] Titterton, ch. 3.7.2, eq. 3.84, p. 49

◆ calcEarthRadius_N()

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcEarthRadius_N ( const Scalar & latitude,
const Scalar & a = InsConst<>::WGS84::a,
const Scalar & e_squared = InsConst<>::WGS84::e_squared )

Calculates the North/South (meridian) earth radius.

Parameters
[in]latitude𝜙 Latitude in [rad]
[in]aSemi-major axis
[in]e_squaredSquare of the first eccentricity of the ellipsoid
Returns
North/South (meridian) earth radius [m]
Note
See [17] Groves, ch. 2.4.2, eq. 2.105, p. 59
See [45] Titterton, ch. 3.7.2, eq. 3.83, p. 49

◆ calcGeocentricRadius()

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGeocentricRadius ( const Scalar & latitude,
const Scalar & R_E,
const Scalar & e_squared = InsConst<Scalar>::WGS84::e_squared )

r_eS^e The distance of a point on the Earth's surface from the center of the Earth

Parameters
[in]latitude𝜙 Latitude in [rad]
[in]R_EPrime vertical radius of curvature (East/West) in [m]
[in]e_squaredSquare of the first eccentricity of the ellipsoid
Returns
Geocentric Radius in [m]
Note
[17] Groves, ch. 2.4.7, eq. 2.137, p. 71

◆ calcGeographicalDistance()

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGeographicalDistance ( Scalar lat1,
Scalar lon1,
Scalar lat2,
Scalar lon2 )

Measure the distance between two points over an ellipsoidal-surface.

Parameters
[in]lat1Latitude of first point in [rad]
[in]lon1Longitude of first point in [rad]
[in]lat2Latitude of second point in [rad]
[in]lon2Longitude of second point in [rad]
Returns
The distance in [m]
Note
See Lambert's formula for long lines (https://en.wikipedia.org/wiki/Geographical_distance#Lambert's_formula_for_long_lines)

◆ calcGreatCircleDistance()

template<typename Scalar , typename = std::enable_if_t<std::is_floating_point_v<Scalar>>>
Scalar NAV::calcGreatCircleDistance ( Scalar lat1,
Scalar lon1,
Scalar lat2,
Scalar lon2 )

Measure the distance between two points on a sphere.

Parameters
[in]lat1Latitude of first point in [rad]
[in]lon1Longitude of first point in [rad]
[in]lat2Latitude of second point in [rad]
[in]lon2Longitude of second point in [rad]
Returns
The distance in [m]
Note
See Haversine Formula (https://www.movable-type.co.uk/scripts/latlong.html)

◆ conversionMatrixCartesianCurvilinear()

template<typename Derived >
Eigen::Matrix3< typename Derived::Scalar > NAV::conversionMatrixCartesianCurvilinear ( const Eigen::MatrixBase< Derived > & lla_position,
const typename Derived::Scalar & R_N,
const typename Derived::Scalar & R_E )

Conversion matrix between cartesian and curvilinear perturbations to the position.

Parameters
[in]lla_positionPosition as Lat Lon Alt in [rad rad m]
[in]R_NMeridian radius of curvature in [m]
[in]R_EPrime vertical radius of curvature (East/West) [m]
Returns
T_rn_p A 3x3 matrix
Note
See [17] Groves, ch. 2.4.3, eq. 2.119, p. 63