Azimuth
Azimuth is the angle a line makes with a meridian, measured clockwise from north. Thus the azimuth of due north is 0°, due east is 90°, due south is 180°, and due west is 270°. You can instruct several Mapping Toolbox™ functions to compute azimuths for any pair of point locations, either along rhumb lines or along great circles. These will have different results except along cardinal directions. For great circles, the result is the azimuth at the initial point of the pair defining a great circle path. This is because great circle azimuths other than 0°, 90°, 180°, and 270° do not remain constant. Azimuths for rhumb lines are constant along their entire path (by definition).
For rhumb lines, computing an azimuth backward (from the second point to the first) yields the complement of the forward azimuth ((Az + 180°) mod 360°). For great circles, the back azimuth is generally not the complement, and the difference depends on the distance between the two points.
In addition to forward and back azimuths, Mapping Toolbox functions can compute locations of points a given distance and azimuth from a reference point, and can calculate tracks to connect waypoints, along either great circles or rhumb lines on a sphere or ellipsoid.
For more an example that uses azimuths, see Reckoning
Calculate Azimuth
When the azimuth is calculated from one point to another using the toolbox, the result depends upon whether you want a great circle or a rhumb line azimuth. For great circles, the result is the azimuth at the starting point of the connecting great circle path. In general, the azimuth along a great circle is not constant. For rhumb lines, the resulting azimuth is constant along the entire path.
Azimuths, or bearings, are returned in the same angular units as the input latitudes and longitudes. The default path type is the shorter great circle, and the default angular units are degrees. In the example, the great circle azimuth from the first point to the second is
azgc = azimuth(-15,0,60,150) azgc = 19.0391
For the rhumb line, the constant azimuth is
azrh = azimuth('rh',-15,0,60,150) azrh = 58.8595
One feature of rhumb lines is that the inverse azimuth, from the second point to the first, is the complement of the forward azimuth and can be calculated by simply adding 180° to the forward value:
inverserh = azimuth('rh',60,150,-15,0) inverserh = 238.8595 difference = inverserh-azrh difference = 180
This is not true, in general, of great circles:
inversegc = azimuth('gc',60,150,-15,0) inversegc = 320.9353 difference = inversegc-azgc difference = 301.8962
The azimuths associated with cardinal and intercardinal compass directions are the following:
North |
0° or 360° |
Northeast |
45° |
East |
90° |
Southeast |
135° |
South |
180° |
Southwest |
225° |
West |
270° |
Northwest |
315° |