<meta http-equiv="refresh" content="1; url=/nojavascript/"> Linear Equations in Slope-Intercept Form | CK-12 Foundation
You are reading an older version of this FlexBook® textbook: CK-12 Algebra I Go to the latest version.

# 5.1: Linear Equations in Slope-Intercept Form

Created by: CK-12

## Learning Objectives

• Write an equation given slope and $y-$intercept.
• Write an equation given the slope and a point.
• Write an equation given two points.
• Write a linear function in slope-intercept form.
• Solve real-world problems using linear models in slope-intercept form.

## Introduction

We saw in the last chapter that linear graphs and equations are used to describe a variety of real-life situations. In mathematics, we want to find equations that explain a situation as presented in a problem. In this way, we can determine the rule that describes the relationship between the variables in the problem. Knowing the equation or rule is very important since it allows us to find the values for the variables. There are different ways to find an equation that describes the problem. The methods are based on the information you can gather from the problem. In graphing these equations, we will assume that the domain is all real numbers.

## Write an Equation Given Slope and y-intercept

Let’s start by learning how to write an equation in slope–intercept form $y=mx+b$.

$b$ is the $y-$intercept (the value of $y$ when $x=0$. This is the point where the line crosses the $y-$axis).

$m$ is the slope how the quantity $y$ changes with each one unit of $x$.

If you are given the slope and $y-$intercept of a line:

1. Start with the slope–intercept form of the line $y=mx+b$.
2. Substitute the given values of $m$ and $b$ into the equation.

Example 1

a) Write an equation with a $\text{slope} = 4$ and a $y-$intercept $= -3$.

b) Write an equation with a $\text{slope} = -2$ and a $y-$intercept $= 7$.

c) Write an equation with a $\text{slope} = \frac{2}{3}$ and a $y-$intercept $= \frac{4}{5}$.

a) Solution

We are given $m=4$ and $b=-3$. Plug these values into the slope–intercept form $y=mx+b$.

$y = 4x -3$

b) Solution

We are given $m=-2$ and $b=7$. Plug these values into the slope–intercept form $y=mx+b$.

$y = -2x +7$

c) Solution

We are given $m=\frac{2}{3}$ and $b=\frac{4}{5}$. Plug these values into the slope–intercept form $y=mx+b$.

$y = \frac {2}{3}x + \frac {4}{5}$

You can also write an equation in slope-intercept form if you are given the graph of the line.

Example 2

Write the equation of each line in slope–intercept form.

a)

b)

c)

d)

a) The $y-$intercept $= -4$ and the $\text{slope} =-\frac{5}{2}$. Plug these values into the slope–intercept form $y = mx + b$.

Solution

$y = -\frac {5}{2}x - 4$

b) The $y-$intercept $= 2$ and the $\text{slope} =\frac{3}{1}$. Plug these values into the slope–intercept form $y = mx + b$.

Solution

$y = 3x + 2$

c) The $y-$intercept $= 4$ and the $\text{slope} =-\frac{1}{1}$. Plug these values into the slope–intercept form $y = mx + b$.

Solution

$y = -x + 4$

d) The $y-$intercept $= -2$ and the $\text{slope} =\frac{1}{2}$. Plug these values into the slope–intercept form $y = mx + b$.

Solution

$y = \frac{1}{2}x - 2.$

## Write an Equation Given the Slope and a Point

Often, we don’t know the value of the $y-$intercept, but we know the value of $y$ for a non-zero value of $x$. In this case we can still use the slope–intercept form to find the equation of the line.

For example, we are told that the slope of a line is two and that the line passes through the point (1, 4). To find the equation of the line, we start with the slope–intercept form of a line.

$y = mx + b$

Plug in the value of the slope.

We don’t know the value of $b$ but we know that the slope is two, and that point (1, 4) is on this line. Where the $x$ value is one, and the $y$ value is four. We plug this point in the equation and solve for $b$.

