The perpendicular distance formula, the distance between parallel lines, altitudes and areas of triangles, and which side of a line a point lies on.
Lesson 7 of 8
5 min read
10 practice questions
The distance from a point to a line means the shortest distance, which is measured along the perpendicular from the point to the line. There is a neat formula for it, and from it come the distance between two parallel lines, the altitude and area of a triangle, and a test for whether two points lie on the same side of a line. This lesson develops all of these.
Result. The perpendicular distance from the point P(x1,y1) to the line ax+by+c=0 is
d=a2+b2∣ax1+by1+c∣
In words: substitute the point into the left side of the equation, take the modulus, and divide by a2+b2.
Why. Let the line cut the axes at A(−ac,0) and B(0,−bc) (assume a, b, c non-zero; the other cases are simpler). The area of triangle PAB can be found in two ways: as 21×AB×d, and from the coordinates by the determinant formula. Working this out, the area is 2∣ab∣∣c∣∣ax1+by1+c∣, while AB=∣ab∣∣c∣a2+b2. Equating the two expressions for the area and cancelling gives the formula.
Special case. The distance from the origin to ax+by+c=0 is a2+b2∣c∣.
Two parallel lines can be written with the same x and y coefficients: ax+by+c1=0 and ax+by+c2=0. The distance between them is
d=a2+b2∣c1−c2∣
(Take any point on one line and find its distance from the other.) Before using the formula, make sure the coefficients of x and y are the same in both equations.
In the triangle with vertices A(1,3), B(0,0), C(4,3), find the altitude from A and the area.
The line BC passes through the origin with slope 43, so it is 3x−4y=0. The altitude from A is
9+16∣3(1)−4(3)∣=5∣3−12∣=59
BC=16+9=5, so the area is 21×5×59=29 square units. (The determinant formula from the matrices course gives the same: 21∣1(0−3)−3(0−4)+1(0)∣=29.)
For the line ax+by+c=0, the expression ax+by+c is zero on the line, positive for all points on one side and negative for all points on the other side. So:
two points are on the same side of the line if ax+by+c has the same sign at both;
they are on opposite sides if the signs are different.
Write the second as 2x+y+2=0. Then d=5∣−3−2∣=55=5.
5∣3+4k−5∣=2, so ∣4k−2∣=10, giving 4k−2=10 or 4k−2=−10: k=3 or k=−2.
At (2,3): 4−3+1=2>0. At (−1,5): −2−5+1=−6<0. Opposite sides.
At the origin: −4<0. At (1,5): 1+5−4=2>0. No, they are on opposite sides.
Here A(1,3), B(0,0), C(4,3). AB is y=3x, that is, 3x−y=0, and AB=10. The altitude from C is 10∣12−3∣=109, so the area is 21×10×109=29 square units.
For (a,0): 5∣4a−12∣=3, so 4a−12=±15, giving a=427 or a=−43. The points are (427,0) and (−43,0).