MagneticDeclinationProvider

Provides magnetic declination values for a given location and time.

Magnetic declination is the angle between true north and magnetic north at a specific geographic location. This abstraction allows for testability and future extensions (e.g., caching, model updates, alternative data sources).

Typical values: -20° to +20° depending on location (varies ~6° per 1000 km).

Inheritors

Functions

Link copied to clipboard
abstract fun getMagneticDeclination(latitude: Float, longitude: Float, altitude: Float = 0.0f, timeMillis: Long): Float?

Calculate magnetic declination at the given location and time.