$4 & = 2(1)+b\\4 & = 2+b\\ -2 & = -2\\2 &= b$

Therefore the equation of this line is $y = 2x + 2$.

If you are given the slope and a point on the line:

1. Start with the slope–intercept form of the line $y = mx + b$.
2. Plug in the given value of $m$ into the equation.
3. Plug the $x$ and $y$ values of the given point and solve for $b$.
4. Plug the value of $b$ into the equation.

Example 3

Write the equation of the line in slope–intercept form.

a) The slope of the line is 4 and the line contains point (-1, 5).

b) The slope of the line is $-\frac{2}{3}$ and the line contains point (2, -2).

c) The slope of the line is -3 and the line contains point (3, -5).

Solution

a)

$\text{Start with the slopeâ€“intercept form of the line} & & y & = mx + b\\\text{Plug in the slope}. & & y & = 4x + b\\\text{Plug point} \ (-1, 5) \ \text{into the equation}. & & 5&=4(-1)+b \Rightarrow b=9\\\text{Plug the value of} \ b \ \text{into the equation}. & & y & =4x+9$

b)

$\text{Start with the slopeâ€“intercept form of the line} & & y & = mx + b\\\text{Plug in the slope}. & & y & = -\frac{2}{3}x + b\\\text{Plug point} \ (2,-2) \ \text{into the equation}.& & -2 & =-\frac{2}{3}(2)+b \Rightarrow b=-2+\frac{4}{3}=-\frac{2}{3}\\\text{Plug the value of} \ b \ \text{into the equation}.& & y & =-\frac{2}{3}x-\frac{2}{3}$

c)

$\text{Start with the slopeâ€“intercept form of the line} & & y & = mx + b\\\text{Plug in the slope}. & & y & = -3x + b\\\text{Plug point} \ (3,-5) \ \text{into the equation}. & & -5 & =-3(3)+b \Rightarrow b=4\\\text{Plug the value of} \ b \ \text{into the equation}. & & y & =-3x+4$

## Write an Equation Given Two Points

One last case is when we are just given two points on the line and we are asked to write the line of the equation in slope–intercept form.

For example, we are told that the line passes through the points (-2, 3) and (5, 2). To find the equation of the line we start with the slope–intercept form of a line

$y = mx + b$

Since we don’t know the slope, we find it using the slope formula $m=\frac {y_2-y_1}{x_2-x_1}$.

Now substitute the $x_1$ and $x_2$ and the $y_1$ and $y_2$ values into the slope formula to solve for the slope.

$m=\frac {2-3}{5-(-2)}=-\frac{1}{7}$

We plug the value of the slope into the slope–intercept form $y=-\frac {1}{7}x+b$

We don’t know the value of $b$ but we know two points on the line. We can plug either point into the equation and solve for $b$. Let’s use point (-2, 3).

Therefore, the equation of this line is $y=-\frac {1}{7}x+\frac{19}{7}$.

If you are given two points on the line:

1. Start with the slope–intercept form of the line $y = mx + b$
2. Use the two points to find the slope using the slope formula $m=\frac {y_2-y_1}{x_2-x_1}$.
3. Plug the given value of $m$ into the equation.
4. Plug the $x$ and $y$ values of one of the given points into the equation and solve for $b$.
5. Plug the value of $b$ into the equation.
6. Plug the other point into the equation to check the values of $m$ and $b$.

Example 4

Write the equations of each line in slope–intercept form.

a) The line contains the points (3, 2) and (-2, 4).

b) The line contains the points (-4, 1) and (-2, 3).

Solution:

a)

1. Start with the slope–intercept form of the line $y = mx + b$.
2. Find the slope of the line. $m=\frac {y_2-y_1}{x_2-x_1}=\frac {4-2}{-2-3}=-\frac {2}{5}$
3. Plug in the value of the slope. $y=-\frac {2}{5}x+b$
4. Plug point (3, 2) into the equation. $2=-\frac {2}{5}(3)+b\Rightarrow b=2+\frac {6}{5}=\frac{16}{5}$
5. Plug the value of $b$ into the equation. $y=-\frac {2}{5}x+\frac {16}{5}$
6. Plug point (-2, 4) into the equation to check. $4=-\frac {2}{5}(-2)+\frac {16}{5}=\frac {4}{5}+\frac {16}{5}=\frac {20}{5}=4$

