CoReq to Introductory Statistics, 2/eXYZ Homework Edition

6.6 Finding the Equation of a Line

Finding the Equation of a Line

How do online retailers know that ‘you may also like’ a particular item based on something you just ordered? How can economists know how a rise in the minimum wage will affect the unemployment rate? How do medical researchers create drugs to target cancer cells? How can traffic engineers predict the effect on your commuting time of an increase or decrease in gas prices? It’s all mathematics.

You are at an exciting point in your mathematical journey as the mathematics you are studying has interesting applications in the real world.

The physical sciences, social sciences, and the business world are full of situations that can be modeled with linear equations relating two variables. Data is collected and graphed. If the data points appear to form a straight line, an equation of that line can be used to predict the value of one variable based on the value of the other variable.

To create a mathematical model of a linear relation between two variables, we must be able to find the equation of the line. In this section we will look at several ways to write the equation of a line. The specific method we use will be determined by what information we are given.

Find an Equation of the Line Given the Slope and y-Intercept

We can easily determine the slope and intercept of a line if the equation was written in slope–intercept form, y=mx+b. Now, we will do the reverse—we will start with the slope and y-intercept and use them to find the equation of the line.

Sometimes, the slope and intercept need to be determined from the graph.

Find an Equation of the Line Given Two Points

When real-world data is collected, a linear model can be created from two data points. In the next example we’ll see how to find an equation of a line when just two points are given.

We have two options so far for finding an equation of a line: slope–intercept or point–slope. Since we will know two points, it will make more sense to use the point–slope form.

But then we need the slope. Can we find the slope with just two points? Yes. Then, once we have the slope, we can use it and one of the given points to find the equation.

We have seen that we can use either the slope–intercept form or the point–slope form to find an equation of a line. Which form we use will depend on the information we are given. This is summarized in Table 6.17.

Practice Makes Perfect

Find an Equation of the Line Given the Slope and y-Intercept

In the following exercises, find the equation of a line with given slope and y-intercept. Write the equation in slope–intercept form.

  1. slope 3 and y-intercept (0,5)

  2. slope 4 and y-intercept (0,1)

    Show solution to exercise 2

    y=4x+1

  3. slope 6 and y-intercept (0,−4)

  4. slope 8 and y-intercept (0,−6)

    Show solution to exercise 4

    y=8x−6

  5. slope −1 and y-intercept (0,3)

  6. slope −1 and y-intercept (0,7)

    Show solution to exercise 6

    y=−x+7

  7. slope −2 and y-intercept (0,−3)

  8. slope −3 and y-intercept (0,−1)

    Show solution to exercise 8

    y=−3x−1

  9. slope 35 and y-intercept (0,−1)

  10. slope 15 and y-intercept (0,−5)

    Show solution to exercise 10

    y=15x−5

  11. slope −34 and y-intercept (0,−2)

  12. slope −23 and y-intercept (0,−3)

    Show solution to exercise 12

    y=−23x−3

  13. slope 0 and y-intercept (0,−1)

  14. slope 0 and y-intercept (0,2)

    Show solution to exercise 14

    y=2

  15. slope −3 and y-intercept (0,0)

  16. slope −4 and y-intercept (0,0)

    Show solution to exercise 16

    y=−4x

In the following exercises, find the equation of the line shown in each graph. Write the equation in slope–intercept form.

  1. A line passes through the y-intercept (0, -5) and marked point (1, -2); its x-intercept is (5/3, 0). Labeled ticks run from -6 to 6 on both axes.
  2. A descending line passes through (0, 4) and the marked x-intercept (2, 0). Labeled ticks run from -6 to 6 on both axes.
    Show solution to exercise 18

    y=−2x+4

  3. An ascending line passes through (0, -3) and the marked x-intercept (6, 0). Labeled ticks run from -8 to 8 on both axes.
  4. An ascending line passes through (0, 2) and marked point (4, 5); its x-intercept is (-8/3, 0). Labeled ticks run from -6 to 6 on both axes.
    Show solution to exercise 20

    y=34x+2

  5. A descending line passes through the y-intercept (0, 3) and marked point (3, -1); its x-intercept is (9/4, 0). Labeled ticks run from -6 to 6 on both axes.
  6. A descending line passes through (0, -1) and marked point (2, -4); its x-intercept is (-2/3, 0). Labeled ticks run from -6 to 6 on both axes.
    Show solution to exercise 22

    y=−32x−1

  7. A horizontal line y = -2 passes through the marked point (2, -2). Labeled ticks run from -6 to 6 on both axes.
  8. A horizontal line y = 6 passes through the marked point (-3, 6). Labeled ticks run from -8 to 8 on both axes.
    Show solution to exercise 24

    y=6

Find an Equation of the Line Given Two Points

In the following exercises, find the equation of a line containing the given points. Write the equation in slope–intercept form when possible. For a vertical line, give its equation in the form x = a and explain why slope–intercept form is not possible.

  1. (2,6) and (5,3)

  2. (3,1) and (2,5)

    Show solution to exercise 26

    y=−4x+13

  3. (4,3) and (8,1)

  4. (2,7) and (3,8)

    Show solution to exercise 28

    y=x+5

  5. (−3,−4) and (5,−2)

  6. (−5,−3) and (4,−6)

    Show solution to exercise 30

    y=−13x−143

  7. (−1,3) and (−6,−7)

  8. (−2,8) and (−4,−6)

    Show solution to exercise 32

    y=7x+22

  9. (6,−4) and (−2,5)

  10. (3,−2) and (−4,4)

    Show solution to exercise 34

    y=−67x+47

  11. (0,4) and (2,−3)

  12. (0,−2) and (−5,−3)

    Show solution to exercise 36

    y=15x−2

  13. (7,2) and (7,−2)

  14. (4,2) and (4,−3)

    Show solution to exercise 38

    x=4

  15. (−7,−1) and (−7,−4)

  16. (−2,1) and (−2,−4)

    Show solution to exercise 40

    x=−2

  17. (6,1) and (0,1)

  18. (6,2) and (−3,2)

    Show solution to exercise 42

    y=2

  19. (3,−4) and (5,−4)

  20. (−6,−3) and (−1,−3)

    Show solution to exercise 44

    y=−3

  21. (4,3) and (8,0)

  22. (0,0) and (1,4)

    Show solution to exercise 46

    y=4x

  23. (−2,−3) and (−5,−6)

  24. (−3,0) and (−7,−2)

    Show solution to exercise 48

    y=12x+32

  25. (8,−1) and (8,−5)

  26. (3,5) and (−7,5)

    Show solution to exercise 50

    y=5

Adapted from OpenStax, Rice University; access for free at openstax.org. Lessons 2.4 and 6.7 are written for this edition by XYZ Homework. License: CC BY-NC-SA 4.0. Copyright and sources.

⇩ Download ▾

These eBooks are a prerelease and are not yet certified conformant with WCAG 2.1 AA or any other accessibility standard. Every page is built against an automated accessibility gate, and our target for the published editions is WCAG 2.2 Level AA. If something is unusable, please tell us.