Skip to main content

Module angle

Module angle 

Source

Structs§

Angle
An angular measurement stored as radians.
DmsFmt
Formatter for degrees-minutes-seconds (DMS) notation.
HmsFmt
Formatter for hours-minutes-seconds (HMS) notation.
ParsedAngle
Result of parsing an angle string.

Enums§

NormalizeMode
Specifies which normalization convention to apply.

Traits§

AngleUnits
Parse strings as angles with explicit unit specification.
ParseAngle
Auto-detect and parse angle format.

Functions§

arcmin
Creates an angle from arcminutes. Shorthand for Angle::from_arcminutes.
arcsec
Creates an angle from arcseconds. Shorthand for Angle::from_arcseconds.
clamp_dec
Clamps an angle to [-pi/2, +pi/2] radians (i.e., [-90, +90] degrees).
deg
Creates an angle from degrees. Shorthand for Angle::from_degrees.
hours
Creates an angle from hours. Shorthand for Angle::from_hours.
parse_angle
Parses an angle string, trying HMS format first, then DMS.
parse_dms
Parse a string as degrees-minutes-seconds.
parse_hms
Parse a string as hours-minutes-seconds.
rad
Creates an angle from radians. Shorthand for Angle::from_radians.
validate_declination
Validates declination angle.
validate_latitude
validate_longitude
validate_right_ascension
wrap_0_2pi
Wraps an angle to [0, 2pi) radians.
wrap_pm_pi
Wraps an angle to [-pi, +pi) radians.