## Coordinate Geometry

**The Distance Between two Points**

**The Midpoint of a Line Joining Two Points**

The midpoint of the line joining the points (x_{1}, y_{1}) and (x_{2}, y_{2}) is:

- [½(x
_{1}+ x_{2}), ½(y_{1}+ y_{2})]

**Example**

Find the coordinates of the midpoint of the line joining (1, 2) and (3, 1).

Midpoint = [½(3 + 1), ½(2 + 1)] = __(2, 1.5)__

**The Gradient of a Line Joining Two Points**

**Parallel and Perpendicular Lines**

If two lines are parallel, then they have the same gradient.

If two lines are perpendicular, then the product of the gradients of the two lines is -1.

**Example**

a) y = 2x + 1

b) y = -½ x + 2

c) ½y = x - 3

The gradients of the lines are 2, -½ and 2 respectively. Therefore (a) and (b) and perpendicular, (b) and (c) are perpendicular and (a) and (c) are parallel.

**The Equation of a Line Using One Point and the Gradient**

The equation of a line which has gradient m and which passes through the point (x_{1}, y_{1}) is:

- y - y
_{1}= m(x - x_{1})

**Example**

Find the equation of the line with gradient 2 passing through (1, 4).

y - 4 = 2(x - 1)

y - 4 = 2x - 2__y = 2x + 2__

Since m = __y _{2} - y_{1}__

x

_{2}- x

_{1}

The equation of a line passing through (x_{1}, y_{1}) and (x_{2}, y_{2}) can be written as:__y - y _{1}__ =

__y__

_{2}- y_{1}x - x

_{1}x

_{2}- x

_{1}