3.4 Making calculations using elevation

This learning object looks at some of the other variables that can be derived from a Digital Elevation Model (DEM). It focuses especially on slope and aspect, which can be calculated by most GIS systems. Slope is the gradient of a given raster grid cell and is usually measured in degrees (0 degrees being flat ground and 90 degrees being a precipice) or as percentages. Aspect of slope (‘aspect’ for short) is the direction in which a slope faces. Aspect is usually measured as a compass bearing in degrees (with 0 degrees being north-facing, 90 degrees being east-facing, 180 degrees being south-facing, and so on up to 359 degrees). Often, a special code (e.g. -1 or -999) is used to represent flat ground in a grid of aspect, since flat grid cells face straight up into the sky, rather than any particular compass direction. Slope and aspect are important variables in many environmental management applications. For example, the rate of soil erosion is often greater on steeper slopes than gentle slopes. Calculating these variables automatically from a DEM saves the environmental manager the expense and effort of measuring slope and aspect through a field survey.

Heuvelink (1998) describes three different types of raster GIS operation: cell-based operations, local operations, and global operations. Cell-based operations are calculations based on only single grid raster grid cells. A cell-based operation might be simple raster grid arithmetic, e.g. comparing two different DEMs by subtracting one from the other. Local operations are calculations based on each cell and its immediately surrounding neighbours. As we will see below, slope and aspect calculations are both local operations. Global operations are calculations based not only on neighbouring cells, but on more distant cells too, e.g. calculating the total area from which a given square within a DEM is visible, or the area upstream of a given grid cell.

How slope and aspect are calculated

Slope and aspect are both calculated by examining the elevation for a particular grid cell in relation to elevation values for the surrounding 8 grid cells. For example, if the three cells to the north of a given grid cell have higher elevations and the three cells to the south all have lower elevations, then the grid cell is likely to be south-facing (it will be tilted southwards). As shown in the illustrations below, such calculations can be made automatically within a GIS. The exact formulae for calculating slope and aspect are given at the NCGIA web site in the references below.

Classifying topography

This same information can also be used to automatically identify topographic features. For example, if a given grid cell shares the same elevation as the eight neighbouring cells around it, it can be classified as a flat plain. If a given grid cell has the same elevation as its eastern and western neigbours, but has grid cells with lower elevations to the north and south, it might be described as a ridge (running east-west). In much the same way, other topographic features (e.g. concave and convex hill slopes, valley bottoms, pits, and peaks) can be identified by examining the elevation of a given grid cell in relation to its neighbours.

Issues when calculating slope and aspect

Bear in mind that there are several factors that will affect the slope and aspect calculated from a DEM. One issue is the resolution of the DEM. For example, a slope calculation based on a very coarse resolution DEM (e.g. one with grid cells of 1 by 1 km) is likely to produce gentler slopes than a fine resolution DEM (e.g. one with grid cells of 10 by 10 metres). A second issue is the data source and / or interpolation method used to create the DEM. For example, some interpolation methods can produce unrealistically abrupt changes in elevation and therefore unrealistically steep slopes. Similarly, a DEM derived from contours on a paper map may exhibit a sudden change in slope where a contour has been drawn incompletely by the original mapmaker.


Activity 1
Q. How would you identify a grid cell that formed a peak within a DEM?


A grid cell that was a peak would have a higher elevation value than any of the surrounding 8 grid cells.


Activity 2

    1. Complete the quiz below.


      Making calculations using elevation

  1. If you wished to assess the accuracy of the slope and aspect digital maps produced from a DEM, how might you do this? Post your thoughts to the forum.

References (Essential reading for this learning object indicated by *)

The following book is the origin of the concepts of cell-based, local and global operations described above. Note that you are not intended to read it and it is cited here as a reference only:

Heuvelink, G. (1998) Error Propagation in Environmental Modeling with GIS. Taylor and Francis.

If you wish to find out the exact formulae used to calculate slope and aspect, see this chapter (https://spatialanalysisonline.com/HTML/gradient__slope_and_aspect.htm) of this online book:

de Smith MJ, Goodchild M, Longley P (2021): Geospatial Analysis – a comprehensive guide to principles, techniques and software tools.  6th edition.  https://spatialanalysisonline.com/

. A more detailed investigation of the various methods used for calculating slope can be found in:

Warren, S., Hohmann, M., Auerswald, K., and Mitasova, H. (2004) An evaluation of methods to determine slope using digital elevation data. Catena 58, 215-233. http://gruenland.wzw.tum.de/fileadmin/auerswald/2004_Warren-CAT.pdf

Comments are closed.