What is the relation of this line $y = ax +b$ with the points $(x_1, y_1), (x_2, y_2)$

64 Views Asked by At

I have a two points with coordinates $(x_1, y_1), (x_2, y_2)$

I am given a line

$y = ax +b$

where $a = \dfrac{y_2-y_1}{x_2-x_1}$, $b = \dfrac{y_1x_2 - y_2x_1}{x_2-x_1}$

I wish to know the relationship between this line and the two points.

Right now it looks to me that $y$ is a line that passes through the two points. I recognize $a$ as the slope of the line. However, I can't see the importance of having the offset $b$ to be that number.

Can someone see how $b$ was calculated?

2

There are 2 best solutions below

0
On BEST ANSWER

Line $y=ax+b$ through points $(x_1,y_1)$ and $(x_2,y_2)$ satisfies $y_1=ax_1+b$ and $y_2=ax_2+b$. Then, from $a = (y_1-b)/x_1 = (y_2-b)/x_1$ follows the value for $b$ as given in the question.

0
On

The points $(x_1,y_1)$ and $(x_2,y_2)$ are on the line $y=ax+b$, because $$ax_1+b= \dfrac{y_2-y_1}{x_2-x_1}x_1+ \dfrac{y_1x_2 - y_2x_1}{x_2-x_1}=\dfrac{y_2x_1-y_1x_1+y_1x_2-y_2x_1}{x_2-x_1}=\dfrac{y_1x_2-y_1x_1}{x_2-x_1}=y_1,$$ and similarly $ax_2+b=y_2$.

$b$ could be computed from

$y_2-ax_2=y_2-\dfrac{y_2-y_1}{x_2-x_1}x_2=\dfrac{y_2x_2-y_2x_1-y_2x_2+y_1x_2}{x_2-x_1}=\dfrac{y_1x_2-y_2x_1}{x_2-x_1},$

and similarly $y_1-ax_1=\dfrac{y_1x_2-y_2x_1}{x_2-x_1}.$