"

19 Slope Basics

Topics Covered[1]

In case you missed something in class, or just want to review a specific topic covered in this Module, here is a list of topics covered:

  1. Defining Slope
  2. Proportional Relationships
  3. Rates of Change
  4. Key Concepts

Introduction

We defined in the last chapter the various ways data can be represented in math: Verbal, numerical/tabular, graphical, algebraic/symbolic. We explored the basics of the graphical representation and some of the tabular in the previous section. Now we expand on that with slope.

Defining Slope[2]

In mathematics, the measure of the rate of change, or steepness, of a line is called the slope of the line.

The concept of slope has many applications in the real world. In construction, the pitch of a roof, the slant of the plumbing pipes, and the steepness of the stairs are all applications of slope. And as you ski or jog down a hill, you definitely experience a slope.

We can assign a numerical value to the slope of a line by finding the ratio of the rise and run. The rise is the amount the vertical distance changes while the run measures the horizontal change, as shown in this illustration. The slope is a rate of change. See picture below.

This figure has a diagram of two arrows. The first arrow is vertical and pointed up and labeled “rise”. The second arrow starts at the end of the first. The second arrow is horizontal and pointed right and labeled “run”.

Slope of a Line

The slope of a line is m = rise \times run.

 

The rise measures the vertical change and the run measures the horizontal change. Creating a ratio out of these values gives us the rate of change of the line.

The image shows four arrows. The first arrow is slanted and pointing up and to the right and is labeled “positive”. The second arrow is slanted and pointing down and to the right and labeled “negative”. The third arrow is horizontal and labeled “zero”. The fourth arrow is vertical and labeled “undefined”.

There are multiple methods to find the slope of a line depending on the type of representation presented.

In the next example, to find the slope of a line, we locate two points on the line whose coordinates are integers. Then we sketch a right triangle where the two points are vertices and one side is horizontal and one side is vertical.

Try it! – Finding the Slope of a Line

Find the slope of the line shown.

This figure shows the graph of a straight line on the x y-coordinate plane. The x-axis runs from negative 1 to 9. The y-axis runs from negative 1 to 7. The line goes through the points (0, 5), (3, 3), and (6, 1).


Solution

Steps Algebraic
Locate two points on the graph whose
coordinates are integers.
(0, 5) and (3, 3)
Starting at (0, 5), sketch a right triangle to
(3, 3) as shown in this graph.
.
Count the rise— since it goes down, it is negative. The rise is −2.
Count the run. The run is 3.
Use the slope formula. m = \frac{\text{rise}}{\text{run}}
Substitute the values of the rise and run. m = −23
Simplify. m = −23
The slope of the line is −23.
So, y decreases by 2 units as x increases by 3 units.

How To:

Find the slope of a line from its graph using m = \frac{\text{rise}}{\text{run}}.

  1. Locate two points on the line whose coordinates are integers.
  2. Starting with one point, sketch a right triangle, going from the first point to the second point.
  3. Count the rise and the run on the legs of the triangle.
  4. Take the ratio of rise to run to find the slope: m = \frac{\text{rise}}{\text{run}}.

 

Try it! – Finding Slope with an Integer y-intercept

Find the slope of the line shown:


The graph shows the x y-coordinate plane. The x-axis runs from -1 to 6. The y-axis runs from -4 to 2. A line passes through the points “ordered pair 5, 1” and “ordered pair 0, -3”.


Solution

Steps Algebraic
Locate two points on the graph, choosing points whose coordinates are integers. (0, −3) and (5, 1)
Starting with the point on the left, (0, −3), sketch a right triangle, going from the first point to the second point, (5, 1). The graph shows the x y-coordinate plane. The x-axis runs from -1 to 6. The y-axis runs from -4 to 2. A line passes through the points “ordered pair 5, 1” and “ordered pair 0, -3”. Two line segments form a triangle with the line. A horizontal line connects “ordered pair 0, 1” and “ordered pair 5,1 ”. A vertical line segment connects “ordered pair 0, -3” and “ordered pair 0, 1”.
Count the rise on the vertical leg of the triangle. The rise is 4 units.
Count the run on the horizontal leg. The run is 5 units.
Use the slope formula. m = \frac{\text{rise}}{\text{run}}
Substitute the values of the rise and run. m = 45
The slope of the line is 45.

Notice that the slope is positive since the line slants upward from left to right.

Try it! – Finding Slope without an Integer y-intercept

Find the slope of the line shown:


The graph shows the x y-coordinate plane. The x-axis runs from 0 to 7. The y-axis runs from 0 to 8. A line passes through the points “ordered pair 2, 3” and “ordered pair 7, 6”.


Solution

