Spherical

A Spherical value stores the latitude and azimuthal angles. For efficiency, the angles are not converted to any standard interval, though some operations on values do so. They can be accessed directly as the lat and lon (for longitude) fields.

Multiplicative inverse (inv) and sign of Spherical values exploit the structure of the representation. Otherwise, most operations are done by first converting to Complex.

The comparators iszero, isinf, isfinite, and isapprox are defined appropriately.

ComplexValues.SphericalMethod
Spherical(latitude,azimuth)

Construct a spherical representation with given latitude in [-π/2,π/2] and azimuth.

source
ComplexValues.S2coordMethod
S2coord(u::Spherical)

Convert the spherical value to a 3-vector of coordinates on the unit sphere.

source