3.12 Linear Functions and Applications of Linear Functions

Learning Objectives

In this section you will:

• Represent a linear function.
• Write and interpret an equation for a linear function.
• Model real-world problems with linear functions.
• Build linear models from verbal descriptions.
• Model a set of data with a linear function.

Just as with the growth of a bamboo plant, there are many situations that involve constant change over time. Consider, for example, the first commercial maglev train in the world, the Shanghai MagLev Train Figure 3.12.1. It carries passengers comfortably for a 30-kilometer trip from the airport to the subway station in only eight minutes[1] .

Suppose a maglev train travels a long distance, and maintains a constant speed of 83 meters per second for a period of time once it is 250 meters from the station. How can we analyze the train’s distance from the station as a function of time? In this section, we will investigate a kind of function that is useful for this purpose, and use it to investigate real-world situations such as the train’s distance from the station at a given point in time.

Representing Linear Functions

The function describing the train’s motion is a linear function, which is defined as a function with a constant rate of change. This is a polynomial of degree $1$. There are several ways to represent a linear function, including word form, function notation, tabular form, and graphical form. We will describe the train’s motion as a function using each method.

Representing a Linear Function in Word Form

Let’s begin by describing the linear function in words. For the train problem, we just considered, the following word sentence may be used to describe the function relationship.

• The train’s distance from the station is a function of the time during which the train moves at a constant speed plus its original distance from the station when it began moving at constant speed.

The speed is the rate of change. Recall that a rate of change is a measure of how quickly the dependent variable changes with respect to the independent variable. The rate of change for this example is constant, which means that it is the same for each input value. As the time (input) increases by 1 second, the corresponding distance (output) increases by $83$ meters. The train began moving at this constant speed at a distance of $250$ meters from the station.

Representing a Linear Function in Function Notation

Another approach to representing linear functions is by using function notation. One example of function notation is an equation written in the slope-intercept form of a line, where $x$ is the input value, $m$ is the rate of change, and $b$ is the initial value of the dependent variable.

Equation form                      $y=mx+b$
Function notation                $f(x)=mx+b$

In the example of the train, we might use the notation $D$ where the total distance $D$ is a function of the time $t$. The rate, $m$, is $83$ meters per second. The initial value of the dependent variable $b$ is the original distance from the station, $250$ meters. We can write a generalized equation to represent the motion of the train.

$D=83t+250$.

Representing a Linear Function in Tabular Form

A third method of representing a linear function is through the use of a table. The relationship between the distance from the station and the time is represented in Figure 3.12.2. From the table, we can see that the distance changes by $83$ meters for every $1$ second increase in time.

Can the input in the previous example be any real number?

No. The input represents time so while nonnegative rational and irrational numbers are possible, negative real numbers are not possible for this example. The input consists of non-negative real numbers.

Representing a Linear Function in Graphical Form

Another way to represent linear functions is visually, using a graph. We can use the function relationship from above, $D(t)=83t+250$, to draw a graph as represented in Figure 3.12.3 Notice the graph is a line. When we plot a linear function, the graph is always a line.

The rate of change, which is constant, determines the slant, or slope of the line. The point at which the input value is zero is the vertical intercept, or $y$-intercept, of the line. We can see from the graph that the $y$-intercept in the train example we just saw is $(0,250)$ and represents the distance of the train from the station when it began moving at a constant speed.

Notice that the graph of the train example is restricted, but this is not always the case. Consider the graph of the line $f(x)=2x+1$.

Ask yourself what numbers can be input to the function. In other words, what is the domain of the function? The domain is comprised of all real numbers because any number may be doubled, and then have one added to the product.

Linear Function

A linear function is a function whose graph is a line. Linear functions can be written in the slope-intercept form of a line

$f(x)=mx+b$

where $b$ is the initial or starting value of the function (when input, $x=0$), and $m$, is the constant rate of change, or slope of the function. The $y$-intercept is at $(0,b)$.

Example 3.12.1.

Using a Linear Function to Find the Pressure on a Diver

The pressure, $P$ in pounds per square inch (PSI) on the diver in Figure 3.12.4 depends upon her depth below the water surface, $d$ in feet. This relationship may be modelled by the equation, $P(d)=0.434d+14.696$. Restate this function in words.

Solution

To restate the function in words, we need to describe each part of the equation. The pressure as a function of depth equals four hundred thirty-four thousandths times depth plus fourteen and six hundred ninety-six thousandths.

Analysis

The initial value, $14.696$, is the pressure in PSI on the diver at a depth of $0$ feet, which is the surface of the water. The rate of change, or slope, is $0.434$ PSI per foot. This tells us that the pressure on the diver increases $0.434$ PSI for each foot her depth increases.

Modelling Real-World Problems with Linear Functions