Steps Algebraic
Locate two points on the graph whose coordinates are integers. (2, 3) and (7, 6)
Which point is on the left? (2, 3)
Starting at (2, 3), sketch a right angle to (7, 6) as shown below. The graph shows the x y-coordinate plane. The x-axis runs from 0 to 7. The y-axis runs from 0 to 8. Two unlabeled points are drawn at “ordered pair 2, 3” and “ordered pair 7, 6”. A line passes through the points. Two line segments form a triangle with the line. A vertical line connects “ordered pair 2, 3” and “ordered pair 2, 6 ”. It is labeled “rise”. A horizontal line segment connects “ordered pair 2, 6” and “ordered pair 7, 6”. It is labeled “run”.
Count the rise. The rise is 3.
Count the run. The run is 5.
Use the slope formula. m = \frac{\text{rise}}{\text{run}}
Substitute the values of the rise and run. m = 35
The slope of the line is 35.

Some lines are not at an angle but are either completely vertical or horizontal. These are special kinds of slope because the numerical equations will only ever have one variable; either just the x or y.

The Slope of a Horizontal Line

The slope of a horizontal line, y = b, is 0.
The graph shows the x y-coordinate plane. The x-axis runs from -1 to 5. The y-axis runs from -1 to 7. A horizontal line passes through the labeled points “ordered pair 0, 4” and “ordered pair 3, 4”.

Steps Algebraic
What is the rise? The rise is 0
What is the run? The run is 3.
The slop is 0. m = \frac{0}{3} = 0
What is the slope? m = \frac{\text{rise}}{\text{run}}. All horizontal lines have slope 0. When the y-coordinates are the same, the rise is 0.

The Slope of a Vertical Line

The slope of a vertical line, x = a, is undefined.
The graph shows the x y-coordinate plane. Both axes run from -5 to 5. A vertical line passes through the labeled points “ordered pair 3, 2” and “ordered pair 3, 0”.

Steps Algebraic
What is the rise? The rise is 2.
What is the run? The run is 0.
What is the slope? m = \frac{\text{rise}}{\text{run}}
m = 20

All vertical lines have a slope undefined. When the x-coordinates are the same, the rise is undefined. This is because any number minus itself is zero and you cannot divide by 0.

Slope of a Horizontal and Vertical Line

The slope of a horizontal line, y = b, is 0.

The slope of a vertical line, x = a, is undefined.

Try it!

Find the slope of each line:

a. x = 8

b. y = −5.


Solution:

a. x = 8 This is a vertical line. Its slope is undefined.

b. y = −5 This is a horizontal line. It has slope 0.

The Slope from Two Points

Sometimes we’ll need to find the slope of a line between two points when we don’t have a graph to count out the rise and the run. We could plot the points on grid paper, then count out the rise and the run, but as we’ll see, there is a way to find the slope without graphing. Before we get to it, we need to introduce some algebraic notation.

We will use (x1,y1) to identify the first point and (x2,y2) to identify the second point.

Let’s see how the rise and run relate to the coordinates of the two points by taking another look at the slope of the line between the points (2,3) and (7,6), as shown in this graph.The figure shows the graph of a straight line on the x y-coordinate plane. The x-axis runs from negative 1 to 7. The y-axis runs from negative 1 to 7. The line goes through the points (2, 3) and (7, 6). A right triangle is drawn by connecting the three points (2, 3), (2, 6), and (7, 6). The point (2, 3) is labeled (x 1, y 1). The point (7, 6) is labeled (x 2, y 2). The vertical side of the triangle has labels y 2 minus y 1, 6 minus 3, and 3. The horizontal side of the triangle has labels x 2 minus x 1, 7 minus 2, and 5.

Steps Algebraic
Since we have two points, we will use subscript notation. \begin{pmatrix} x_1 & y_1 \\ 2, & 3 \end{pmatrix}\begin{pmatrix} x_2 & y_2 \\ 7, & 6 \end{pmatrix}

m = \displaystyle\frac{\text{rise}}{\text{run}}

On the graph, we counted the rise of 3 and the run of 5 m = \displaystyle\frac{3}{5}
Notice that the rise of 3 can be found by subtracting they-coordinates, 6 and 3, and the run of 5 can be found by subtracting the x-coordinates 7 and 2.
We rewrite the rise and run by putting in the coordinates. m = \displaystyle\frac{6 - 3}{7 - 2}
But 6 isy2,they-coordinate of the second point and 3 isy1,the y-coordinate of the first point. So we can rewrite the slope using subscript notation. m = \displaystyle\frac{y_2 - y_1}{7 - 2}
Also 7 is the x-coordinate of the second point and 2 is the x-coordinate of the first point. So again we rewrite the slope using subscript notation. m = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

Slope Formula (Slope of a line between two points)

The slope of the line between two points (x1,y1) and (x2,y2) is:

m = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

OR

y of the second point minus y of the first point
over
x of the second point minus x of the first point.

