Exploration and global navigation have become widely accessible in recent years with the help with GPS, or Global Positioning System. Today, locations all over the world can be pinpointed using GPS coordinates. By taking the curvature of the earth into account, the GPS coordinates of any two locations can be translated into the straight-line distance between those locations. As a result, planning a backpacking trip through the woods or a stroll through a foreign city is no longer as formidable a task as it once was.

Assign the symbol a to represent the latitude and the symbol b to represent the longitude of each set of GPS coordinates. For example, location one will be represented by the coordinates (a1, b1), while location two will have the coordinates (a2, b2).

Convert the GPS coordinates (a, b) from the typical degree-minute-second format given by most GPS devices into the decimal degree format using the following formula: degrees + (minutes/60) + (seconds/3600) = degrees. For example, a coordinate given as 45 degrees 22 minutes 38 seconds would become 45.3772 degrees when converted using this formula.

Replace the cardinal points W (west) and S (south) associated with the longitude and latitude of each set of GPS coordinates with negative signs. E (east) and N (north) are replaced with positive signs. For example, S45 degrees can be written as -45 degrees.

Use the following formula to calculate the distance in feet of the shortest line across the surface of the earth that joins the two locations represented by GPS coordinates (a1, b1) and (a2, b2): 131332796.6 x (ArcCos{Cos[a1]xCos[b1]xCos[a2]xCos[b2] + Cos[a1]xSin[b1]xCos[a2]xSin[b2] + Sin[a1]xSin[a2]}/360)

#### TL;DR (Too Long; Didn't Read)

Check that the calculator you are using has the degree mode selected before attempting these calculations. Calculations done using the calculator's radian mode will result in errors.

#### Warning

The formula for the calculation of the distance between two locations using sets of GPS coordinates does not incorporate the true shape of the earth, but assumes a spherical earth with a radius of 20902263.779528 feet.