Documentation ¶
Overview ¶
Package latlon implements handling of geodetic coordinates as latitude and longitude.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Degrees ¶
type Degrees float64
Degrees represents an angle in degrees.
func Azimuth ¶
Azimuth calculates the azimuth between two coordinates in degrees. See http://www.movable-type.co.uk/scripts/latlong.html for more details.
type Km ¶
type Km float64
Km represents kilometers.
func Distance ¶
Distance calculates the great circle distance between two coordinates in kilometers using the haversine formula. See http://www.movable-type.co.uk/scripts/latlong.html for more details.
type LatLon ¶
LatLon contains a pair of coordinates consisting of latitude and longitude.
func NewLatLon ¶
NewLatLon creates a new pair of coordinates. It normalizes the given latitude and longitude.
func ParseLatLon ¶
ParseLatLon parses a latitude and longitude from two strings and returns the parsed data as LatLon.