Try it! – Finding the Slope of a Line with Two Points 

Use the slope formula to find the slope of the line through the points (−2,−3) and (−7,4).


Solution:

Steps Algebraic
We’ll call (−2, −3) point #1 and (−7, 4) point #2. \begin{pmatrix} x_1 & y_1 \\ -2, & -3 \end{pmatrix}\begin{pmatrix} x_2 & y_2 \\ -7, & 4 \end{pmatrix}
Use the slope formula. m = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}
Substitute the values.

y of the second point minus y of the first point

x of the second point minus x of the first point

m = \displaystyle\frac{4 - (-3)}{-7 - (-2)}
Simplify. m = \displaystyle\frac{7}{-5}
Let’s verify this slope on the graph shown. The figure shows the graph of a straight line on the x y-coordinate plane. The x-axis runs from negative 8 to 2. The y-axis runs from negative 6 to 6. The line goes through the points (negative 7, 4) and (negative 2, negative 3). A right triangle is drawn by connecting the three points (negative 7, 4), (negative 7, negative 3), and (negative 2, negative 3). The vertical side of the triangle is labeled “rise”. The horizontal side of the triangle is labeled “run”.
m = \displaystyle\frac{\text{rise}}{\text{run}}

m = \displaystyle\frac{7}{-5}

m = –\displaystyle\frac{7}{5}

 

 

Proportional Relationships with Slope[3]

Relationships are considered proportional relationships when the ratio between related sets of data values is constant.
To know if a relationship is proportional, look for the following aspects:

  • Algebraic/symbolic representations (or equations) will tell you if they are proportional when you look at their y-intercept or the b.
    • Proportional relationships will not have a y-intercept, or will not have a b value, or the b will be 0.
    • Non-Proportional relationships will have a non-zero y-intercept.
  • Numerical/tabular representations will have the coordinate pair (0, 0) in the table.
    This figure shows the graph of a straight line on the x y-coordinate plane. The x-axis runs from negative 12 to 12. The y-axis runs from negative 12 to 12. The line goes through the points (2, negative 2) and (5, 2).
    On the left is an example of a non-proportional numerical/tabular representation and on the right is an example of a proportional numerical/tabular representation.
  • Graphical representations will show one of the following:
      • Pass through the origin if it is proportional
      • Not pass through the origin if it is non-proportional.
    This figure shows the graph of a straight line on the x y-coordinate plane. The x-axis runs from negative 12 to 12. The y-axis runs from negative 12 to 12. The line goes through the points (2, negative 2) and (5, 2).
    On the left is an example of a non-proportional graphical representation and on the right is an example of a proportional graphical representation.
All proportional relationships are linear but not all linear relationships are proportional.

Rates of Change[4]

A rate of change is a relationship or unit rate that shows how one variable or quantity changes with another. The most common way to investigate rates of change is in numerical or tabular form of data, as demonstrated below.

a table with notated changes in x and y values to determine the rate of change. Column one is Hours spent working with the listed values of 0, 1, 2, 3, 4, 5. Column 2 is batches of cookies made, with values 0, 6, 12, 18, 24, 30. Arrows demonstrate that the change in column 1 is 1 value. And the change in column 2 is a value of 6.
How the values of x change compared to how the values of y change is called the rate of change. From hour 1 to hour 2, 6 batches of cookies were made. From hour 2 to hour 3, 6 more batches were made. This relationship of change is often represented with a ratio where the dependent variable is in the numerator and the independent variable is in the denominator. The rate of change here would be:
An image of the ratio generated by the previous data table.
This ratio may appear similar to what was discussed in the previous section with slope, and that slope is sometimes described as rise over run.
We can assign a numerical value to the slope of a line by finding the ratio of the rise and run. The rise is the amount the vertical distance changes while the run measures the horizontal change. Slope is a rate of change.

The slope of a line, m, represents the vertical change in y over the horizontal change in x. Given two points, (x1,y1) and (x2,y2), the following formula determines the slope of a line containing these points:

m = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

Slope also indicates the direction in which a line slants as well as its steepness.

So rate of change describes how an output quantity changes relative to the change in the input quantity. To find the average rate of change over the specified period of time, we divide the change in the output value by the change in the input value.

Forms of Average rate of change (Slope) = \displaystyle\frac{\text{Change in output}}{\text{Change in input}} .
= \displaystyle\frac{\Delta y}{\Delta x}
= \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

The Greek letter Δ (delta) signifies the change in a quantity; we read the ratio as “delta-y over delta-x” or “the change in y divided by the change in x.”

Try it!

Gasoline costs have experienced some wild fluctuations over the last several decades. The table1 lists the average cost, in dollars, of a gallon of gasoline for the years 2005–2012. The cost of gasoline can be considered as a function of year.

y 2005 2006 2007 2008 2009 2010 2011 2012
 