b)

1. Start with the slope–intercept form of the line $y = mx + b$.
2. Find the slope of the line. $m=\frac {y_2-y_1}{x_2-x_1}=\frac {3-1}{-2-(-4)}=\frac {2}{2}=1$
3. Plug in the value of the slope. $y = x + b$
4. Plug point (-2, 3) into the equation. $3=-2+b\Rightarrow b=5$
5. Plug the value of $b$ into the equation. $y = x + 5$
6. Plug point (-4, 1) into the equation to check. $1 = -4 + 5 = 1$

## Write a Linear Function in Slope-Intercept Form

Remember that you write a linear function in the form $f(x) = mx+b$. Here $f(x)$ represents the $y$ values of the equation or the graph. So $y = f(x)$ and they are often used interchangeably. Using the functional notation in an equation gives us more information.

For instance, the expression $f(x) = mx+b$ shows clearly that $x$ is the independent variable because you plug in values of $x$ into the function and perform a series of operations on the value of $x$ in order to calculate the values of the dependent variable, $y$.

In this case when you plug $x$ into the function, the function tells you to multiply it by $m$ and then add $b$ to the result. This generates all the values of $y$ you need.

Example 5

Consider the linear function $f(x) = 3x-4$. Find $f(2), f(0)$ and $f(-1)$.

Solution

All the numbers in the parentheses are the values of $x$ that you need to plug into the equation of the function.

When you plug values into a function, it is best to plug in the whole parenthesis, not just the value inside the parenthesis. We often plug expressions into the function instead of numbers, and it is important to keep the expression inside the parenthesis in order to perform the correct order of operations. For example, we want to find $f(2x-1)$ for the same function we used before.

Functional notation is a very compact way of giving information. For example you are told that $f(3)=2$.

To read this information, remember a few things.

The value inside the parentheses is the $x-$value.

The value equal to the function is the dependent value (i.e. the $y-$value for lines).

So, $f(3) = 2$ tells you that $x = 3$ and $y = 2$ or that point (3, 2) is on the line.

We will now use functional notation to write equations of lines in slope–intercept form.

Example 6

Find the equation of the following lines in slope–intercept form

a) $m = -2$ and $f(0)=5$.

b) $m = 3.5$ and $f(-2) = 1$.

c) $f(-1) = 1$ and $f(1) = -1$.

Solution

a) We are told that $m = -2$ and the line contains point (0, 5), so $b = 5$.

Plug the values of $m$ and $b$ into the slope–intercept form $f(x) = mx + b$.

$f(x) = -2x + 5.$

b) We are told that $m = 3.5$ and line contains point (-2, 1).

$\text{Start with slopeâ€“intercept form}. & & f(x) & = mx + b\\\text{Plug in the value of the slope}. & & f(x) & = 3.5x + b\\\text{Plug in the point} \ (-2, 1). & & 1 & =3.5(-2)+\Rightarrow b=1+7=8\\\text{Plug the value of} \ b \ \text{in the equation}.& & f(x) & = 3.5x + 8$

c) We are told that the line contains the points (-1, 1) and (1, -1).

$\text{Start with slopeâ€“intercept form}. & & f(x) & = mx + b\\\text{Find the slope}.& & m &= \frac {-1-1}{1-(-1)} =\frac {-2}{2} = -1\\\text{Plug in the value of the slope}.& & f(x) & = -1x + b\\\text{Plug in the point} & & (-1, 1). 1 & =-1(-1)+b\Rightarrow b=0\\\text{Plug the value of} \ b \ \text{in the equation}.& & f(x) & = -x$

