topic badge
United States of AmericaVA
Algebra, Functions, and Data Analysis

5.03 Problem-solving with linear functions

Slope-intercept form

As explored in the previous lesson, transformations on f\left(x\right)=x allow us to shift, dilate, and reflect linear functions. We can write the equations of lines in slope-intercept form:

\displaystyle y=mx+b
\bm{m}
slope
\bm{b}
y-intercept

The main advantage of slope-intercept form is that we can easily identify two key features: the slope and the y-intercept directly from the equation.

This form is particularly useful for modeling and solving real-world problems where a situation starts with an initial amount or value (b) and changes at a constant rate (m).

Exploration

A table with 5 rows and 2 columns titled x and f of x. The data is as follows: 0, 2; 1, 3.5; 2, 5; 8, 14, and 15, 24.5.
Table
A line in quadrant one of the coordinate plane. Labeled Depth in inches along the y-axis and Time in hours along the x-axis. The line passes through (0,2), (1,3.5), (2,5), (8,14), (13, 21.5).
Graph
A text saying The initial depth of snow is 2 inches. The snow falls at a rate of 1.5 inches per hour.
Description
An equation. f of x equals 1.5 x plus 2.
Equation
  1. What do the table, description, graph, and equation representations have in common?
  2. What is different about each representation?

Given information about a linear function, we can write the equation in slope-intercept form.

0
1
2
3
4
5
6
7
8
9
x
3
6
9
12
15
18
21
24
27
30
33
36
y

This is a graph of a leaky faucet that drips at a rate of 4 cups per hour. It has already dripped 15 cups of water.

Let x represent the number of hours and y represent the number of cups of water that have leaked from the faucet.

First, identify or solve for the slope (m), which represents the constant rate of change in the situation. In the graph, we can use a slope triangle to see the slope is \dfrac{4}{1}, meaning the water leaks at a rate of 4 cups per hour. This matches the m in y=mx+b.

Next, identify or solve for the y-intercept, which represents the b in y=mx+b.

In the graph, the y-intercept is at (0, 15), which represents the initial value or starting amount. From the context, the initial amount of leaked water is 15 cups, so b=15. This matches the b in y=mx+b.

Lastly, rewrite y=mx+b, substituting the solved values of m and b. Since we have found m = 4 and b=15, we can write the equation:y = 4x+15

Slope-intercept form is especially helpful when we want to graph a linear function. The graph of a line shows all the points (x, y) that make the equation true.

-4
-3
-2
-1
1
2
3
4
x
-4
-3
-2
-1
1
2
3
4
y

\,\\\,Consider the equation y = 2x-1.

First, identify the value of b, and plot this as the y-intercept. Since the y-intercept is -1, plot a point at (0,-1).

Then, identify the value of m, and the value of the rise and the run. From the y-intercept, use the rise and run to create slope triangles to plot additional points.

Each point on the graph is a solution of the equation, so every point satisfies y = 2x-1.

Examples

Example 1

A bathtub has a clogged drain, so it needs to be pumped out. It currently contains 30 gallons of water.

The table of values shows the linear relationship of the amount of water remaining in the tub, y, after x minutes.

\text{Time in minutes } \left(x\right)0123
\text{Water remaining in gallons } \left(y\right)30282624
a

Write the linear equation in slope-intercept form that represents this situation.

Worked Solution
Create a strategy

We can pick two points to calculate the rate of change for the slope. Then, we can recognize that the y-intercept is given in the table of values.

Apply the idea

Find the slope using the values \left(0, 30\right) and \left(1, 28\right):

\displaystyle m\displaystyle =\displaystyle \dfrac{y_2-y_1}{x_2-x_1}Slope formula
\displaystyle m\displaystyle =\displaystyle \dfrac{28-30}{1-0}Substitute \left(x_1,y_1\right)=\left(0,30\right) and \left(x_2,y_2\right)=\left(1,28\right)
\displaystyle m\displaystyle =\displaystyle -2Evaluate

Notice that the initial value, or y-intercept is given in the table as \left(0, 30\right).

Writing in the form y=mx+b, the equation that represents this situation is y=-2x+30.

Reflect and check

If we had not noticed that the y-intercept was given, we could have substituted in any pair of values for x and y, and solved for b.

b

Draw the graph of this linear relationship with a clearly labeled scale. Only show the viable solutions.

Worked Solution
Create a strategy

We cannot have a negative time (x \geq 0) and we should end the graph when the tub is empty (y=0). To plan our graph, we need to find when the tub is empty.

Apply the idea

To find when the tub is empty:

\displaystyle y\displaystyle =\displaystyle -2x+30Original equation
\displaystyle 0\displaystyle =\displaystyle -2x+30Substitute y=0
\displaystyle -30\displaystyle =\displaystyle -2xSubtraction property of equality
\displaystyle 15\displaystyle =\displaystyle xDivision property of equality

This tells us that we have the restriction that 0 \leq x\leq 15 and 0 \leq y\leq 30, which will help us choose the appropriate axes and scale.

5
10
15
\text{Time in minutes}
5
10
15
20
25
30
\text{Water in gallons}

We know that the bathtub begins with 30 gallons which is represented by the y-intercept at (0,30) and that the slope of the linear equation is -2 which means that the tub loses 2 gallons of water every minute until there is no water in the tub at 15 minutes.

5
10
15
\text{Time in minutes}
5
10
15
20
25
30
\text{Water in gallons}
Reflect and check

We can also graph the slope by using the idea of \dfrac{\text{rise}}{\text{run}}.

Since the slope is -2, we can write it as the fraction \dfrac{-2}{1}.

This means the change in y-values (rise) is -2, and the change in x-values (run) is 1.

c

Find the domain and range.

Worked Solution
Create a strategy