In the real world, problems are not always explicitly stated in terms of a function or represented with a graph. Fortunately, we can analyze the problem by first representing it as a linear function and then interpreting the components of the function. As long as we know, or can figure out, the initial value and the rate of change of a linear function, we can solve many different kinds of real-world problems.

HOW TO

Given a linear function $f$ and the initial value and rate of change, evaluate $f$ .

1. Determine the initial value and the rate of change (slope).
2. Substitute the values into $f(x)=mx+b$.
3. Evaluate the function at $x=c$.

Example 3.12.2

Using a Linear Function to Determine the Number of Songs in a Music Collection

Marcus currently has $200$ songs in his music collection. Every month, he adds $15$ new songs. Write a formula for the number of songs, $N$ in his collection as a function of time, $t$ the number of months. How many songs will he own at the end of one year?

Solution

The initial value for this function is $200$ because he currently owns $200$ songs, so $N(0)=200$, which means that $b=200$.

The number of songs increases by $15$ songs per month, so the rate of change is $15$ songs per month. Therefore we know that $m=15$. We can substitute the initial value and the rate of change into the slope-intercept form of a line.

We can write the formula $N(t)=15t+200$.

With this formula, we can then predict how many songs Marcus will have at the end of one year ($12$ months). In other words, we can evaluate the function at, $t=12$.

$\begin{eqnarray*} \mbox{N(12)} & = & 15(12)+200 \\ \\ \ & = & 180+200 \\ \\ \ & = & 380 \end{eqnarray*}$

Marcus will have $380$ songs in $12$ months.

Analysis

Notice that $N$ is an increasing linear function. As the input (the number of months) increases, the output (number of songs) increases as well.

Example 3.12.3

Using a Linear Function to Calculate Salary Based on Commission

Working as an insurance salesperson, Ilya earns a base salary plus a commission on each new policy. Therefore, Ilya’s weekly income depends on the number of new policies, $n$ he sells during the week. Last week he sold $3$ new policies, and earned $\760$ for the week. The week before, he sold $5$ new policies and earned $\920$. Find an equation for $I$ and interpret the meaning of the components of the equation.

Solution

The given information gives us two input-output pairs: $(3,\760)$ and $(5,\920)$ We start by finding the rate of change.

$\begin{eqnarray*} \mbox{m} &=& \frac{\920-\760}{5-3} \\ \\ \ & = & \frac{\160}{2\;policies} \\ \\ \ &=&80 {\;per\;policy} \end{eqnarray*}$

Keeping track of units can help us interpret this quantity. Income increased by $\160$ when the number of policies increased by $2$, so the rate of change is $\80$ per policy. Therefore, Ilya earns a commission of $\80$ for each policy sold during the week.

We can then solve for the initial value.

\begin{align*}\text{I(n)}&=80n+b\\\\760&=80(3)+b\;\text{when n=3, I(3)=760}\\\\760-80(3)&=b\\\\520&=b\end{align*}

The value of $b$ is the starting value for the function and represents Ilya’s income when $n=0$ or when no new policies are sold. We can interpret this as Ilya’s base salary for the week, which does not depend upon the number of policies sold.

We can now write the final equation.

$I =80n+520$

Our final interpretation is that Ilya’s base salary is $\520$ per week and he earns an additional $\80$ commission for each policy sold.

Example 3.12.4

Using Tabular Form to Write an Equation for a Linear Function

Below table relates the number of rats in a population to time, in weeks. Use the table to write a linear equation.

 number of weeks, $w$ number of rats, $P(w)$ $0$ $2$ $4$ $6$ $1000$ $1080$ $1160$ $1240$
Solution

We can see from the table that the initial value for the number of rats is $1000$, so $b=1000$.

Rather than solving for $m$ we can tell from looking at the table that the population increases by $80$ for every $2$ weeks that pass. This means that the rate of change is $80$ rats per $2$ weeks, which can be simplified to $40$ rats per week.

$P(w)=40w+1000$

If we did not notice the rate of change from the table we could still solve for the slope using any two points from the table. For example, using $(2, 1080)$ and $(6, 1240)$

$\begin{eqnarray*} \mbox{m} & = & \frac{1240-1080}{6-2} \\ \\ \ & = & \frac{160}{4} \\ \\ \ & = & 40 \end{eqnarray*}$

Is the initial value always provided in a table of values like Example 3.12.4?

No. Sometimes the initial value is provided in a table of values, but sometimes it is not. If you see an input of $0$, then the initial value would be the corresponding output. If the initial value is not provided because there is no value of input on the table equal to $0$, find the slope, substitute one coordinate pair and the slope into $f(x)=mx+b$ and solve for $b$.

Try It

