Main Content

scxsc

Intersection points for pairs of small circles

Description

example

[lat,lon] = scxsc(lat1,lon1,range1,lat2,lon2,range2) returns in lat and lon the locations where pairs of small circles intersect. The small circles are defined using small circle notation, which consists of a center point and a radius in units of angular arc length. For example, the first small circle in a pair would be centered on the point (lat1,lon1) with a radius of range1 (in angular units).

For any pair of small circles, there are four possible intersection conditions: the circles are identical, they do not intersect, they are tangent to each other and hence they intersect once, or they intersect twice.

[lat,lon] = scxsc(lat1,lon1,range1,lat2,lon2,range2,units) specifies the angular units used for all inputs, where units is any valid angular unit.

latlon = scxsc(___) returns a single output consisting of the concatenated latitude and longitude coordinates of the small circle intersection points.

Examples

Find Intersection Points of Two Small Circles

Given a small circle centered at (10ºS,170ºW) with a radius of 20º (~1200 nautical miles), where does it intersect with a small circle centered at (3ºN, 179ºE), with a radius of 15º (~900 nautical miles)?

[newlat,newlon] = scxsc(-10,-170,20,3,179,15)
newlat =
   -8.8368    9.8526

newlon =
   169.7578 -167.5637

Note that in this example, the two small circles cross the date line.

Input Arguments

collapse all

Latitude or longitude coordinate of the center of the first small circle in each pair, specified as one of these values.

  • A numeric scalar to find the intersection of a single pair of small circles.

  • A n-element numeric vector to find the intersection of n pairs of small circles.

lat1 and lon1 must have the same length.

Example: -10

Example: [-10 20 90 -45]

Radius of the first small circle of each pair, in angular units, specified as one of these values.

  • A positive numeric scalar to find the intersection of a single pair of small circles.

  • A n-element vector of positive numbers to find the intersection of n pairs of small circles. The length of range1 matches the length of lat1 and lon1.

Example: 20

Example: [20 10 45 45]

Latitude or longitude coordinate of the center of the second small circle in each pair, specified as one of these values.

  • A numeric scalar to find the intersection of a single pair of small circles.

  • A n-element numeric vector to find the intersection of n pairs of small circles.

lat2 and lon2 must have the same length as lat1 and lon1.

Example: 3

Example: [3 30 85 -45]

Radius of the second small circle of each pair, in angular units, specified as one of these values.

  • A positive numeric scalar to find the intersection of a single pair of small circles.

  • A n-element vector of positive numbers to find the intersection of n pairs of small circles. The length of range2 matches the length of lat2 and lon2.

Example: 15

Example: [15 15 45 50]

Angular units, specified as 'degrees' or 'radians'.

Output Arguments

collapse all

Coordinates of small circle intersections, returned as one of the following.

  • 2-element vector when you find the intersection of a single pair of small circles.

  • n-by-2 matrix when you find the intersection of n pairs of small circles.

If a pair of small circles do not intersect, or are identical, then scxsc displays a warning and returns NaNs for the latitude and longitude coordinates of the intersection points. If a pair of small circles are tangent, then the single intersection point is returned twice.

Concatenated coordinates of small circle intersections, returned as one of the following. This output is identical to [lat lon].

  • 4-element vector when you find the intersection of a single pair of small circles.

  • n-by-4 matrix when you find the intersection of n pairs of small circles.

If a pair of small circles do not intersect, or are identical, then scxsc displays a warning and returns NaNs for the latitude and longitude coordinates of the intersection points. If a pair of small circles are tangent, then the single intersection point is returned twice.

Tips

Great circles are a subset of small circles — a great circle is just a small circle with a radius of 90º. This provides two methods of notation for defining great circles. Great circle notation consists of a point on the circle and an azimuth at that point. Small circle notation for a great circle consists of a center point and a radius of 90º (or its equivalent in radians).

Introduced before R2006a