The domain of a function represents all possible x-values.

The range of a function represents all possible y-values.

Consider values that may fit the pattern but do not fit the context.

Apply the idea

Domain: 0 \leq x \leq 15

Notice that even though negative x-values could fit the pattern, it does not make sense with the context to have a negative amount of time.

Range: 0 \leq y \leq 30

In the context, water is never added so it can never be above the starting amount of 30 gallons. Continuing the pattern, the y-value will never drop below empty, or 0 gallons.

d

Describe how the graph would change if, instead, there were initially 40 gallons of water in the tub, and it emptied at 2.5 gallons per minute.

Worked Solution
Create a strategy

The initial value is represented by the y-intercept on the graph. The rate of change is represented by the slope of the graph. We should consider how these are changing from the original question.

Apply the idea

The original question had an initial value of 30 gallons, and the new scenario has an initial value of 40 gallons. This means the new y-intercept will be higher on the y-axis.

The original question had a rate of change of -2 as it was decreasing at 2 gallons per minute. The new scenario has a rate of change of -2.5 as it is emptying at 2.5 gallons per minute. This means the slope will be steeper in the new scenario.

We can see this on the graph:

5
10
15
20
\text{Time }\left(x\right)
5
10
15
20
25
30
35
40
\text{Water }\left(y\right)
Reflect and check

Notice that despite starting with 10 extra gallons of water, the tub with 40 gallons of water only takes 1 more minute to empty than the 30-gallon tub, because it is emptying at a faster rate. This is reflected in the graph as a steeper slope. The second function is decreasing at a greater rate than the first.

Example 2

Which of the following has the higher y-intercept?

A
The line with a slope of 4 that crosses the y-axis at (0, 6).
B
The line given by the equation y=x+4.
Worked Solution
Create a strategy

For an equation in the form y=mx+b, the value of b is the y-intercept.

Apply the idea

In option A, the y-intercept is 6.

In option B, the equation is of the form y=mx+b where b=4. So, the y-intercept is 4.

Since 6 \gt 4, option A has the higher y-intercept.

Example 3

A phone company offers a plan that includes a base monthly fee plus a charge per gigabyte (GB) of data used. The plan costs \$40 per month plus \$5 per GB of data. Let x represent the gigabytes of data used and y represent the total monthly cost in dollars.

a

Write a linear equation in slope-intercept form to represent the total monthly cost.

Worked Solution
Create a strategy

Identify the initial value (base fee) which corresponds to the y-intercept (b) and the rate of change (cost per GB) which corresponds to the slope (m). Substitute these into y=mx+b.

Apply the idea

The base monthly fee is \$40. This is the cost even if 0 GB of data are used (x=0). So, the initial value or y-intercept is b=40.

The cost increases by \$5 for each GB of data used. This is the constant rate of change, so the slope is m=5.

Substituting these values into y=mx+b, the equation is:y = 5x + 40

b

Graph the relationship. Assume a maximum of 10 GB of data usage is relevant for this plan. Label the axes and show appropriate scales.

Worked Solution
Create a strategy

The domain is restricted by the context (0 \leq x \leq 10). The range will also be non-negative costs.

Plot the y-intercept at (0, 40). Use the slope m=5 or \dfrac{5}{1}) to find another point, or simply calculate the cost at x=10. Draw a line segment for the relevant domain.

Apply the idea

The y-intercept is at (0, 40).

To find the cost at 10 GB, substitute x=10 into the equation: y = 5(10) + 40 = 50 + 40 = 90. So, another point is (10, 90).

We need axes that accommodate x from 0 to 10 and y from (at least) 40 to 90.

1
2
3
4
5
6
7
8
9
10
\text{Data Used (GB)}
10
20
30
40
50
60
70
80
90
\text{Monthly Cost}
c

What do the slope and y-intercept represent in the context of this phone plan?

Worked Solution
Create a strategy

Relate the mathematical terms "slope" and "y-intercept" back to the specific details given in the problem description (cost per GB, base fee).

Apply the idea

The slope (m=5) represents the cost per gigabyte of data used. For every additional gigabyte of data used, the total monthly cost increases by \$5.

The y-intercept (b=40) represents the base monthly fee. This is the cost for the plan before any data is used (the cost at 0 GB).

d

Using the equation or graph, determine the total cost if a customer uses 7 GB of data.

Worked Solution
Create a strategy

Substitute the given data usage (x=7) into the linear equation y=5x+40 and solve for y. Alternatively, find x=7 on the graph and read the corresponding y-value.

Apply the idea

Using the equation:

\displaystyle y\displaystyle =\displaystyle 5x+40Start with the equation
\displaystyle y\displaystyle =\displaystyle 5(7)+40Substitute x=7
\displaystyle y\displaystyle =\displaystyle 35+40Multiply
\displaystyle y\displaystyle =\displaystyle 75Add

The total cost for using 7 GB of data is \$75. We could also estimate this point (7, 75) on the graph.

Idea summary

The slope-intercept form of a line is:

\displaystyle y=mx+b
\bm{m}
slope
\bm{b}
y-intercept

Slope-intercept form is useful when we know, or want to know the slope of the line and the y-intercept of the line.

This form is commonly used to model real-world linear situations where b represents a starting amount or initial value, and m represents a constant rate of change.

Outcomes

AFDA.AF.1d

Write the equation of a linear, quadratic, or exponential function, given a graph, using transformations of the parent function.

AFDA.AF.1e

Use a graphical or algebraic representation of a function to solve problems within a context, graphically and algebraically, when appropriate.

AFDA.AF.1g

Compare and contrast linear, quadratic, and exponential functions using multiple representations (e.g., graphs, tables, equations, verbal descriptions).

What is Mathspace

About Mathspace