9 Coordinate reference systems

In this section we review what a coordinate reference system (CRS) is. The materials here are meant to act as a refresher of the lesson on coordinate reference systems in week 2 of the EDS 223 - Geospatial Analysis & Remote Sensing MEDS course.

How to create a CRS

Since the Earth does not have lines and numbers etched on it, we humans need to create a system to locate places on its surface. A way to solve this is to create a coordinate reference system (CRS). A CRS is, at its core, a way to represent places on the Earth as coordinates.

To understand what the components of a CRS are, it can be useful to think of the process we would go through to match places on the Earth to coordinates that represent them.

Step 1. Pick an ellipsoid

Think of the Earth. Our planet is not a perfect sphere. Besides its rugged surface with high mountains and deep ocean trenches, its overall shape is not perfectly round either. Due to the Earth’s rotation, the planet is slightly wider at the Equator. Thus, a sphere is not the best way to model the shape of the Earth. Instead, we use an ellipsoid. Think of an ellipsoid as a sphere that has been slightly flattened at the poles. This is the first step for creating a CRS: picking an ellipsoid, a.k.a. picking a shape for the Earth. The ellipsoid used to represent the Earth’s shape has changed across time and it may also change depending on the application.

Step 2. Align the ellipsoid with Earth’s locations to obtain a datum

The ellipsoid is an abstract mathematical object on which we can locate points by using angles. The coordinate system on the ellipsoid uses two angles: latitude (north or south of the Equator) and longitude (east or west of the prime meridian).

Latitude and longitude as angular coordinates on the ellipsoid. Image source: Coordinate systems and map projections - University of Twente

The next step to create a CRS is thus to make a decision on how to align the ellipsoid so that its surface corresponds to actual places on the Earth. We could think, for example, of:

  • how to place the ellipsoid’s center relative to Earth’s mass center (is it the same or is it off?) or
  • how to align the ellipsoid’s axes with the Earth (which meridian will be our prime meridian?).

Generally speaking, a geodetic datum, or just a datum, is how we are aligning our abstract ellipsoid to match the Earth’s surface.

Regional datums to optimize location accuracy. Image source: GPS for Land Surveyors
Datums may change across time and applications

Geographers and cartographers have created and used many datums across time and applications. A datum refers both to a choice of ellipsoid and how to align it to the Earth. More importantly, different datums are used to increase the accuracy of representing different regions of Earth. On Wikipedia you can see examples of datums optimized for different regions.

Step 3. Obtain a geographic CRS with lat/lon coordinates for all the Earth

At this point, we have successfully made a correspondence between the Earth’s surface and our ellipsoid. This means we can now use the latitude, longitude (lat/lon) coordinates of the ellipsoid to locate any point on the Earth’s surface. This is called a geographic CRS. Geographic coordinate reference systems use degrees of latitude and longitude to locate points on the Earth, still thinking of it as a 3D object.

We use a geographic CRS to create angular coordinates on the Earth (latitude and longitude) that allow us to locate any place

Step 4. Select a projection to flatten a portion of your ellipsoid and make a map

A map is a flat (2-dimensional) representation of a region of the Earth. In a geographic CRS we use a 3-dimensional model of the Earth (the ellipsoid) to locate places on it. To transform our 3-dimensional ellipsoid to make a 2-dimensional representation we need to use a projection. A projection is a method to convert between angular coordinates (i.e. lat/lon coordinates in 3D) and planar coordinates (i.e. \(x\),\(y\) coordinates in 2D).

Image Source: Battersby, S. (2017). Map Projections. The Geographic Information Science & Technology Body of Knowledge
Many projections

There are many ways to project an ellipsoid into a 2-dimensional region. However, no matter what projection we use, the area, distances, or angles of the actual regions on Earth will be distorted when we project. Ultimately, the choice of projection relies on whether we want to optimize calculations involving area, angle, or distance measurements, as well as aesthetics when creating a map.

The following video, Vox - Why all world maps are wrong, does a great job at explaining how projections work!

Step 5. Obtain a projected CRS with \(x\),\(y\) coordinates for a specific region

When we project a region of the ellipsoid to represent a region of Earth on the plane we obtain a new set of planar coordinates, thus creating a projected CRS. A projected CRS must also include a unit of measure for its axes. These new coordinates are usually called eastings, when referring to the eastward-measured distance (\(x\)-coordinate), and northings, when referring to the northward-measured distance (\(y\)-coordinate).

A projected CRS gives planar coordinates.

CRS codes

There are thousands of CRSs in use. Listing every component of a CRS (ellipsoid, datum, projection, and units) each time we need to refer to one would be impractical. Instead, each CRS is usually identified by a short code. The most common codes come from the EPSG Geodetic Parameter Dataset, a public registry of CRSs maintained by the International Association of Oil & Gas Producers (IOGP). An EPSG code is written as EPSG: followed by a number, for example EPSG:4326. Python packages like geopandas use these codes to know exactly which CRS our data is in.

These are some CRSs we will encounter often:

  • EPSG:4326 - WGS 84. The World Geodetic System 1984 (WGS 84) is a geographic CRS designed to work for the whole Earth. It is the CRS used by the Global Positioning System (GPS), and its coordinates are latitude and longitude in degrees.

  • EPSG:4269 - NAD83. The North American Datum of 1983 (NAD83) is a geographic CRS optimized for North America. Many US government datasets, like the ones from the US Census Bureau, use it.

  • EPSG:26911 - NAD83 / UTM zone 11N. This is a projected CRS built on the NAD83 datum. It uses the Universal Transverse Mercator (UTM) projection, which divides the Earth into 60 zones, each 6 degrees of longitude wide. Zone 11N covers most of Southern California, including Santa Barbara. Its coordinates are eastings and northings in meters.

Notice that the name of a projected CRS usually starts with the name of the geographic CRS it is built on, followed by the projection.

Looking up a CRS

Websites like epsg.io and spatialreference.org let you search for a CRS by its code or name. For example, epsg.io/4326 shows the details of WGS 84 and the area of the Earth where it can be used.