sl.lonlat.angle: Compute Angle (GC-Distance) between Points on Sphere

sl.lonlat.angleR Documentation

Compute Angle (GC-Distance) between Points on Sphere

Description

Compute the angle (great-circle distance) between two points on a sphere.

Usage

sl.lonlat.angle(lon1, lat1, lon2, lat2)

Arguments

lon1

a scalar giving the longitude of the first point.

lat1

a scalar giving the latitude of the first point.

lon2

a scalar giving the longitude of the second point.

lat2

a scalar giving the latitude of the second point.

Value

A scalar giving the angle (great-circle distance) between the two points in degrees.

Note

Do not confuse with sl.angle which provides the angle between two edges of a triangle.

Author(s)

Helge Goessling

See Also

sl.gc.dist, sl.angle.

Examples

sl.lonlat.angle(lon1=0,lat1=50,lon2=10,lat2=40)
## Should return:
## [1] 12.22407

FESOM/spheRlab documentation built on March 7, 2024, 8:39 a.m.