SME
Geographic Information Systems (GIS) · Problem type
Straight-line and grid distance
Use this for “How far is it from (2, 3) to (8, 11) km, straight and along a street grid?”
Chart
dₘ
=
|Δx|
+
|Δy|
=
6
+
8
=
14
km:
along
the
grid
(heavy),
and
every
path
that
never
turns
back
(the
staircase)
is
as
long.
d
=
√
Δx² + Δy²
=
10
km,
the
straight
line
(dashed),
is
shorter.
This is an example. Type your own values to start a new problem.
x₁
x of point 1
example
y₁
y of point 1
example
x₂
x of point 2
example
y₂
y of point 2
example
Δx
Change in x
worked out (not typed)
Δy
Change in y
worked out (not typed)
d
Straight-line distance
calculated
dₘ
Grid distance
calculated
Formulas
Δx
=
x₂
−
x₁
6 = 8 − 2
Δy
=
y₂
−
y₁
8 = 11 − 3
d
=
√
Δx² + Δy²
10
=
√
6
2
+
8
2
dₘ = |Δx| + |Δy|
14 = |6| + |8|
Assumptions
•
Projected coordinates in kilometres on a flat map, with x east and y north; a flat map is true to a few hundred km.
•
Grid distance runs only east–west and north–south, like streets on a square grid.
•
Grid distance is never shorter than the straight line, and at most 1.41 times it.
Step-by-step
WE KNOW
x₁ = 2 km, y₁ = 3 km, x₂ = 8 km, y₂ = 11 km
FIND
change in x (Δx), change in y (Δy), straight-line distance (d), grid distance (dₘ)
Step 1 · Find change in x (Δx)
Use Δx = x₂ − x₁
How far east the second point is from the first (negative when it is west).
Δx = 8 − 2
Δx = 6 km
Step 2 · Find change in y (Δy)
Use Δy = y₂ − y₁
How far north the second point is from the first (negative when it is south).
Δy = 11 − 3
Δy = 8 km
Step 3 · Find straight-line distance (d)
Use d = √(Δx² + Δy²)
Δx and Δy are the legs of a right triangle, and the straight line is its hypotenuse.
d
=
√
6
2
+
8
2
d
=
√
36 + 64
d
=
√
100
d
=
10
km
Step 4 · Find grid distance (dₘ)
Use dₘ = |Δx| + |Δy|
Along a grid you go the whole way across, then the whole way up: add the two legs’ lengths.
dₘ = |6| + |8|
dₘ = 6 + 8
dₘ = 14 km
Check
Put the numbers back in. Both sides should match.
6 = 8 − 2 ✓
8 = 11 − 3 ✓
10
=
√
6
2
+
8
2
✓
14 = |6| + |8| ✓
Topic check
See what you know: 5 questions on this topic
New questions each time. Pass to mark it complete.