New Zealand
Level 6 - NCEA Level 1

# The Two Point Formula

Lesson

So far we have three different forms of an equation for a straight line.

Equation of Lines!

We have:

$y=mx+b$y=mx+b  (gradient-intercept form)

$ax+by+c=0$ax+by+c=0   (general form)

$y-y_1=m\left(x-x_1\right)$yy1=m(xx1)   (point-gradient formula)

What if the information given is two points on the line?

We have a couple of options.

#### Option 1: We could use this information and construct an equation in point gradient form.

##### Example 1 - with numbers

Find the equation of the line that passes through the points A$\left(-3,6\right)$(3,6) and B$\left(5,-10\right)$(5,10).

As we have been developing good mathematical practice, the first thing to do here is to quickly sketch the two points on a plane so we can visually see the line we are finding the equation for.  This helps to check if our line will have positive or negative gradient and to refer back to when we have our final equation.

We need to find the gradient of the line, so I will use the gradient formula:

 $m$m $=$= $\frac{y_2-y_1}{x_2-x_1}$y2​−y1​x2​−x1​​ $m$m $=$= $\frac{-10-6}{5-\left(-3\right)}$−10−65−(−3)​ $m$m $=$= $\frac{-16}{8}$−168​ $m$m $=$= $-2$−2

$m=-2$m=2  (negative as we suspected from our sketch!)

Now we can use the point gradient formula. Since both given points lie on the line, we can choose to use whichever point we like.

Let's use $\left(-3,6\right)$(3,6) and the gradient we found, $m=-2$m=2.

 $y-y_1$y−y1​ $=$= $m\left(x-x_1\right)$m(x−x1​) $y-6$y−6 $=$= $-2\left(x-\left(-3\right)\right)$−2(x−(−3)) $y-6$y−6 $=$= $-2\left(x+3\right)$−2(x+3) $y-6$y−6 $=$= $-2x-6$−2x−6 $y$y $=$= $-2x$−2x

#### Option 2: We could substitute the values of both points into the two point formula.

##### Two point formula

Think of the basic idea behind a straight line: pick any two points on the line and the gradient between them will always be the same.

So say we want to find the equation of a line that passes through

A$\left(-3,6\right)$(3,6), (which will be our $\left(x_1,y_1\right)$(x1,y1) ), and

B$\left(5,-10\right)$(5,10), (which will be our $\left(x_2,y_2\right)$(x2,y2) ).

Let C$\left(x,y\right)$(x,y) represent any point on the line.

Then the gradient between point A and B will be equal to the gradient between point A and C. Let's express this mathematically:

 $\text{Gradient of interval AB }$Gradient of interval AB $=$= $\frac{y_2-y_1}{x_2-x_1}$y2​−y1​x2​−x1​​ $=$= $\frac{-10-6}{5-\left(-3\right)}$−10−65−(−3)​ AND $\text{Gradient of interval AC }$Gradient of interval AC $=$= $\frac{y-y_1}{x-x_1}$y−y1​x−x1​​ $=$= $\frac{y-6}{x-\left(-3\right)}$y−6x−(−3)​

Equating the gradients, we get:

 $\frac{y-y_1}{x-x_1}$y−y1​x−x1​​ $=$= $\frac{y_2-y_1}{x_2-x_1}$y2​−y1​x2​−x1​​ (THE TWO POINT FORMULA) $\frac{y-6}{x-\left(-3\right)}$y−6x−(−3)​ $=$= $\frac{-10-6}{5-\left(-3\right)}$−10−65−(−3)​ $\frac{y-6}{x-\left(-3\right)}$y−6x−(−3)​ $=$= $\frac{-16}{8}$−168​ $\frac{y-6}{x-\left(-3\right)}$y−6x−(−3)​ $=$= $-2$−2 $y-6$y−6 $=$= $-2\left(x+3\right)$−2(x+3) $y-6$y−6 $=$= $-2x-6$−2x−6 $y$y $=$= $-2x$−2x

Two Point Formula

We call this the two point formula, but it is really just the process of finding the gradient first and then using the point gradient formula.

$\frac{y-y_1}{x-x_1}=\frac{y_2-y_1}{x_2-x_1}$yy1xx1=y2y1x2x1

## Deriving the two point formula algebraically

Find the equation of a line that passes through the points P$\left(x_1,y_1\right)$(x1,y1) and Q$\left(x_2,y_2\right)$(x2,y2).

Let's work through the same steps as we did in example 1, first by finding the gradient and then using the point gradient formula.

Gradient of the line:

$m=\frac{y_2-y_1}{x_2-x_1}$m=y2y1x2x1

Substituting into the point-gradient formula:

$y-y_1=m\left(x-x_1\right)$yy1=m(xx1)

$y-y_1=\frac{y_2-y_1}{x_2-x_1}\left(x-x_1\right)$yy1=y2y1x2x1(xx1)

This is the process you would use to find the gradient for any straight line if you are just given two points.

Find gradient first, then use point gradient formula.

With one more manipulation (divide both sides by $x-x_1$xx1) we can change

$y-y_1=\frac{y_2-y_1}{x_2-x_1}\left(x-x_1\right)$yy1=y2y1x2x1(xx1)

into

$\frac{y-y_1}{x-x_1}=\frac{y_2-y_1}{x_2-x_1}$yy1xx1=y2y1x2x1 and we call this the two point formula.

##### Example 2

Find the equation of the line that goes through $\left(-5,2\right)$(5,2) and $\left(-4,-3\right)$(4,3).

Think: We can use the two point formula: $\frac{y-y_1}{x-x_1}=\frac{y_2-y_1}{x_2-x_1}$yy1xx1=y2y1x2x1. Let $\left(x_1,y_1\right)$(x1,y1) be $\left(-5,2\right)$(5,2), and let $\left(x_2,y_2\right)$(x2,y2) be $\left(-4,-3\right)$(4,3).

Do: Substitute the values into the formula:

 $\frac{y-y_1}{x-x_1}$y−y1​x−x1​​ $=$= $\frac{y_2-y_1}{x_2-x_1}$y2​−y1​x2​−x1​​ $\frac{y-2}{x-\left(-5\right)}$y−2x−(−5)​ $=$= $\frac{-3-2}{-4-\left(-5\right)}$−3−2−4−(−5)​ $\frac{y-2}{x+5}$y−2x+5​ $=$= $\frac{-5}{1}$−51​ $\frac{y-2}{x+5}$y−2x+5​ $=$= $-5$−5 Make $y$y the subject: $y-2$y−2 $=$= $-5\left(x+5\right)$−5(x+5) $y-2$y−2 $=$= $-5x-25$−5x−25 $y$y $=$= $-5x-23$−5x−23

Exercise: Switch the points you call $\left(x_1,y_1\right)$(x1,y1) and $\left(x_2,y_2\right)$(x2,y2) in any of the above examples. You should get exactly the same equation.

##### Example 3

A line $L$L passes through $A$A$\left(-7,-1\right)$(7,1) and $B$B$\left(-9,-4\right)$(9,4).

1. Find the equation of line $L$L in general form.

2. Sketch the line on the number plane below.

3. Solve for the $x$x-intercept of the line.

4. Solve for the $y$y-intercept of the line.

### Outcomes

#### NA6-7

Relate graphs, tables, and equations to linear, quadratic, and simple exponential relationships found in number and spatial patterns

#### 91028

Investigate relationships between tables, equations and graphs