Function wmm::declination [−][src]
Expand description
Returns the magnetic declination for a given date and location
Arguments
date
- Date within the 2020 to 2025 time rangelat
- Latitude: -90.00 to +90.00 degreeslon
- Longitude: -180.00 to +180.00 degrees
Examples
use time::{Date, Month};
use wmm::declination;
let date = Date::from_calendar_date(2021, Month::September, 1).unwrap();
let lat = 29.7363025;
let lon = -93.8827939;
let dec = declination(date, lat, lon).unwrap();