Home > Geometry > Distance of a point from a line

## Distance of a point from a line

Here what we want is the shortest distance of a point from a line.  This is the perpendicular distance of the point to the line

Steps

1. Find the gradient of the line
2. Find the gradient of the perpendicular to the line (the negative reciprocal)
3. Find the equation of the line that goes through the point and has the perpendicular gradient
4. Find the point of intersection between the original line and the line we have just found
5. Find the distance between the original point and the point just found

### Example

Find the shortest distance between the point $(2,8)\mbox{ and }y=2x+5$

The gradient of the line is 2

The gradient perpendicular to the line is $-\frac{1}{2}$

Using $y-y_1=m(x-x_1)$

So $y-8=-\frac{1}{2} (x-2)\implies y=-\frac{1}{2}x+9$

To find point of intersection let $2x+5=-\frac{1}{2}x+9$

$\implies 4x+10=-x+18$

$\implies x=\frac{8}{5}$

So $y=2\times \frac{8}{5} + 5=\frac{41}{5}$

Distance between the two points is $\sqrt{\left(\frac{2}{5}\right)^2+\left(\frac{1}{5}\right)^2}=\frac{\sqrt{5}}{5}=0.447$