# How do you use the method of linear interpolation to approximate values and create an equation of a line?

Mar 22, 2015

Let's say you have two points: $\left(x , y\right)$ co-ordinates.

An equation of the line will be of the form $y = m \cdot x + b$
where $m =$ the slope and $b =$ the so-called $y -$intercept.

Example :
Let's take $\left(- 6 , 0\right)$ and $\left(4 , 5\right)$
graph{0.5x+3 [-9.61, 12.89, -2.795, 8.455]}
Then first we determine the slope $m$
Difference in $y = \Delta y = 5 - 0 = 5$
Difference in $x = \Delta x = 4 - \left(- 6\right) = 10$
To find the slope we divide $\frac{\Delta y}{\Delta x} = \frac{5}{10} = \frac{1}{2}$

We fill this in in one of the points to get $b$

$y = m x + b \to 0 = \frac{1}{2} \cdot \left(- 6\right) + b \to b = + 3$

So the equation goes $y = \frac{1}{2} \cdot x + 3$
And you can fill in any $x$ to get the $y$

Check (allways check!) with the other point $\left(4 , 5\right)$:
$\frac{1}{2} \cdot 4 + 3 = 5$ is OK