C(y)

 

2.31 2.62 2.84 3.30 2.41 2.84 3.58 3.68

If we were interested only in how the gasoline prices changed between 2005 and 2012, we could compute that the cost per gallon had increased from $2.31 to $3.68, an increase of $1.37. While this is interesting, it might be more useful to look at how much the price changed per year.

In our example, the gasoline price increased by $1.37 from 2005 to 2012. Over 7 years, the average rate of change was

\displaystyle\frac{\Delta y}{\Delta x} = \frac{\$1.37}{7 \text{years}} ≈ 0.196 dollars per year

On average, the price of gas increased by about 19.6¢ each year.

Other examples of rates of change include:

  • A population of rats increasing by 40 rats per week
  • A car traveling 68 miles per hour (distance traveled changes by 68 miles each hour as time passes)
  • A car driving 27 miles per gallon (distance traveled changes by 27 miles for each gallon)
  • The current through an electrical circuit increasing by 0.125 amperes for every volt of increased voltage
  • The amount of money in a college account decreasing by $4,000 per quarter

Rate of Change

A rate of change describes how an output quantity changes relative to the change in the input quantity. The units on a rate of change are “output units per input units.”

The average rate of change between two input values is the total change of the output values divided by the change in the input values.

\displaystyle\frac{\Delta y}{\Delta x} = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

Given the value of a function at different points, calculate the average rate of change of a function for the interval between two values x1 and x2.

  1. Calculate the difference y2 – y1 = Δy.
  2. Calculate the difference x2 – x1 = Δx.
  3. Find the ratio \displaystyle\frac{\Delta y}{\Delta x}

Try it! – Computing an Average Rate of Change

Using the data in gasoline example above, find the average rate of change of the price of gasoline between 2007 and 2009.

y 2005 2006 2007 2008 2009 2010 2011 2012
 

C(y)

 

2.31 2.62 2.84 3.30 2.41 2.84 3.58 3.68

Solution:

In 2007, the price of gasoline was $2.84. In 2009, the cost was $2.41. The average rate of change is

\displaystyle\frac{\Delta y}{\Delta x} = \frac{f(x_2) - f(x_1)}{x_2 - x_1}

\displaystyle = \frac{\$2.41 - \$2.84}{2009 - 2007}

\displaystyle = \frac{-\$0.43 }{2 \text{years}}

= -$0.22 per year

Analysis

Note that a decrease is expressed by a negative change or “negative increase.” A rate of change is negative when the output decreases as the input increases or when the output increases as the input decreases.

Try it! – Computing Average Rate of Change from a Table

After picking up a friend who lives 10 miles away and leaving on a trip, Anna records her distance from home over time. The values are shown in the table below. Find her average speed over the first 6 hours.

t (hours) D(t) (miles)
0 10
1 55
2 90
3 153
4 214
5 240
6 292
7 300

Solution:

Here, the average speed is the average rate of change. She traveled 282 miles in 6 hours.

\displaystyle\frac{292 - 10}{6 - 0} = \frac{282}{6}

= 47

The average speed is 47 miles per hour.

 

Analysis

Because the speed is not constant, the average speed depends on the interval chosen. For the interval [2,3], the average speed is 63 miles per hour.

Key Concepts

  • Slope of a Line
    • The slope of a line is m = \displaystyle\frac{\text{rise}}{\text{run}} .
    • The rise measures the vertical change and the run measures the horizontal change.

  • How to find the slope of a line from its graph using m = \displaystyle\frac{\text{rise}}{\text{run}}.
    1. Locate two points on the line whose coordinates are integers.
    2. Starting with one point, sketch a right triangle, going from the first point to the second point.
    3. Count the rise and the run on the legs of the triangle.
    4. Take the ratio of rise to run to find the slope: m = \displaystyle\frac{\text{rise}}{\text{run}}.
  • Slope of a line between two points.
    • The slope of the line between two points (x1, y1) and (x2, y2) is:

      m = \displaystyle\frac{y_2 - y_1}{x_2 - x_1}

  1. Access for free at https://openstax.org/books/prealgebra-2e/pages/1-introduction ; Access for free at https://openstax.org/books/introductory-statistics-2e/pages/1-introduction
  2. Section material derived from Openstax Introductory Statistics: The Linear Regression and Correlation-Linear Equations and Prealgebra: Graphs-Understand Slope of a Line
  3. This material was created by Amanda Towry using the Microsoft Word processing program.
  4. This material was created by Amanda Towry using the Microsoft Word processing program. updated Section material derived from Openstax Introductory Statistics: The Linear Regression and Correlation-Linear Equations and Prealgebra: Graphs-Understand Slope of a Line
definition

License

Icon for the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License

NCB 0542 Corequisite Copyright © by Elizabeth Pople is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License, except where otherwise noted.