## Solve Real-World Problems Using Linear Models in Slope-Intercept Form

Let’s apply the methods we just learned to a few application problems that can be modeled using a linear relationship.

Example 7

Nadia has $200 in her savings account. She gets a job that pays$7.50 per hour and she deposits all her earnings in her savings account. Write the equation describing this problem in slope–intercept form. How many hours would Nadia need to work to have $500 in her account? Let’s define our variables $y =$ amount of money in Nadia’s savings account $x =$ number of hours You can see that the problem gives us the $y-$intercept and the slope of the equation. We are told that Nadia has$200 in her savings account, so $b = 200$.

We are told that Nadia has a job that pays $7.50 per hour, so $m = 7.50$. If we plug these values in the slope–intercept form $y = mx + b$ we obtain $y=7.5x+200$. To answer the question, we plug in $y = 500$ and solve for $x$. $500=7.5x+200\Rightarrow 7.5x=300\Rightarrow x=40 \ hours$. Solution Nadia must work 40 hours if she is to have$500 in her account.

Example 8

A stalk of bamboo of the family Phyllostachys nigra grows at steady rate of 12 inches per day and achieves its full height of 720 inches in 60 days. Write the equation describing this problem in slope–intercept form.

How tall is the bamboo 12 days after it started growing?

Let’s define our variables

$y =$ the height of the bamboo plant in inches

$x =$ number of days

You can see that the problem gives us the slope of the equation and a point on the line.

We are told that the bamboo grows at a rate of 12 inches per day, so $m= 12$.

We are told that the plant grows to 720 inches in 60 days, so we have the point (60, 720).

$\text{Start with the slopeâ€“intercept form of the line} & & y & = mx + b\\\text{Plug in the slope}.& & y & = 12x + b\\\text{Plug in point} \ (60, 720). & & 720 & =12(60)+ b \Rightarrow b=0\\\text{Plug the value of} \ b \ \text{back into the equation}. & & y & = 12x$

To answer the question, plug in $x = 12$ to obtain $y= 12(12) = 144 \ inches$.

Solution

The bamboo is 144 inches (12 feet!) tall 12 days after it started growing.

Example 9

Petra is testing a bungee cord. She ties one end of the bungee cord to the top of a bridge and to the other end she ties different weights and measures how far the bungee stretches. She finds that for a weight of 100 lb, the bungee stretches to 265 feet and for a weight of 120 lb, the bungee stretches to 275 feet. Physics tells us that in a certain range of values, including the ones given here, the amount of stretch is a linear function of the weight. Write the equation describing this problem in slope–intercept form. What should we expect the stretched length of the cord to be for a weight of 150 lbs?

Let’s define our variables

$y =$ the stretched length of the bungee cord in feet in feet

$x =$ the weight attached to the bungee cord in pounds

You can see that the problem gives us two points on the line.

We are told that for a weight of 100 lbs the cord stretches to 265 feet, so we have point (100, 265).

We are told that for a weight of 200 lbs the cord stretches to 275 feet, so we have point (120, 270).

$\text{Start with the slopeâ€“intercept form of the line} & & y & = mx + b\\\text{Find the slope of the line}.& & m & =\frac {y_2-y_1}{x_2-x_1}=\frac {270-265}{120-100}=\frac {5}{20}=\frac {1}{4}\\\text{Plug in the value of the slope}.& & y & =\frac {1}{4}x+b\\\text{Plug point} \ (100, 265) \ \text{into the equation}. & & 265 & =\frac {1}{4}(100)+b\Rightarrow b=265-25=240\\\text{Plug the value of} \ b \ \text{into the equation}. & & y & =\frac {1}{4}x+240$

To answer the question, we plug in $x = 150$. $y=\frac {1}{4}(150)+240\Rightarrow y=37.5+240=277.5 \ feet$

Solution

For a weight of 150 lbs we expect the stretched length of the cord to be 277.5 feet.

