Core concepts of Coordinate and Vector types
mainThe library uses Coordinate and Vector types to represent points and vectors. To prevent accidental misuse of coordinates from different spaces, these types are generic over a CoordinateSystem.
You can define custom coordinate systems with specific semantics using the system! macro. This allows you to distinguish between different instances of the same base system (e.g., distinguishing between PlaneFrd and EmitterFrd even if both are based on the FRD system).
Supported base coordinate systems include:
Wgs84: Latitude, longitude, and altitude.Ecef: Earth-centered, Earth-fixed Cartesian coordinates.Ned: North, East, Down (local tangent plane).Frd: Front, Right, Down (body frame).Enu: East, North, Up (local tangent plane).
// Define custom coordinate systems using the system! macro
system!(struct PlaneFrd using FRD);
system!(struct PlaneNed using NED);
// Coordinates are now tied to these specific systems
let coord = Coordinate::<PlaneFrd>::from_bearing(...);