1) A new plant food was introduced to a young tree to test its effect on the height of the tree. The table shows the height of the tree, in feet, $x$ months since the measurements began. Write a linear function, $H(x)$, where $x$ is the number of months since the start of the experiment.

 $x$ $H(x)$ $0$ $2$ $4$ $8$ $12$ $12.5$ $13.5$ $14.5$ $16.5$ $18.5$
Solution

$H(x)=0.5x+12.5$

Building Linear Models from Verbal Descriptions

When building linear models to solve problems involving quantities with a constant rate of change, we typically follow the same problem strategies that we would use for any type of function. Let’s briefly review them:

1. Identify changing quantities, and then define descriptive variables to represent those quantities. When appropriate, sketch a picture or define a coordinate system.
2. Carefully read the problem to identify important information. Look for information that provides values for the variables or values for parts of the functional model, such as slope and initial value.
3. Carefully read the problem to determine what we are trying to find, identify, solve, or interpret.
4. Identify a solution pathway from the provided information to what we are trying to find. Often this will involve checking and tracking units, building a table, or even finding a formula for the function being used to model the problem.
5. When needed, write a formula for the function.
6. Solve or evaluate the function using the formula.
7. Reflect on whether your answer is reasonable for the given situation and whether it makes sense mathematically.
8. Clearly convey your result using appropriate units, and answer in full sentences when necessary.

Now let’s take a look at the student in Seattle. In her situation, there are two changing quantities: time and money. The amount of money she has remaining while on vacation depends on how long she stays. We can use this information to define our variables, including units.

Output: $M$, money remaining in dollars.
Input: $t$, time in weeks.

So, the amount of money remaining depends on the number of weeks: $M(t)$.

We can also identify the initial value and the rate of change.
Initial Value: She saved $\3,500$, so $\3,500$ is the initial value for $M$.
Rate of Change: She anticipates spending $\400$ each week, so $\400$ per week is the rate of change, or slope.

Notice that the unit of dollars per week matches the unit of our output variable divided by our input variable. Also, because the slope is negative, the linear function is decreasing. This should make sense because she is spending money each week.

The rate of change is constant, so we can start with the linear model $M(t)=mt+b$. Then we can substitute the intercept and slope provided.

To find the $x$intercept, we set the output to zero, and solve for the input.

$\begin{eqnarray*} \mbox{0} & = & -400t+3500 \\ \\ \ {t}& = & \frac{3500}{400} \\ \\ \ & = & 8.75 \end{eqnarray*}$

The $x$-intercept is $8.75$ weeks. Because this represents the input value when the output will be zero, we could say that Emily will have no money left after $8.75$ weeks.

When modelling any real-life scenario with functions, there is typically a limited domain over which that model will be valid—almost no trend continues indefinitely. Here the domain refers to the number of weeks. In this case, it doesn’t make sense to talk about input values less than zero. A negative input value could refer to a number of weeks before she saved $\3,500$, but the scenario discussed poses the question once she saved $\3,500$ because this is when her trip and subsequent spending starts. It is also likely that this model is not valid after the $x$-intercept, unless Emily uses a credit card and goes into debt. The domain represents the set of input values, so the reasonable domain for this function is $0\leq t\leq8.75$

In this example, we were given a written description of the situation. We followed the steps of modelling a problem to analyze the information. However, the information provided may not always be the same. Sometimes we might be provided with an intercept. Other times we might be provided with an output value. We must be careful to analyze the information we are given, and use it appropriately to build a linear model.

Using a Given Intercept to Build a Model

Some real-world problems provide the $y$-intercept, which is the constant or initial value. Once the $y$-intercept is known, the $x$-intercept can be calculated. Suppose, for example, that Hannah plans to pay off a no-interest loan from her parents. Her loan balance is $\1,000$. She plans to pay $\250$ per month until her balance is $\0$. The $y$-intercept is the initial amount of her debt, or $\1,000$. The rate of change, or slope, is $-\250$ per month. We can then use the slope-intercept form and the given information to develop a linear model.

$\begin{eqnarray*} \mbox{f(x)} & = & {mx + b} \\ \\ \ & = & -250x+1000 \end{eqnarray*}$

Now we can set the function equal to $0$, and solve for $x$ to find the $x$-intercept.
$\begin{eqnarray*} \mbox{0} & = & {-250x + 1000} \\ \\ \ 1000 & = & 250x \\ \\ \ 4 & = & x \\ \\ \ x & = & 4\end{eqnarray*}$

The $x$-intercept is the number of months it takes her to reach a balance of $\0$. The $x$-intercept is $4$ months, so it will take Hannah four months to pay off her loan.

Using a Given Input and Output to Build a Model

Many real-world applications are not as direct as the ones we just considered. Instead they require us to identify some aspect of a linear function. We might sometimes instead be asked to evaluate the linear model at a given input or set the equation of the linear model equal to a specified output.

HOW TO

Given a word problem that includes two pairs of input and output values, use the linear function to solve a problem.

