# How is y=mx+c derived?

I understand what the coefficients represent. I just can't figure out how Rene Descartes would have derived this straight line equation.

• What do the coefficients represent? For surely a constant gradient can only describe a line. Its intercept rules out parallel lines. I suspect there is a gap in your knowledge about what gradient is. – Karl Feb 24 '17 at 18:51
• You're correct. I'm having a hard time grasping the concept of straight line graphs. I'm trying to familiarise myself with them by trying to understand various aspects of the line itself. I confess, my understanding of gradients and x,y intercepts is still very low. – user401747 Feb 24 '17 at 18:54
• The gradient is the change in $y$ per unit change in $x$ whilst the $y$ intercept is the value of $y$ when $x=0$ the form you have displays these values in a convenient way. Note though that $x+y-3=0$ is a perfectly good line but the gradient and intercept are not so obvious. – Karl Feb 24 '17 at 19:07
• I think I'm beginning to understand this. Thanks a lot Karl! :) – user401747 Feb 25 '17 at 0:31

Think in terms of motion. You are at point A and you want to go in a straight line towards point B. Set up your rectangular coordinate system as convenient. You have to move a certain amount East (the "run", call it a) and a certain amount North (the "rise", call it b). To go the shortest distance and keep in a straight line, you want to move a proportional amount of each direction with each step you take. So for example you travel half the run, you should travel half the rise at the same time; a tenth of the run with a tenth of the rise; and so on.

If you list the coordinates of A as $(x_1, y_1)$ then starting at time $t = 0$ with t in fractions of a time unit (say parts of an hour), your position at any time $t$ should be $(x_1 + ta, y_1 + tb)$. Assuming you get to point B in exactly one hour, you get to B = $(x_1 + a, y_1 + b) = (x_2, y_2)$ which is correct, following the original assumption that run = $x_2 - x_1 = a$ and rise = $y_2 - y_1 = b$

(Note: when you learn about vectors and lines in 3D, this is exactly how they are calculated, with a point of origin A and a direction vector $(a,b)$ plus a parameter $t$ which it is often helpful to think of as time.)

If you draw a diagram of this and mark your position at a few different points between A and B, then draw a horizontal line along A and a vertical line through B and another vertical line through each point you noted, you see you have several similar triangles. For any point $(x,y)$ on the line, the "rise" $y-y_1$ over the "run" $x - x_1$ is equal to the total rise over total run (It has to be, since we said we are going to work proportionally) = $b/a$.

Then for convenience we name the fraction $b/a$ = slope. This is called $m$ in most US texts, $a$ in our local texts in Quebec, whatever letter your local books choose.

This gives us the formula $\frac{y - y_1}{x - x_1} = m$

Note -- very important -- that $(x,y)$ is ANY general point, moving up and down the line, a variable. The subscripts are quite different. $(x_1, y_1)$ is a fixed point, our given initial point A. A lot of beginners get muddled on this so take some time to get it clear.

We multiply the above equation by the denominator and get

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

There is one of the standard forms of the line, developed through a simple idea of proportionality and our knowledge of motion in space.

• excellent answer. – nits.kk Jul 16 '17 at 1:35

If you're familiar with the other forms of straight line equations (two point and point-slope) you should realize that this form, slope-intercept, is just a case of point-slope, whose point is the y intercept. Converting from two point to point-slope is simple: the slope is the rise (difference in y values of the points) over the run (diff x values). The point for point slope is either of the 2 point points.