We've updated our
Privacy Policy effective December 15. Please read our updated Privacy Policy and tap

Study Guides > Intermediate Algebra

Calculate and Interpret Slope

Learning Outcomes

  • Define slope for a linear function
  • Calculate slope given two points
One well known form for writing linear functions is known as slope-intercept form, where xx is the input value, mm is the rate of change or slope, and bb is the initial value of the dependant variable.

Equation formy=mx+bFunction notationf(x)=mx+b\begin{array}{cc}\text{Equation form}\hfill & y=mx+b\hfill \\ \text{Function notation}\hfill & f\left(x\right)=mx+b\hfill \end{array}

We often need to calculate the slope given input and output values. Given two values for the input, x1{x}_{1} and x2{x}_{2}, and two corresponding values for the output, y1{y}_{1} and y2{y}_{2} —which can be represented by a set of points, (x1y1)\left({x}_{1}\text{, }{y}_{1}\right) and (x2y2)\left({x}_{2}\text{, }{y}_{2}\right)—we can calculate the slope mm, as follows

m=change in output (rise)change in input (run)=ΔyΔx=y2y1x2x1m=\dfrac{\text{change in output (rise)}}{\text{change in input (run)}}=\dfrac{\Delta y}{\Delta x}=\dfrac{{y}_{2}-{y}_{1}}{{x}_{2}-{x}_{1}}

where Δy\Delta y is the vertical displacement and Δx\Delta x is the horizontal displacement. Note in function notation two corresponding values for the output y1{y}_{1} and y2{y}_{2} for the function ff are y1=f(x1){y}_{1}=f\left({x}_{1}\right) and y2=f(x2){y}_{2}=f\left({x}_{2}\right), so we could equivalently write

m=f(x2)f(x1)x2x1m=\dfrac{f\left({x}_{2}\right)-f\left({x}_{1}\right)}{{x}_{2}-{x}_{1}}

The graph below indicates how the slope of the line between the points, (x1,y1)\left({x}_{1,}{y}_{1}\right) and (x2,y2)\left({x}_{2,}{y}_{2}\right) is calculated. Recall that the slope measures steepness. The greater the absolute value of the slope, the steeper the line is. Graph depicting how to calculate the slope of a line The slope of a function is calculated by the change in yy divided by the change in xx. It does not matter which coordinate is used as the (x2, y2)\left({x}_{2,\text{ }}{y}_{2}\right) and which is the (x1, y1)\left({x}_{1},\text{ }{y}_{1}\right), as long as each calculation is started with the elements from the same coordinate pair. The units for slope are always units for the outputunits for the input\dfrac{\text{units for the output}}{\text{units for the input}}. Think of the units as the change of output value for each unit of change in input value. An example of slope could be miles per hour or dollars per day. Notice the units appear as a ratio of units for the output per units for the input.

Calculating Slope

The slope, or rate of change, of a function mm can be calculated using the following formula: m=change in output (rise)change in input (run)=ΔyΔx=y2y1x2x1m=\dfrac{\text{change in output (rise)}}{\text{change in input (run)}}=\dfrac{\Delta y}{\Delta x}=\dfrac{{y}_{2}-{y}_{1}}{{x}_{2}-{x}_{1}} where x1{x}_{1} and x2{x}_{2} are input values, y1{y}_{1} and y2{y}_{2} are output values.
When the slope of a linear function is positive, the line is moving in an uphill direction from left to right across the coordinate axes. This is also called an increasing linear function. Likewise, a decreasing linear function is one whose slope is negative. The graph of a decreasing linear function is a line moving in a downhill direction from left to right across the coordinate axes. In mathematical terms, For a linear function f(x)=mx+bf(x)=mx+b, if m>0m>0, then f(x)f(x) is an increasing function. For a linear function f(x)=mx+bf(x)=mx+b, if m<0m<0, then f(x)f(x) is a decreasing function. For a linear function f(x)=mx+bf(x)=mx+b, if m=0m=0, then f(x)f(x) is a constant function. Sometimes we say this is neither increasing nor decreasing. In the following example, we will first find the slope of a linear function through two points then determine whether the line is increasing, decreasing, or neither.

Example

If f(x)f\left(x\right) is a linear function and (3,2)\left(3,-2\right) and (8,1)\left(8,1\right) are points on the line, find the slope. Is this function increasing or decreasing?

Answer: The coordinate pairs are (3,2)\left(3,-2\right) and (8,1)\left(8,1\right). To find the rate of change, we divide the change in output by the change in input.

m=change in outputchange in input=1(2)83=35m=\dfrac{\text{change in output}}{\text{change in input}}=\dfrac{1-\left(-2\right)}{8 - 3}=\dfrac{3}{5}

We could also write the slope as m=0.6m=0.6. The function is increasing because m>0m>0. As noted earlier, the order in which we write the points does not matter when we compute the slope of the line as long as the first output value, or y-coordinate, used corresponds with the first input value, or x-coordinate, used.

In the following video we show examples of how to find the slope of a line passing through two points and then determine whether the line is increasing, decreasing or neither. https://youtu.be/in3NTcx11I8

Example

The population of a city increased from 23,40023,400 to 27,80027,800 between 20082008 and 20122012. Find the change of population per year if we assume the change was constant from 20082008 to 20122012.

Answer: The rate of change relates the change in population to the change in time. The population increased by 27,80023,400=440027,800-23,400=4400 people over the four-year time interval. To find the rate of change, divide the change in the number of people by the number of years.

4,400 people4 years=1,100 peopleyear\dfrac{4,400\text{ people}}{4\text{ years}}=1,100\text{ }\dfrac{\text{people}}{\text{year}}

So the population increased by 1,1001,100 people per year. Because we are told that the population increased, we would expect the slope to be positive. This positive slope we calculated is therefore reasonable.

In the next video, we show an example where we determine the increase in cost for producing solar panels given two data points. https://youtu.be/4RbniDgEGE4 The following video provides an example of how to write a function that will give the cost in dollars for a given number of credit hours taken, x. https://youtu.be/X3Sx2TxH-J0

Licenses & Attributions