The slope formula is determined by rise/run. Our "rise" is y2−y1, and our "run" is x2−x1. Say you wanted to calculate the slope of two points: (x1,y1), and (x2,y2). If you draw a horizontal line that passes (x1,y1) and a vertical line that passes (x2,y2), you will see that it intersects at (x2,y1). The vertical line is our rise.
the distance between (x2,y2) and (x2,y1) Using the distance formula, which is:
Substituting our coordinates into the formula:
Therefore, y2−y1 is our rise. Now for our run. the distance between (x1,y1) and (x2,y1)
D=x2−x1 Our run is x2−x1
Remember that m=rise/run.
m = (y2-y1)/(x2-x1)