Documentation Center

  • Trial Software
  • Product Updates


Small circles from center and perimeter


[lat,lon] = scircle2(lat1,lon1,lat2,lon2)
[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid)
[lat,lon] = scircle2(lat1,lon1,lat2,lon2,units)
[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid,units)
[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid,units,npts)
[lat,lon] = scircle2(track,...)
mat = scircle2(...)
mat = [lat lon]


[lat,lon] = scircle2(lat1,lon1,lat2,lon2) computes small circles (on a sphere) with centers at the points lat1,lon1 and points on the circles at lat2,lon2. The inputs can be scalar or column vectors.

[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid) computes the small circle on the ellipsoid defined by the input ellipsoid, rather than by assuming a sphere. ellipsoid is a referenceSphere, referenceEllipsoid, or oblateSpheroid object, or a vector of the form [semimajor_axis eccentricity]. Default is a unit sphere.

[lat,lon] = scircle2(lat1,lon1,lat2,lon2,units) and
[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid,units) are valid calling forms, which use the input string units to define the angle units of the inputs and outputs. If the input string units is omitted, 'degrees' is assumed.

[lat,lon] = scircle2(lat1,lon1,lat2,lon2,ellipsoid,units,npts) uses the scalar input npts to determine the number of points per track computed. The default value of npts is 100.

[lat,lon] = scircle2(track,...) uses the track string to define either a great circle or a rhumb line radius. If track' = 'gc', then small circles are computed. If track = 'rh', then circles with radii of constant rhumb line distance are computed. If the track string is omitted, 'gc' is assumed.

mat = scircle2(...) returns a single output argument where mat = [lat lon]. This is useful if a single circle is computed.

Multiple circles can be defined from a single center point by providing scalar lat1,lon1 inputs and column vectors for the points on the circumference, lat2,lon2.


A small circle is the locus of all points an equal surface distance from a given center. For true small circles, this distance is always calculated in a great circle sense. However, the scircle2 function allows a locus to be calculated using distances in a rhumb line sense as well. An example of a small circle is all points exactly 100 miles from the Washington Monument.


Plot the locus of all points the same distance from New Delhi as Kathmandu:

axesm('mercator','MapLatlimit',[0 40],'MapLonLimit',[60 110]);
load coast

% For reference 

% New Delhi  
lat1 = 29; lon1 = 77.5;

% Kathmandu
lat2 = 27.6; lon2 = 85.5;  

% Plot the cities
plotm([lat1 lat2],[lon1 lon2],'b*')   
[latc,lonc] = scircle2(lat1,lon1,lat2,lon2); 

See Also

| | |

Was this topic helpful?