2.3 Functions and Models
Linear Functions
As you hop into a taxicab in Allentown, the meter will immediately read $3.30; this is the “drop” charge made when the taxi meter is activated. After that initial fee, the taxi meter will add $2.40 for each mile the taxi drives. In this scenario, the total taxi fare depends upon the number of miles ridden in the taxi, and we can ask whether it is possible to model this type of scenario with a mathematical function. Using descriptive variables, we choose
We know for certain that
It is good to verify that the units make sense in this equation. The $3.30 drop charge is measured in dollars; the $2.40 charge is measured in dollars per mile. So
When dollars per mile are multiplied by a number of miles, the result is a number of dollars, matching the units on the 3.30, and matching the desired units for the C function.
Notice this equation
Looking at this same problem in table format we can also see the cost changes by $2.40 for every 1 mile increase:
0 | 1 | 2 | 3 | |
---|---|---|---|---|
C(m) | 3.30 | 5.70 | 8.10 | 10.50 |
It is important here to note that in this equation, the rate of change is constant; over any interval, the rate of change is the same.
Graphing this equation,

Long description: The line passes through the points (0 , 4) and (10, 27).
When the number of miles is zero the cost is $3.30, giving the point
Linear Function
A linear function is a function whose graph produces a line. Linear functions can always be written in the form
or
where
This form of a line is called slope-intercept form of a line.
Many people like to write linear functions in the form
For this reason alone we will use the
Slope and Increasing/Decreasing
is an increasing function if . is a decreasing function if
If
Example 1
Marcus currently owns 200 songs in his iTunes collection. Every month, he adds 15 new songs. Write a formula for the number of songs,
The initial value for this function is 200, since he currently owns 200 songs, so
With this formula we can predict how many songs he will have in 1 year (12 months):
Marcus will have 380 songs in 12 months.
Calculating Rate of Change
Given two values for the input,
Rate of change of a linear function is also called the slope of the line.
Note in function notation,
Example 2
The population of a city increased from 23,400 to 27,800 between 2002 and 2006. Find the rate of change of the population during this time span.
The rate of change will relate the change in population to the change in time. The population increased by
Notice that we knew the population was increasing, so we would expect our value for m to be positive. This is a quick way to check to see if your value is reasonable.
Example 3
The pressure,
The rate of change, or slope, 0.434 would have units
The initial value, 14.696, will have the same units as the output, so this tells us that at a depth of 0 feet, the pressure on the diver will be 14.696 PSI.
We can now find the rate of change given two input-output pairs, and could write an equation for a linear function if we had the rate of change and initial value. If we have two input-output pairs and they do not include the initial value of the function, then we will have to solve for it.
Example 4
Write an equation for the linear function graphed here.

Long description: The line passes through the points (0, 7) and (8,1).
Looking at the graph, we might notice that it passes through the points
This allows us to write the equation:
Example 5
If
The rate of change (or slope) of the function is
Combining this with the value for the rate of change, we can now write a formula for this function:
As an alternative to the approach used above to find the initial value, b, we can use the point-slope form of a line instead.
Point-Slope Equation of a Line
An equation for the line passing through the point
This is called the point-slope form of a line. It is a little easier to write if you know a point and the slope, but requires a bit of work to rewrite into slope-intercept form, and requires memorizing another formula.
Example 6
Working as an insurance salesperson, Ilya earns a base salary and a commission on each new policy, so Ilya’s weekly income,
The given information gives us two input-output pairs:
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; Ilya earns a commission of $80 for each policy sold during the week.
We can now write the equation using the point-slope form of the line, using the slope we just found and the point
If we wanted this in function form (slope intercept form), we could rewrite the equation into that form:
This form allows us to see the starting value for the function: 520. This is Ilya’s income when n = 0, which means 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.
Our final interpretation is: Ilya’s base salary is $520 per week and he earns an additional $80 commission for each policy sold each week.
Graphs of Linear Functions
Graphical Interpretation of a Linear Equation
Graphically, in the equation
is the vertical intercept of the graph and tells us we can start our graph at- and
is the slope of the line and tells us how far to rise and run to get to the next point.
Once we have at least 2 points, we can extend the graph of the line to the left and right.
Example 7
Graph
The vertical intercept of the function is

Long description: A solid dot is shown at the point (6, 1). A horizontal dashed line extends from (0, 5) to (3, 5). A vertical dashed line extends from (3, 5) to (3,3).
Another option for graphing is to use transformations of the identity function

In

Example 8
Match each equation with one of the lines in the graph below

Only one graph has a vertical intercept of -3, so we can immediately match that graph with