## Lesson Summary

• The equation of a line in slope-intercept form is $y = mx + b$.

Where $m$ is the slope and $(0, b)$ is the $y-$intercept).

• If you are given the slope and $y-$intercept of a line:
1. Simply plug $m$ and $b$ into the equation.
• If you are given the slope and a point on the line:
1. Plug in the given value of $m$ into the equation.
2. Plug the $x$ and $y$ values of the given point and solve for $b$.
3. Plug the value of $b$ into the equation.
• If you are given two points on the line:
1. Use the two points to find the slope using the slope formula $m=\frac {y_2-y_1}{x_2-x_1}$.
2. Plug the value of $m$ into the equation.
3. Plug the $x$ and $y$ values of one of the given points and solve for $b$.
4. Plug the value of $b$ into the equation.
5. Plug the other point into the equation to check the values of $m$ and $b$.

## Review Questions

Find the equation of the line in slope–intercept form.

1. The line has slope of 7 and $y-$intercept of -2.
2. The line has slope of -5 and $y-$intercept of 6.
3. The line has slope of $-\frac{1}{4}$ and contains point (4, -1).
4. The line has slope of $\frac{2}{3}$ and contains point $\left ( \frac{1}{2},1 \right )$.
5. The line has slope of -1 and contains point $\left ( \frac{4}{5},0 \right)$.
6. The line contains points (2, 6) and (5, 0).
7. The line contains points (5, -2) and (8, 4).
8. The line contains points (3, 5) and (-3, 0).
9. The line contains points (10, 15) and (12, 20).

Write the equation of each line in slope-intercept form.

Find the equation of the linear function in slope–intercept form.

1. $m = 5, f(0) = -3$
2. $m = -7, f(2) = -1$
3. $m= \frac{1}{3}, f(-1) = \frac{2}{3}$
4. $m = 4.2, f(-3) = 7.1$
5. $f\left( \frac{1}{4} \right )=\frac {3}{4}, f(0)=\frac {5}{4}$
6. $f(1.5) = -3, f(-1) = 2$
7. To buy a car, Andrew puts a down payment of $1500 and pays$350 per month in installments. Write an equation describing this problem in slope-intercept form. How much money has Andrew paid at the end of one year?
8. Anne transplants a rose seedling in her garden. She wants to track the growth of the rose so she measures its height every week. On the third week, she finds that the rose is 10 inches tall and on the eleventh week she finds that the rose is 14 inches tall. Assuming the rose grows linearly with time, write an equation describing this problem in slope-intercept form. What was the height of the rose when Anne planted it?
9. Ravi hangs from a giant spring whose length is 5 m. When his child Nimi hangs from the spring its length is 2 m. Ravi weighs 160 lbs. and Nimi weighs 40 lbs. Write the equation for this problem in slope-intercept form. What should we expect the length of the spring to be when his wife Amardeep, who weighs 140 lbs., hangs from it?

1. $y = 7x- 2$
2. $y = -5x + 6$
3. $y =-\frac{1}{4}x$
4. $y = \frac{2}{3}x + \frac{2}{3}$
5. $y = -1x + \frac{4}{5}$
6. $y = -2x + 10$
7. $y = 2x-12$
8. $y = \frac{5}{6}x + \frac{5}{2}$
9. $y = \frac{5}{2}x- 10$
10. $y = -x + 3$
11. $y= 4x- 6$
12. $f(x)= 5x- 3$
13. $f(x) = -7x + 13$
14. $f(x) = \frac{1}{3}x + 1$
15. $f(x) = 4.2x + 19.7$
16. $f(x) = -2x + \frac{5}{4}$
17. $f(x)= -2x$
18. $y = 350x + 1500; y = \5700$
19. $y = 0.5x + 8.5; y= 8.5 \ inches$
20. $y = .025x + 1$ or $y =\frac{1}{40}x + 1; y = 4.5 \ m$

Feb 22, 2012

Sep 17, 2014