lesson

Updated 1 month ago Β· 9 views
If you walk 4 blocks east and 3 blocks north on a city grid, you walk 7 blocks in total. But what if a drone flies straight from your start to your finish?
The straight-line path cuts diagonally across the grid. To find that exact diagonal length, we turn the grid into a right triangle.
Building the Right Triangle
On a Cartesian grid, any two points (x1β,y1β) and (x2β,y2β) form the opposite corners of a right triangle.
πA clean 2D Cartesian coordinate plane showing points A(1, 2) and B(5, 5). Draw a right triangle where segment AB is the red hypotenuse, a horizontal dotted blue line runs from (1, 2) to (5, 2) labeled '|x2 - x1| = 4', and a vertical dotted green line runs from (5, 2) to (5, 5) labeled '|y2 - y1| = 3'. Include a right-angle square marker at (5, 2). Label point A, point B, and hypotenuse 'd'. Use responsive SVG, clear font labels, card background #ffffff, grid lines #f0f0f0.
The hypotenuse is the longest side of a right triangle, located directly across from the 90β right angle.
Around 500 BCE, ancient Greek mathematicians formalized the Pythagorean theorem, which proves that the sum of the squared legs equals the squared hypotenuse: a2+b2=c2.
How do we turn this geometry rule into an algebraic formula for any pair of coordinates?
Deriving the Distance Formula
The horizontal leg length is the difference between x-values, Ξx=x2ββx1β. The vertical leg length is the difference between y-values, Ξy=y2ββy1β.
Plugging these legs into the Pythagorean relationship gives d2=(x2ββx1β)2+(y2ββy1β)2. Taking the principal square root gives the distance formula:
d=(x2ββx1β)2+(y2ββy1β)2β
Let's test this formula on a concrete pair of coordinates.