In addition to understanding the basic behavior of a linear function (increasing or decreasing, recognizing the slope and vertical intercept), it is often helpful to know the horizontal intercept of the function – where it crosses the horizontal axis.
Finding Horizontal Intercept
The horizontal intercept of the function is where the graph crosses the horizontal axis. If a function has a horizontal intercept, you can always find it by solving
Example 9
Find the horizontal intercept of
Setting the function equal to zero to find what input will put us on the horizontal axis:
Thus the graph crosses the horizontal axis at
Intersections of Lines
The graphs of two lines will intersect if they are not parallel. They will intersect at the point that satisfies both equations. To find this point when the equations are given as functions, we can solve for an input value so that
Economics tells us that in a free market, the price for an item is related to the quantity that producers will supply and the quantity that consumers will demand. Increases in prices will decrease demand, while supply tends to increase with prices. Sometimes supply and demand are modeled with linear functions.
Example 10
The supply, in thousands of items, for custom phone cases can be modeled by the equation,
Setting
We can find the output value of the intersection point by evaluating either function at this input:
These lines intersect at the point

Quadratics
Quadratics are transformations of the function
Example 11
A backyard farmer wants to enclose a rectangular space for a new garden. She has purchased 80 feet of wire fencing to enclose three sides, and will put the fourth side against the backyard fence. Find a formula for the area enclosed by the fence if the sides of fencing perpendicular to the existing fence have length

In a scenario like this involving geometry, it is often helpful to draw a picture. It might also be helpful to introduce a temporary variable,
Since we know we only have 80 feet of fence available, we know that
Now we are ready to write an equation for the area the fence encloses. We know the area of a rectangle is length multiplied by width, so
This formula represents the area of the fence in terms of the variable length
Forms of Quadratic Functions
The standard form of a quadratic function is
The transformation form of a quadratic function is
The vertex of the quadratic function is located at
Example 12
Write an equation for the quadratic graphed below as a transformation of

We can see the graph is the basic quadratic shifted to the left 2 and down 3, putting the vertex at
The equation for this formula is
Short run Behavior: Intercepts
As with any function, we can find the vertical intercepts of a quadratic by evaluating the function at an input of zero, and we can find the horizontal intercepts by solving for when the output will be zero. Notice that depending upon the location of the graph, we might have zero, one, or two horizontal intercepts.



Notice that in the standard form of a quadratic, the constant term
Example 13
Find the vertical and horizontal intercepts of the quadratic
We can find the vertical intercept by evaluating the function at an input of zero:
So the vertical intercept is at
For the horizontal intercepts, we solve for when the output will be zero:
In this case, the quadratic can be factored easily, providing the simplest method for solution.:
so either
or
So the Horizontal intercepts are at
When a quadratic is not factorable or is hard to factor, we can turn to the quadratic formula.
Quadratic Formula
For a quadratic function given in standard form
Example 14
A ball is thrown upwards from the top of a 40 foot high building at a speed of 80 feet per second. The ball’s height above ground can be modeled by the equation
When does the ball hit the ground?
To find when the ball hits the ground, we need to determine when the height is zero, i.e., when
Since the square root does not simplify nicely, we can use a calculator to approximate the values of the solutions:
The second answer is outside the reasonable domain of our model, so we conclude the ball will hit the ground after about 5.458 seconds.
Polynomial Functions
Terminology of Polynomial Functions
A polynomial is a function that can be written as
Each of the
A term of the polynomial is any one piece of the sum, that is any
The degree of the polynomial is the highest power of the variable that occurs in the polynomial.
The leading term is the term containing the highest power of the variable: the term with the highest degree.
The leading coefficient is the coefficient of the leading term.
Because of the definition of the “leading” term we often rearrange polynomials so that the powers are descending:
Example 15
Identify the degree, leading term, and leading coefficient of the polynomial
The degree is 3, the highest power on
Short Run Behavior: Intercepts
As with any function, the vertical intercept can be found by evaluating the function at an input of zero. Since this is evaluation, it is relatively easy to do it for a polynomial of any degree. To find horizontal intercepts, we need to solve for when the output will be zero. For general polynomials, this can be a challenging prospect. Consequently, we will limit ourselves to three cases:
- The polynomial can be factored using known methods: greatest common factor and trinomial factoring.
- The polynomial is given in factored form.
- Technology is used to determine the intercepts.
Example 16
Find the horizontal intercepts of
We can attempt to factor this polynomial to find solutions for
Factoring out the greatest common factor Factoring the inside as a quadratic in
Then break apart to find solutions:
This gives us five horizontal intercepts.
Example 17
Find the horizontal intercepts of
Since this polynomial is not in factored form, has no common factors, and does not appear to be factorable using techniques we know, we can turn to technology to find the intercepts.
Graphing this function, it appears there are horizontal intercepts at

We could check these are correct by plugging in these values for
Solving Polynomial Inequalities
One application of our ability to find intercepts and sketch a graph of polynomials is the ability to solve polynomial inequalities. It is a very common question to ask when a function will be positive and negative, and one we will use later in this course.
Example 18
Solve
As with all inequalities, we start by solving the equality
We could choose a test value in each interval and evaluate the function
Interval | Test |
||
---|---|---|---|
-4 | 72 | ||
-2 | -6 | ||
0 | -12 | ||
5 | 288 |
On a number line this would look like:

