How to find the slope using a graph

Learning Outcomes

  • Given the graph of a line, determine the slope of the line
  • Identify the slope of a horizontal line given it's equation
  • Identify the slope of a vertical line given it's equation


Now we’ll look at some graphs on a coordinate grid to find their slopes. The method will be very similar to what we just modeled on our geoboards.

Doing the Manipulative Mathematics activity "Slope of Lines Between Two Points" will help you develop a better understanding of how to find the slope of a line from its graph.

To find the slope, we must count out the rise and the run. But where do we start?

We locate any two points on the line. We try to choose points with coordinates that are integers to make our calculations easier. We then start with the point on the left and sketch a right triangle, so we can count the rise and run.

example

Find the slope of the line shown:

How to find the slope using a graph
Solution

Locate two points on the graph, choosing points whose coordinates are integers. We will use

(0,−3)\left(0,-3\right)

and

(5,1)\left(5,1\right)

.

Starting with the point on the left,

(0,−3)\left(0,-3\right)

, sketch a right triangle, going from the first point to the second point,

(5,1)\left(5,1\right)

.

How to find the slope using a graph
Count the rise on the vertical leg of the triangle. The rise is

44

units.
Count the run on the horizontal leg. The run is

55

units.
Use the slope formula.

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

Substitute the values of the rise and run.

m=45m=\frac{4}{5}

The slope of the line is

45\frac{4}{5}

.

 

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

try it



 

Find the slope from a graph

  1. Locate two points on the line whose coordinates are integers.
  2. Starting with the point on the left, 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=riserunm=\frac{\text{rise}}{\text{run}}



 

example

Find the slope of the line shown:

How to find the slope using a graph

Show Solution





 

Notice that the slope is negative since the line slants downward from left to right.

What if we had chosen different points? Let’s find the slope of the line again, this time using different points. We will use the points

(−3,7)\left(-3,7\right)

and

(6,1)\left(6,1\right)

.

How to find the slope using a graph
Starting at

(−3,7 )\left(-3,7\right)

, sketch a right triangle to

(6,1)\left(6,1\right)

.

How to find the slope using a graph
Count the rise. The rise is

−6-6

.
Count the run. The run is

99

.
Use the slope formula.

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

Substitute the values of the rise and run.

m=−69m=\frac{-6}{9}

Simplify the fraction.

m=−23m=-\frac{2}{3}

The slope of the line is

−23-\frac{2}{3}

.

It does not matter which points you use—the slope of the line is always the same. The slope of a line is constant!

try it



 

The lines in the previous examples had

yy

-intercepts with integer values, so it was convenient to use the y-intercept as one of the points we used to find the slope. In the next example, the

yy

-intercept is a fraction. The calculations are easier if we use two points with integer coordinates.

example

Find the slope of the line shown:

How to find the slope using a graph

Show Solution





 

try it



Finding the Slope of Horizontal and Vertical Lines

Do you remember what was special about horizontal and vertical lines? Their equations had just one variable.

  • horizontal line

    y=by=b

    ; all the

    yy

    -coordinates are the same.
  • vertical line

    x=ax=a

    ; all the

    xx

    -coordinates are the same.

So how do we find the slope of the horizontal line

y=4?y=4?

One approach would be to graph the horizontal line, find two points on it, and count the rise and the run. Let’s see what happens. We’ll use the two points

(0,4)\left(0,4\right)

and

(3 ,4)\left(3,4\right)

to count the rise and run.

How to find the slope using a graph

What is the rise? The rise is

00

.
What is the run? The run is

33

.
What is the slope?

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

m=03m=\frac{0}{3}

m=0m=0

The slope of the horizontal line

y=4y=4

is

00

.

All horizontal lines have slope

00

. When the

yy

-coordinates are the same, the rise is

00

.

Slope of a Horizontal Line

The slope of a horizontal line,

y=by=b

, is

00

.

 

Now we’ll consider a vertical line, such as the line

x=3x=3

, shown below. We’ll use the two points

(3,0)\left(3,0\right)

and

(3,2) \left(3,2\right)

to count the rise and run.

How to find the slope using a graph

What is the rise? The rise is

22

.
What is the run? The run is

00

.
What is the slope?

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

m=20m=\frac{2}{0}

But we can’t divide by

00

. Division by

00

is undefined. So we say that the slope of the vertical line

x=3x=3

is undefined. The slope of all vertical lines is undefined, because the run is

00

.

Slope of a Vertical Line

The slope of a vertical line,

x=ax=a

, is undefined.

 

example

Find the slope of each line:

1.

x=8x=8


2.

y=−5y=-5


Solution

1.

x= 8x=8


This is a vertical line, so its slope is undefined.

2.

y=−5y=-5


This is a horizontal line, so its slope is

00

.

 

try it



 

Quick Guide to the Slopes of Lines

How to find the slope using a graph

 

Licenses and Attributions

CC licensed content, Specific attribution

  • Prealgebra. Provided by: OpenStax. License: CC BY: Attribution. License terms: Download for free at http://cnx.org/contents/[email protected]

How do you find slope on a graph?

Using the Slope Equation Pick two points on the line and determine their coordinates. Determine the difference in y-coordinates of these two points (rise). Determine the difference in x-coordinates for these two points (run). Divide the difference in y-coordinates by the difference in x-coordinates (rise/run or slope).

What is the formula to find the slope?

Use the slope formula to find the slope of a line given the coordinates of two points on the line. The slope formula is m=(y2-y1)/(x2-x1), or the change in the y values over the change in the x values.