Module unit_sphere::vector::intersection

source ·
Expand description

The intersection module contains functions for calculating great circle intersections using vectors.

A pair of great circles intersect at two points unless they are the same (or opposing) great circles.
For example, points u and v in Figure1.

great circle path
Figure 1 A pair of intersecting great circles

A great circle intersection point can simply be calculated from the cross product of their pole vectors. If the resulting vector is too small to normalize, then the great circles are the same or opposing, in which case they effectively intersect everywhere.

The tricky part is choosing which of the two intersection points to use.
Most of the functions in this module perform that task.

Functions§