Long description: The interval from -6 to -3.2 is labeled as positive. the interval from -3.2 to -1.2 is labeled as negative, the interval from -1.2 to 3.8 is labeled as negative, and the interval from 3.8 to 6 is labeled as positive.
From our test values, we can determine this function is positive when
Rational Functions
Rational functions are the ratios, or fractions, of polynomials. They can arise from both simple and complex situations.
Example 19
You plan to drive 100 miles. Find a formula for the time the trip will take as a function of the speed you drive.
You may recall that multiplying speed by time will give you distance. If we let
Notice that this is a transformation of the reciprocal toolkit function,
We have seen the graphs of the basic reciprocal function and the squared reciprocal function from our review of toolkit functions. These graphs have several important features.


Let’s begin by looking at the reciprocal function,
Short Run behavior
As the input values approach zero from the left side (taking on very small, negative values), the function values become very large in the negative direction (in other words, they approach negative infinity).
We write:
As we approach zero from the right side (small, positive input values), the function values become very large in the positive direction (approaching infinity).
We write: as
This behavior creates a vertical asymptote. An asymptote is a line that the graph approaches. In this case the graph is approaching the vertical line
Long Run behavior
As the values of x approach infinity, the function values approach 0. Also, as the values of x approach negative infinity, the function values approach 0.
Symbolically: as
Based on this long run behavior and the graph we can see that the function approaches 0 but never actually reaches 0, it just “levels off” as the inputs become large. This behavior creates a horizontal asymptote. In this case the graph is approaching the horizontal line
Vertical and Horizontal Asymptotes
A vertical asymptote of a graph is a vertical line
A horizontal asymptote of a graph is a horizontal line
Example 20
Sketch a graph of the reciprocal function shifted two units to the left and up three units. Identify the horizontal and vertical asymptotes of the graph, if any.
Transforming the graph left 2 and up 3 would result in the function
Shifting the toolkit function would give us this graph. Notice that this equation is undefined at

As the inputs grow large, the graph appears to be leveling off at output values of 3, indicating a horizontal asymptote at
Notice that horizontal and vertical asymptotes get shifted left 2 and up 3 along with the function.
A general rational function is the ratio of any two polynomials.
Rational Function
A rational function is a function that can be written as the ratio of two polynomials,
Rational functions can arise from many real situations.
Example 21
A large mixing tank currently contains 100 gallons of water, into which 5 pounds of sugar have been mixed. A tap will open pouring 10 gallons per minute of water into the tank at the same time sugar is poured into the tank at a rate of 1 pound per minute. Find the concentration (pounds per gallon) of sugar in the tank after
Notice that the amount of water in the tank is changing linearly, as is the amount of sugar in the tank. We can write an equation independently for each:
The concentration,
Vertical Asymptotes of Rational Functions
The vertical asymptotes of a rational function will occur for x-values where the denominator of the function is equal to zero and the numerator is not zero.
Horizontal Asymptote of Rational Functions
The horizontal asymptote of a rational function can be determined by comparing the degrees of the numerator and denominator.
- Degree of denominator > degree of numerator: Horizontal asymptote at y=0.
- Degree of denominator < degree of numerator: No horizontal asymptote.
- Degree of denominator = degree of numerator: Horizontal asymptote at ratio of leading coefficients,
(p and q are equal in this case).
Example 22
In the sugar concentration problem from earlier, we created the equation
Both the numerator and denominator are linear (degree 1), so since the degrees are equal, there will be a horizontal asymptote at the ratio of the leading coefficients. In the numerator, the leading term is
This tells us that as the input gets large, the output values will approach
Example 23
Find the horizontal and vertical asymptotes of the function
First, note this function has no inputs that make both the numerator and denominator zero, so there are no potential holes. The function will have vertical asymptotes when the denominator is zero, causing the function to be undefined. The denominator will be zero at
The numerator has degree 2, while the denominator has degree 3. Since the degree of the denominator is greater than the degree of the numerator, the denominator will grow faster than the numerator, causing the outputs to tend towards zero as the inputs get large, and so as
As with all functions, a rational function will have a vertical intercept when the input is zero, if the function is defined at zero. It is possible for a rational function to not have a vertical intercept if the function is undefined at zero.
Likewise, a rational function will have horizontal intercepts at the inputs that cause the output to be zero (unless that input corresponds to a hole). It is possible there are no horizontal intercepts. Since a fraction is only equal to zero when the numerator is zero, horizontal intercepts will occur when the numerator of the rational function is equal to zero.
Example 24
Find the intercepts of
We can find the vertical intercept by evaluating the function at zero:
The horizontal intercepts will occur when the function is equal to zero: