Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

gcIntersect

Intersections of two great circles


Description

Get the two points where two great cricles cross each other. Great circles are defined by two points on it.

Usage

gcIntersect(p1, p2, p3, p4)

Arguments

p1

Longitude/latitude of a single point, in degrees; can be a vector of two numbers, a matrix of 2 columns (first one is longitude, second is latitude) or a SpatialPoints* object

p2

As above

p3

As above

p4

As above

Value

two points for each pair of great circles

Author(s)

Robert Hijmans, based on equations by Ed Williams (see reference)

References

See Also

Examples

p1 <- c(5,52); p2 <- c(-120,37); p3 <- c(-60,0); p4 <- c(0,70)
gcIntersect(p1,p2,p3,p4)

geosphere

Spherical Trigonometry

v1.5-10
GPL (>= 3)
Authors
Robert J. Hijmans [cre, aut], Ed Williams [ctb], Chris Vennes [ctb]
Initial release
2019-05-25

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.