4.2 Modeling with Linear Functions
Learning Objectives
In this section, you will:
- Build linear models from verbal descriptions.
- Model a set of data with a linear function.

Elan is a college student who plans to spend a summer in Seattle. Elan has saved $3,500 for their trip and anticipates spending $400 each week on rent, food, and activities. How can we write a linear model to represent this situation? What would be the x-intercept, and what can Elan learn from it? To answer these and related questions, we can create a model using a linear function. Models such as this one can be extremely useful for analyzing relationships and making predictions based on those relationships. In this section, we will explore examples of linear function models.
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:
- Identify changing quantities, and then define descriptive variables to represent those quantities. When appropriate, sketch a picture or define a coordinate system.
- 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.
- Carefully read the problem to determine what we are trying to find, identify, solve, or interpret.
- 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.
- When needed, write a formula for the function.
- Solve or evaluate the function using the formula.
- Reflect on whether your answer is reasonable for the given situation and whether it makes sense mathematically.
- 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 Elan’s situation, there are two changing quantities: time and money. The amount of money they have remaining while on vacation depends on how long they stay. We can use this information to define our variables, including units.
[latex]\begin{array}{l} \text{Output}: \ M, \ \text{money remaining, in dollars} \\ \text{Input:} \ t, \ \text{time, in weeks} \end{array}[/latex]
So, the amount of money remaining depends on the number of weeks: [latex]M(t).[/latex]
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 [latex]M.[/latex]
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 [latex]M(t)=mt+b.[/latex] Then we can substitute the intercept and slope provided.
To find the t-intercept (horizontal axis intercept), we set the output to zero, and solve for the input.
[latex]\begin{array}{ll} 0 &=& -400t+3500 \\ t &=& \frac{3500}{400} \\ &=& 8.75 \end{array}[/latex]
The t-intercept (horizontal axis intercept) is 8.75 weeks. Because this represents the input value when the output will be zero, we could say that Elan will have no money left after 8.75 weeks.
When modeling 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 Elan saved $3,500, but the scenario discussed poses the question once they saved $3,500 because this is when the trip and subsequent spending starts. It is also likely that this model is not valid after the t-intercept (horizontal axis intercept), unless Elan uses a credit card and goes into debt. The domain represents the set of input values, so the reasonable domain for this function is [latex]0\le t\le 8.75.[/latex]
In this example, we were given a written description of the situation. We followed the steps of modeling 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 vertical axis intercept, which is the constant or initial value. Once the vertical axis intercept is known, the t-intercept (horizontal axis 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.
[latex] \begin{array}{ll} f(x) &=& mx+b \\ &=& -250x+1000 \end{array}[/latex]
Now we can set the function equal to 0, and solve for [latex]x[/latex] to find the x-intercept.
[latex]\begin{array}{ll} 0 &=& -250x+1000 \\ 1000 &=& 250x \\ 4 &=& x \\ x &=& 4 \end{array}[/latex]
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.
- Identify the input and output values.
- Convert the data to two coordinate pairs.
- Find the slope.
- Write the linear model.
- Use the model to make a prediction by evaluating the function at a given x-value.
- Use the model to identify an x-value that results in a given y-value.
- Answer the question posed.
Example 1: Using a Linear Model to Investigate a Town’s Population
The population of Lakewood, CO has been growing linearly. In April 2010, the population was 142,980. By 2020, the population had grown to 155,984. Assuming this trend continues,
(a) Predict the population of Lakewood in 2026.
(b) Identify the year in which the population will reach 200,000.
Solution (click to expand)
The two changing quantities are 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 the computation a little nicer, we will define our input as the number of years since 2010.
Input: [latex]t,[/latex] years since 2010
Output: [latex]P(t),[/latex] population of Lakewood
To predict the population in 2026 [latex](t=16),[/latex] we would first need an equation for the population. Likewise, to find out when the population would reach 200,000, we would need to solve for the input which would provide an output of 200,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.
[latex]m=\frac{\text{change in output}}{\text{change in input}}[/latex]
The problem gives us two input-output pairs. Converting them to match our defined variables, the year 2010 would correspond to [latex]t=0,[/latex] giving the point [latex](0, 142,980).[/latex] Notice that through our clever choice of variable definition, we have “given” ourselves the y-intercept of the function. The year 2020 would correspond to [latex]t=10,[/latex] giving the point [latex](10, 155,984).[/latex] The two coordinate pairs are [latex](0, 142,980)[/latex] and [latex](10, 155,984).[/latex] 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.
[latex] \begin{array}{lll} m &=& \frac{155,984-142,980}{10-0} \\ &=& \frac{13,004}{10} \\ &=& 1300.4 &\approx& 1300 \ \text{people per year} \end{array}[/latex]
We already know the y-intercept of the line, so we can immediately write the equation:
[latex]P(t)=1300t+142,980[/latex]
To predict the population in 2026, we evaluate our function at [latex]t=16.[/latex]
[latex]\begin{array}{ll} P(16) &=& 1300(16)+142,980 \\ &=& 16,000+142,980 \\ &=& 163,780 \end{array}[/latex]
If the trend continues, our model predicts a population of 163,780 in the year 2026.
To find when the population will reach 200,000, we can set [latex]P(t)=200,000[/latex] and solve for [latex]t.[/latex]
[latex]\begin{array}{ll} 200,000 &=& 1300t+142,980 \\ 57,020 &=& 1300t \\ t &\approx& 43.86 \end{array}[/latex]
Our model predicts that the population will reach 200,000 in a little more than 43 years after 2010, or somewhere around the year 2053
Try It #1
El Paisa Panaderia, a Mexican bakery in Aurora, CO, 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 [latex]C[/latex] of the company as a function of [latex]x,[/latex] the number of doughnuts produced.
(b) Find and interpret the y-intercept.
Try It #2
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.
Using a Diagram to Build a Model
It is useful for many real-world applications to draw a picture to gain a sense of how the variables representing the input and output may be used to answer a question. To draw the picture, first consider what the problem is asking for. Then, determine the input and the output. The diagram should relate the variables. Often, geometrical shapes or figures are drawn. Distances are often traced out. If a right triangle is sketched, the Pythagorean Theorem relates the sides. If a rectangle is sketched, labeling width and height is helpful.
Modeling a Set of Data with Linear Functions
Real-world situations including two or more linear functions may be modeled with a system of linear equations. Remember, when solving a system of linear equations, we are looking for points the two lines have in common. Typically, there are three types of answers possible, as shown in Figure 2.

How To
Given a situation that represents a system of linear equations, write the system of equations and identify the solution.
- Identify the input and output of each linear model.
- Identify the slope and y-intercept of each linear model.
- Find the solution by setting the two linear functions equal to another and solving for [latex]x,[/latex] or find the point of intersection on a graph.
Example 2: Building a System of Linear Models to Choose a Truck Rental Company
Jamal is choosing between two truck-rental companies. The first, Keep on Trucking, Inc., charges an up-front fee of $20, then 59 cents a mile. The second, Move It Your Way, charges an up-front fee of $16, then 63 cents a mile[1]. When will Keep on Trucking, Inc. be the better choice for Jamal?
Solution (click to expand)
The two important quantities in this problem are the cost and the number of miles driven. Because we have two companies to consider, we will define two functions in Table 1.
Input | [latex]d,[/latex] distance driven in miles |
Output | [latex]K(d):[/latex] cost, in dollars, for renting from Keep on Trucking
[latex]M(d):[/latex] cost, in dollars, for renting from Move It Your Way |
Initial Value | Up-front fee: [latex]K(0)=20[/latex] and [latex]M(0)=16[/latex] |
Rate of Change | [latex]K(d)=\$0.59/\text{mile}[/latex] and [latex]M(d)=\$0.63/\text{mile}[/latex] |
A linear function is of the form [latex]f(x)=mx+b.[/latex] Using the rates of change and initial charges, we can write the equations
[latex]\begin{array}{ll} K(d) &=& 0.59d+20 \\ M(d) &=& 0.63d+16 \end{array}[/latex]
Using these equations, we can determine when Keep on Trucking, Inc., will be the better choice. Because all we have to make that decision from is the costs, we are looking for when Move It Your Way, will cost less, or when [latex]K(d)< M(d).[/latex] The solution pathway will lead us to find the equations for the two functions, find the intersection, and then see where the [latex]K(d)[/latex] function is smaller.
These graphs are sketched in Figure 3, with [latex]K(d)[/latex] in blue.
To find the intersection, we set the equations equal and solve:
[latex]\begin{array}{ll} K(d) &=& M(d) \\ 0.59d+20 &=& 0.63d+16 \\ 4 &=& 0.04d \\ 100 &=& d \\ d&=& 100 \end{array}[/latex]
This tells us that the cost from the two companies will be the same if 100 miles are driven. Either by looking at the graph, or nothing that [latex]K(d)[/latex] is growing at a slower rate, we can conclude that Keep on Trucking, Inc. will be the cheaper price when more than 100 miles are driven, that is [latex]d> 100.[/latex]
Media
Access this online resource for additional instruction and practice with linear function models.
4.2 Section Exercises
Verbal
1. Explain how to find the input variable in a word problem that uses a linear function.
2. Explain how to find the output variable in a word problem that uses a linear function.
3. Explain how to interpret the initial value in a word problem that uses a linear function.
4. Explain how to determine the slope in a word problem that uses a linear function.
Algebraic
5. Find the area of a parallelogram bounded by the y-axis, the line [latex]x=3,[/latex] the line [latex]f(x)=1+2x,[/latex] and the line parallel to [latex]f(x)[/latex] passing through [latex](2, 7).[/latex]
6. Find the area of a triangle bounded by the x-axis, the line [latex]f(x)=12-\frac{1}{3}x,[/latex] and the line perpendicular to [latex]f(x)[/latex] that passes through the origin.
7. Find the area of a triangle bounded by the y-axis, the line [latex]f(x)=9-\frac{6}{7}x,[/latex] and the line perpendicular to [latex]f(x)[/latex] that passes through the origin.
8. Find the area of a parallelogram bounded by the x-axis, the line [latex]g(x)=2,[/latex] the line [latex]f(x)=3x,[/latex] and the line parallel to [latex]f(x)[/latex] passing through [latex](6, 1).[/latex]
For the following exercises, consider this scenario: A town’s population has been decreasing at a constant rate. In 2010 the population was 5,900. By 2012 the population had dropped to 4,700. Assume this trend continues.
9. Predict the population in 2016.
10. Identify the year in which the population will reach 0.
For the following exercises, consider this scenario: A town’s population has been increased at a constant rate. In 2010 the population was 46,020. By 2012 the population had increased to 52,070. Assume this trend continues.
11. Predict the population in 2016.
12. Identify the year in which the population will reach 75,000.
For the following exercises, consider this scenario: A town has an initial population of 75,000. It grows at a constant rate of 2,500 per year for 5 years.
13. Find the linear function that models the town’s population [latex]P[/latex] as a function of the year, [latex]t,[/latex] where [latex]t[/latex] is the number of years since the model began.
14. Find a reasonable domain and range for the function [latex]P.[/latex]
15. If the function [latex]P[/latex] is graphed, find and interpret the x– and y-intercepts.
16. If the function is graphed, find and interpret the slope of the function.
17. When will the population reach 100,000?
18. What is the population in the year 12 years from the onset of the model?
For the following exercises, consider this scenario: The weight of a newborn is 7.5 pounds. The baby gained one-half pound a month for its first year.
19. Find the linear function that models the baby’s weight [latex]W[/latex] as a function of the age of the baby, in months, [latex]t.[/latex]
20. Find a reasonable domain and range for the function [latex]W.[/latex]
21. If the function [latex]W[/latex] is graphed, find and interpret the x– and y-intercepts.
22. If the function [latex]W[/latex] is graphed, find and interpret the slope of the function.
23. When did the baby weight 10.4 pounds?
24. What is the output when the input is 6.2?
For the following exercises, consider this scenario: The number of people afflicted with the common cold in the winter months steadily decreased by 205 each year from 2005 until 2010. In 2005, 12,025 people were inflicted.
25. Find the linear function that models the number of people inflicted with the common cold [latex]C[/latex] as a function of the year, [latex]t.[/latex]
26. Find a reasonable domain and range for the function [latex]C.[/latex]
27. If the function [latex]C[/latex] is graphed, find and interpret the x– and y-intercepts.
28. If the function [latex]C[/latex] is graphed, find and interpret the slope of the function.
29. When will the output reach 0?
30. In what year will the number of people be 9,700?
Graphical
For the following exercises, use the graph in Figure 4, which shows the profit, [latex]y,[/latex] in thousands of dollars, of a company in a given year, [latex]t,[/latex] where [latex]t[/latex] represents the number of years since 1980.

31. Find the linear function [latex]y,[/latex] where [latex]y[/latex] depends on [latex]t,[/latex] the number of years since 1980.
32. Find and interpret the y-intercept.
33. Find and interpret the x-intercept.
34. Find and interpret the slope.
For the following exercises, use the graph in Figure 5, which shows the profit, [latex]y,[/latex] in thousands of dollars, of a company in a given year, [latex]t,[/latex] where [latex]t[/latex] represents the number of years since 1980.

35. Find the linear function [latex]y,[/latex] where [latex]y[/latex] depends on [latex]t,[/latex] the number of years since 1980.
36. Find and interpret the y-intercept.
37. Find and interpret the x-intercept.
38. Find and interpret the slope.
Numeric
For the following exercises, use the median home values in Mississippi and Hawaii (adjusted for inflation) shown in Table 2. Assume that the house values are changing linearly.
Year | Mississippi | Hawaii |
---|---|---|
1950 | $25,200 | $74,400 |
2000 | $71,400 | $272,700 |
39. In which state have home values increased at a higher rate?
40. If these trends were to continue, what would be the median home value in Mississippi in 2010?
41. If we assume the linear trend existed before 1950 and continues after 2000, the two states’ median house values will be (or were) equal in what year? (The answer might be absurd.)
For the following exercises, use the median home values in Indiana and Alabama (adjusted for inflation) shown in Table 3. Assume that the house values are changing linearly.
Year | Indiana | Alabama |
---|---|---|
1950 | $37,700 | $27,100 |
2000 | $94,300 | $85,100 |
42. In which state have home values increased at a higher rate?
43. If these trends were to continue, what would be the median home value in Indiana in 2010?
44. If we assume the linear trend existed before 1950 and continues after 2000, the two states’ median house values will be (or were) equal in what year? (The answer might be absurd.)
Create Your Own Real-World Applications
45. Model a linear function in your field of work. Describe the situation and describe what remains constant (y-intercept) and what changes at a constant rate (slope)?
46. Predict a trend in your life that models a linear function. Example: Savings over a period of time.
47. Create a word problem where you compare two scenarios using two linear models. Example: Comparing the cost of using two different streaming services.
48 Imagine you are starting a business. How could you use linear functions to come up with the cost function and the revenue function? What are some examples of fixed costs in your cost function? Can the revenue function have a constant (fixed) value? Why or why not?
49. Have you noticed any trends in your habits, spending, grades or anything else in your life that seems to follow a linear pattern? If you must track any of it, how would you do that using a linear function?
Real-World Applications
50. In 2004, a school population was 1001. By 2008 the population had grown to 1697. Assume the population is changing linearly.
(a) How much did the population grow between the year 2004 and 2008?
(b) How long did it take the population to grow from 1001 students to 1697 students?
(c) What is the average population growth per year?
(d) What was the population in the year 2000?
(e) Find an equation for the population, [latex]P,[/latex] of the school years after 2000.
(f) Using your equation, predict the population of the school in 2011.
51. In 2003, a town’s population was 1431. By 2007 the population had grown to 2134. Assume the population is changing linearly.
(a) How much did the population grow between the year 2003 and 2007?
(b) How long did it take the population to grow from 1431 people to 2134 people?
(c) What is the average population growth per year?
(d) What was the population in the year 2000?
(e) Find an equation for the population, [latex]P,[/latex] of the town years after 2000.
(f) Using your equation, predict the population of the town in 2014.
52. Xfinity has a monthly cellular plan where a customer pays a flat monthly fee and then a certain amount of money per minute used for voice or video calling. If a customer uses 410 minutes, the monthly cost will be $71.50. If the customer uses 720 minutes, the monthly cost will be $118.
(a) Find a linear equation for the monthly cost of the cell plan as a function of [latex]x,[/latex] the number of monthly minutes used.
(b) Interpret the slope and y-intercept of the equation.
(c) Use your equation to find the total monthly cost if 687 minutes are used.
53. Verizon has a monthly cellular data plan where a customer pays a flat monthly fee of $10 and then a certain amount of money per megabyte (MB) of data used on the phone. If a customer uses 20 MB, the monthly cost will be $11.20. If the customer uses 130 MB, the monthly cost will be $17.80.
(a) Find a linear equation for the monthly cost of the data plan as a function of the number of MB used.
(b) Interpret the slope and y-intercept of the equation.
(c) Use your equation to find the total monthly cost if 250 MB are used.
54. In 1991, the moose population in a park was measured to be 4,360. By 1999, the population was measured again to be 5,880. Assume the population continues to change linearly.
(a) Find a formula for the moose population, [latex]P[/latex] since 1990.
(b) What does your model predict the moose population to be in 2003?
55. In 2003, the owl population in a park was measured to be 340. By 2007, the population was measured again to be 285. The population changes linearly. Let the input be years since 2003.
(a) Find a formula for the owl population, [latex]P.[/latex] Let the input be years since 2003.
(b) What does your model predict the owl population to be in 2012?
56. The Federal Helium Reserve held about 16 billion cubic feet of helium in 2010 and is being depleted by about 2.1 billion cubic feet each year.
(a) Give a linear equation for the remaining federal helium reserves, [latex]R,[/latex] in terms of [latex]t,[/latex] the number of years since 2010.
(b) In 2015, what will the helium reserves be?
(c) If the rate of depletion doesn’t change, in what year will the Federal Helium Reserve be depleted?
57. Suppose the world’s oil reserves in 2014 are 1,820 billion barrels. If, on average, the total reserves are decreasing by 25 billion barrels of oil each year:
(a) Give a linear equation for the remaining oil reserves, [latex]R,[/latex] in terms of [latex]t,[/latex] the number of years since now.
(b) Seven years from now, what will the oil reserves be?
(c) If the rate at which the reserves are decreasing is constant, when will the world’s oil reserves be depleted?
58. You are choosing between two different prepaid cell phone plans. The first plan charges a rate of 26 cents per minute. The second plan charges a monthly fee of $19.95 plus 11 cents per minute. How many minutes would you have to use in a month in order for the second plan to be preferable?
59. You are choosing between two different window washing companies. The first charges $5 per window. The second charges a base fee of $40 plus $3 per window. How many windows would you need to have for the second company to be preferable?
60. When hired at a new job selling jewelry at JC Pennery, you are given two pay options:
Option A: Base salary of $17,000 a year with a commission of 12% of your sales
Option B: Base salary of $20,000 a year with a commission of 5% of your sales
How much jewelry would you need to sell for option A to produce a larger income?
61. When hired at a new job selling electronics at Best Buy, you are given two pay options:
Option A: Base salary of $14,000 a year with a commission of 10% of your sales
Option B: Base salary of $19,000 a year with a commission of 4% of your sales
How much electronics would you need to sell for option A to produce a larger income?
- Rates retrieved Aug 2, 2010 from http://www.budgettruck.com and http://www.uhaul.com/ ↵