1. Identify the input and output values.
2. Convert the data to two coordinate pairs.
3. Find the slope.
4. Write the linear model.
5. Use the model to make a prediction by evaluating the function at a given $x$-value.
6. Use the model to identify an $x$-value that results in a given $y$-value.

Example 3.12.5

Using a Linear Model to Investigate a Town’s Population

A town’s population has been growing linearly. In 2004, the population was 6,200. By 2009, the population had grown to 8,100. Assume this trend continues.

1. Predict the population in 2013.
2. Identify the year in which the population will reach 15,000.
Solution

The two changing quantities are the population size and time. While we could use the actual year value as the input quantity, doing so tends to lead to very cumbersome equations because the $y$-intercept would correspond to the year 0, more than 2000 years ago!

To make computation a little nicer, we will define our input as the number of years since 2004.

Input: $t$, years since 2004

Output: $P(t)$, the town’s population
To predict the population in 2013 $t = 9$, we would first need an equation for the population. Likewise, to find when the population would reach 15,000, we would need to solve for the input that would provide an output of 15,000. To write an equation, we need the initial value and the rate of change, or slope.

To determine the rate of change, we will use the change in output per change in input.

$m=\frac{change\hspace{0.15cm}in\hspace{0.15cm}output}{change\hspace{0.15cm}in\hspace{0.15cm}input}$

The problem gives us two input-output pairs. Converting them to match our defined variables, the year 2004 would correspond to $t=0$ giving the point $(0,6200)$. Notice that through our clever choice of variable definition, we have “given” ourselves the $y$-intercept of the function. The year 2009 would correspond to, $t=5$ giving the point $(5,8100)$.

The two coordinate pairs are $(0,6200)$ and $(5,8100)$. Recall that we encountered examples in which we were provided two points earlier in the chapter. We can use these values to calculate the slope.

$\begin{eqnarray*}\mbox{m}&=&\frac{8100-6200}{5-0}\\\\&=&\frac{1900}{5}\\\\&=&380\end{eqnarray*}$

We already know the $y$-intercept of the line, so we can immediately write the equation:

$P(t)=380t+6200$

To predict the population in 2013, we evaluate our function at, $t=9$.

$\begin{eqnarray*}\mbox{P(9)}&=&380(9)+6,200\\\\&=& 9,620\end{eqnarray*}$

if the trend continues, our model predicts a population of 9,620 in 2013.

To find when the population will reach 15,000, we can set

$\begin{eqnarray*}\text{P(t)}&=&15000\\\\150000&=&380t+6200\\\\8800&=&380t\\\\&\approx&23.158\end{eqnarray*}$

Our model predicts the population will reach 15,000 in a little more than 23 years after 2004, or somewhere around the year 2027.

Try It

2) A company sells doughnuts. They incur a fixed cost of $25,000 for rent, insurance, and other expenses. It costs$0.25 to produce each doughnut.

a. Write a linear model to represent the cost $C$ of the company as a function of $x$, the number of doughnuts produced.
b. Find and interpret the $y$-intercept.

Solution

a. $C(x)=0.25x+25,000$
b. The $y$-intercept is $(0,25,000)$. If the company does not produce a single doughnut, they still incur a cost of 25,000.

3) A city’s population has been growing linearly. In 2008, the population was 28,200. By 2012, the population was 36,800. Assume this trend continues.

a. Predict the population in 2014.
b. Identify the year in which the population will reach 54,000.

Solution

a. 41,100
b. 2020

Key Concepts

• Linear functions can be represented in words, function notation, tabular form, and graphical form.
• The equation for a linear function can be written if the slope $m$ and initial value $b$ are known.
• A linear function can be used to solve real-world problems given information in different forms.
• We can use the same problem strategies that we would use for any type of function.
• When modelling and solving a problem, identify the variables and look for key values, including the slope and $y$-intercept.
• Draw a diagram, where appropriate.
• Check for reasonableness of the answer.
• Linear models may be built by identifying or calculating the slope and using the $y$-intercept.
• The $x$-intercept may be found by setting, $y=0$, which is setting the expression $mx+b$ equal to $0$.
• The point of intersection of a system of linear equations is the point where the $x$– and $y$-values are the same.
• A graph of the system may be used to identify the points where one line falls below (or above) the other line.

Self Check

After completing the exercises, use this checklist to evaluate your mastery of the objectives of this section.

Overall, after looking at the checklist, do you think you are well-prepared for the next section? Why or why not?

Glossary

decreasing linear function
a function with a negative slope: If $f(x)=mx+b$,  $m<0$.
increasing linear function
a function with a positive slope: If $f(x)=mx+b$,  $m>0$.
linear function
a function with a constant rate of change that is a polynomial of degree 1, and whose graph is a straight line

definition