Skip to main content

Section 5.5 Key features of rational functions

Because any rational function is the ratio of two polynomial functions, it's natural to ask questions about rational functions similar to those we ask about polynomials. With polynomials, it is often helpful to know where the function's value is zero. In a rational function \(r(x) = \frac{p(x)}{q(x)}\text{,}\) we are curious to know where both \(p(x) = 0\) and where \(q(x) = 0\text{.}\)

Connected to these questions, we want to understand both where a rational function's output value is zero, as well as where the function is undefined. In addition, from the behavior of simple rational power functions such as \(\frac{1}{x}\text{,}\) we expect that rational functions may not only have horizontal asymptotes (as investigated in Section 5.4), but also vertical asymptotes. At first glance, these questions about zeros and vertical asymptotes of rational functions may appear to be elementary ones whose answers simply depend on where the numerator and denominator of the rational function are zero. But in fact, rational functions often admit very subtle behavior that can escape the human eye and the graph generated by a computer.

Preview Activity 5.5.1.

Consider the rational function \(r(x) = \frac{x^2 - 1}{x^2 - 3x - 4}\text{,}\) and let \(p(x) = x^2 - 1\) (the numerator of \(r(x)\)) and \(q(x) = x^2 - 3x - 4\) (the denominator of \(r(x)\)).

  1. Reasoning algebraically, for what values of \(x\) is \(p(x) = 0\text{?}\)

  2. Again reasoning algebraically, for what values of \(x\) is \(q(x) = 0\text{?}\)

  3. Define \(r(x)\) in Desmos, and evaluate the function appropriately to find numerical values for the output of \(r\) and hence complete the following tables.

    \(x\) \(r(x)\)
    \(4.1\) \(\)
    \(4.01\) \(\)
    \(4.001\) \(\)
    \(3.9\) \(\)
    \(3.99\) \(\)
    \(3.999\) \(\)
    \(x\) \(r(x)\)
    \(1.1\) \(\)
    \(1.01\) \(\)
    \(1.001\) \(\)
    \(0.9\) \(\)
    \(0.99\) \(\)
    \(0.999\) \(\)
    \(x\) \(r(x)\)
    \(-1.1\) \(\)
    \(-1.01\) \(\)
    \(-1.001\) \(\)
    \(-0.9\) \(\)
    \(-0.99\) \(\)
    \(-0.999\) \(\)
  4. Why does \(r\) behave the way it does near \(x = 4\text{?}\) Explain by describing the behavior of the numerator and denominator.

  5. Why does \(r\) behave the way it does near \(x = 1\text{?}\) Explain by describing the behavior of the numerator and denominator.

  6. Why does \(r\) behave the way it does near \(x = -1\text{?}\) Explain by describing the behavior of the numerator and denominator.

  7. Plot \(r\) in Desmos. Is there anything surprising or misleading about the graph that Desmos generates?

Subsection 5.5.1 When a rational function has a “hole”

Two important features of any rational function \(r(x) = \frac{p(x)}{q(x)}\) are any zeros and vertical asymptotes the function may have. These aspects of a rational function are closely connected to where the numerator and denominator, respectively, are zero. At the same time, a subtle related issue can lead to radically different behavior. To understand why, we first remind ourselves of a few key facts about fractions that involve \(0\text{.}\) Because we are working with a function, we'll think about fractions whose numerator and denominator are approaching particular values.

If the numerator of a fraction approaches \(0\) while the denominator approaches a nonzero value, then the overall fraction values will approach zero. For instance, consider the sequence of values

\begin{equation*} \frac{0.1}{0.9} = 0.111111\cdots, \frac{0.01}{0.99} = 0.010101\cdots, \frac{0.001}{0.999} = 0.001001\cdots\text{.} \end{equation*}

Because the numerator gets closer and closer to \(0\) and the denominator stays away from \(0\text{,}\) the quotients tend to \(0\text{.}\)

Similarly, if the denominator of a fraction approaches \(0\) while the numerator approaches a nonzero value, then the overall fraction increases without bound. If we consider the reciprocal values of the sequence above, we see that

\begin{equation*} \frac{0.9}{0.1} = 9, \frac{0.99}{0.01} = 99, \frac{0.999}{0.001} = 999\text{.} \end{equation*}

Since the denominator gets closer and closer to \(0\) and the numerator stays away from \(0\text{,}\) the quotients increase without bound.

These two behaviors show how the zeros and vertical asympototes of a rational function \(r(x) = \frac{p(x)}{q(x)}\) arise: where the numerator \(p(x)\) is zero and the denominator \(q(x)\) is nonzero, the function \(r\) will have a zero; and where \(q(x)\) is zero and \(p(x)\) is nonzero, the function will have a vertical asymptote. What we must be careful of is the special situation where both the numerator \(p(x)\) and \(q(x)\) are simultaneously zero. Indeed, if the numerator and denominator of a fraction both approach \(0\text{,}\) different behavior can arise. For instance, consider the sequence

\begin{equation*} \frac{0.2}{0.1} = 2, \frac{0.02}{0.01} = 2, \frac{0.002}{0.001} = 2\text{.} \end{equation*}

In this situation, both the numerator and denominator are approaching \(0\text{,}\) but the overall fraction's value is always \(2\text{.}\) This is very different from the two sequences we considered above. In Example 5.5.1, we explore similar behavior in the context of a particular rational function.

Example 5.5.1.

Consider the rational function \(r(x) = \frac{x^2 - 1}{x^2 - 3x - 4}\) from Preview Activity 5.5.1, whose numerator is \(p(x) = x^2 - 1\) and whose denominator is \(q(x) = x^2 - 3x - 4\text{.}\) Explain why the graph of \(r\) generated by Desmos or another computational device is incorrect, and also identify the locations of any zeros and vertical asymptotes of \(r\text{.}\)

Solution

It is helpful with any rational function to factor the numerator and denominator. We note that \(p(x) = x^2 - 1 = (x-1)(x+1)\) and \(q(x) = x^2 - 3x - 4 = (x+1)(x-4)\text{.}\) The domain of \(r\) is thus the set of all real numbers except \(x = -1\) and \(x = 4\text{,}\) the set of all points where \(q(x) \ne 0\text{.}\)

Knowing that \(r\) is not defined at \(x = -1\text{,}\) it is natural to study the graph of \(r\) near that value. Plotting the function in Desmos, we get a result similar to the one shown in Figure 5.5.2, which appears to show no unusual behavior at \(x = -1\text{,}\) and even that \(r(-1)\) is defined. If we zoom in on that point, as shown in Figure 5.5.3, the technology still fails to visually demonstrate the fact that \(r(-1)\) is not defined. This is because graphing utilities sample functions at a finite number of points and then connect the resulting dots to generate the curve we see.

Figure 5.5.2. A plot of \(r(x) = \frac{x^2 - 1}{x^2 - 3x - 4}\text{.}\)
Figure 5.5.3. Zooming in on \(r(x)\) near \(x = -1\text{.}\)
Figure 5.5.4. How the graph of \(r(x)\) should actually appear near \(x = -1\text{.}\)

We know from our algebraic work with the denominator, \(q(x) = (x+1)(x-4)\text{,}\) that \(r\) is not defined at \(x = -1\text{.}\) While the denominator \(q\) gets closer and closer to \(0\) as \(x\) approaches \(-1\text{,}\) so does the numerator, since \(p(x) = (x-1)(x+1)\text{.}\) If we consider values close but not equal to \(x = -1\text{,}\) we see results in Table 5.5.5.

Table 5.5.5. Values of \(r(x) = \frac{x^2 - 1}{x^2 - 3x - 4}\) near \(x = -1\text{.}\)
\(x\) \(-1.1\) \(-1.01\) \(-1.001\)
\(r(x)\) \(\frac{0.21}{0.51} \approx 0.4118 \) \(\frac{0.0201}{0.0501} \approx 0.4012\) \(\frac{0.002001}{0.005001} \approx 0.4001\)
\(x\) \(-0.9\) \(-0.99\) \(-0.999\)
\(r(x)\) \(\frac{-0.19}{-0.49} \approx 0.3878\) \(\frac{-0.0199}{-0.0499} \approx 0.3989\) \(\frac{-0.001999}{-0.004999} \approx 0.3999\)

In the table, we see that both the numerator and denominator get closer and closer to \(0\) as \(x\) gets closer and closer to \(-1\text{,}\) but that their quotient appears to be getting closer and closer to \(y = 0.4\text{.}\) Indeed, we see this behavior in the graph of \(r\text{,}\) though the graphing utility misses the fact that \(r(-1)\) is actually not defined. A precise graph of \(r\) near \(x = -1\) should look like the one presented in Figure 5.5.4, where we see an open circle at the point \((-1, 0.4)\) that demonstrates that \(r(-1)\) is not defined, and that \(r\) does not have a vertical asymptote or zero at \(x = -1\text{.}\)

Finally, we also note that \(p(1) = 0\) and \(q(1) = -6\text{,}\) so at \(x = 1\text{,}\) \(r(x)\) has a zero (its numerator is zero and its denominator is not). In addition, \(q(4) = 0\) and \(p(4) = 15\) (its denominator is zero and its numerator is not), so \(r(x)\) has a vertical asymptote at \(x = 4\text{.}\) These features are accurately represented by the original Desmos graph shown in Figure 5.5.2.

In the situation where a rational function is undefined at a point but does not have a vertical asymptote there, we'll say that the graph of the function has a hole. In calculus, we use limit notation to identify a hole in a function's graph. Indeed, having shown in Example 5.5.1 that the value of \(r(x)\) gets closer and closer to \(0.4\) as \(x\) gets closer and closer to \(-1\text{,}\) we naturally write

\begin{equation*} \lim_{x \to -1} r(x) = 0.4 \end{equation*}

as a shorthand way to represent the behavior of \(r\) (similar to how we've written limits involving \(\infty\)). This fact, combined with \(r(-1)\) being undefined, tells us that near \(x = -1\) the graph approaches a value of \(0.4\) but has to have a hole at the point \((-1,0.4)\text{,}\) as shown in Figure 5.5.4. Because we'll encounter similar behavior with other functions, we formally define limit notation as follows.

Definition 5.5.6.

Let \(a\) and \(L\) be finite real numbers, and let \(r\) be a function defined near \(x = a\text{,}\) but not necessarily at \(x = a\) itself. If we can make the value of \(r(x)\) as close to the number \(L\) as we like by taking \(x\) sufficiently close (but not equal) to \(a\text{,}\) then we write

\begin{equation*} \lim_{x \to a} r(x) = L \end{equation*}

and say that “the limit of \(r\) as \(x\) approaches \(a\) is \(L\)”.

The key observations regarding zeros, vertical asymptotes, and holes in Example 5.5.1 apply to any rational function.

Features of a rational function.

Let \(r(x) = \frac{p(x)}{q(x)}\) be a rational function.

  • If \(p(a) = 0\) and \(q(a) \ne 0\text{,}\) then \(r(a) = 0\text{,}\) so \(r\) has a zero at \(x = a\text{.}\)

  • If \(q(a) = 0\) and \(p(a) \ne 0\text{,}\) then \(r(a)\) is undefined and \(r\) has a vertical asymptote at \(x = a\text{.}\)

  • If \(p(a) = 0\) and \(q(a) = 0\) and we can show that there is a finite number \(L\) such that

    \begin{equation*} \lim_{x \to a} r(x) = L\text{,} \end{equation*}

    then \(r(a)\) is not defined and \(r\) has a hole at the point \((a,L)\text{.}\) 1 

It is possible for both \(p(a) = 0\) and \(q(a) = 0\) and for \(r\) to still have a vertical asymptote at \(x = a\text{.}\) We explore this possibility further in Exercise 5.5.4.9.
Activity 5.5.2.

For each of the following rational functions, state the function's domain and determine the locations of all zeros, vertical asymptotes, and holes. Provide clear justification for your work by discussing the zeros of the numerator and denominator, as well as a table of values of the function near any point where you believe the function has a hole. In addition, state the value of the horizontal asymptote of the function or explain why the function has no such asymptote.

  1. \(\displaystyle \displaystyle f(x) = \frac{x^3 - 6x^2 + 5x}{x^2-1}\)

  2. \(\displaystyle \displaystyle g(x) = \frac{11(x^2 + 1)(x-7)}{23(x-1)(x^2+4)}\)

  3. \(\displaystyle \displaystyle h(x) = \frac{x^2 - 8x + 12}{x^2 - 3x - 18}\)

  4. \(\displaystyle \displaystyle q(x) = \frac{(x-2)(x^2-9)}{(x-3)(x^2 + 4)}\)

  5. \(\displaystyle \displaystyle r(x) = \frac{19(x-2) (x-3)^2 (x+1)}{17(x+1)(x-4)^2(x-5)}\)

  6. \(\displaystyle \displaystyle s(x) = \frac{1}{x^2 + 1}\)

Subsection 5.5.2 Sign charts and finding formulas for rational functions

Just like with polynomial functions, we can use sign charts to describe the behavior of rational functions. The only significant difference for their use in this context is that we not only must include all \(x\)-values where the rational function \(r(x) = 0\text{,}\) but also all \(x\)-values at which the function \(r\) is not defined. This is because it is possible for a rational function to change sign at a point that lies outside its domain, such as when the function has a vertical asymptote.

Example 5.5.7.

Construct a sign chart for the function \(q(x) = \frac{(x-2)(x^2-9)}{(x-3)(x-1)^2}\text{.}\) Then, graph the function \(q\) and compare the graph and sign chart.

Solution

First, we fully factor \(q\) and identify the \(x\)-values that are not in its domain. Since \(x^2-9 = (x-3)(x+3)\text{,}\) we see that

\begin{equation*} q(x) = \frac{(x-2)(x-3)(x+3)}{(x-3)(x-1)^2}\text{.} \end{equation*}

From the denominator, we observe that \(q\) is not defined at \(x = 3\) and \(x = 1\) since those values make the factors \(x - 3 = 0\) or \((x-1)^2 = 0\text{.}\) Thus, the domain of \(q\) is the set of all real numbers except \(x = 1\) and \(x = 3\text{.}\) From the numerator, we see that both \(x = 2\) and \(x = -3\) are zeros of \(q\) since these values make the numerator zero while the denominator is nonzero. We expect that \(q\) will have a hole at \(x = 3\) since this \(x\)-value is not in the domain and it makes both the numerator and denominator \(0\text{.}\) Indeed, computing values of \(q\) for \(x\) near \(x = 3\) suggests that

\begin{equation*} \lim_{x \to 3} q(x) = 1.5\text{,} \end{equation*}

and thus \(q\) does not change sign at \(x = 3\text{.}\)

Thus, we have three different \(x\)-values to place on the sign chart: \(x = -3\text{,}\) \(x = 1\text{,}\) and \(x = 2\text{.}\) We now analyze the sign of each of the factors in \(q(x) = \frac{(x-2)(x-3)(x+3)}{(x-3)(x-1)^2}\) on the various intervals. For \(x \lt -3\text{,}\) \((x-2) \lt 0\text{,}\) \((x-3) \lt 0\text{,}\) \((x+3) \lt 0\text{,}\) and \((x-1)^2 \gt 0\text{.}\) Thus, for \(x \lt -3\text{,}\) the sign of \(q\) is

\begin{equation*} \frac{- - -}{- +} = + \end{equation*}

since there are an even number of negative terms in the quotient.

On the interval \(-3 \lt x \lt 1\text{,}\) \((x-2) \lt 0\text{,}\) \((x-3) \lt 0\text{,}\) \((x+3) \gt 0\text{,}\) and \((x-1)^2 \gt 0\text{.}\) Thus, for these \(x\)-values, the sign of \(q\) is

\begin{equation*} \frac{- - +}{- +} = -\text{.} \end{equation*}

Using similar reasoning, we can complete the sign chart shown in Figure 5.5.8. A plot of the function \(q\text{,}\) as seen in Figure 5.5.9, shows behavior that matches the sign function, as well as the need to manually identify the hole at \((3, 1.5)\text{,}\) which is missed by the graphing software.

Figure 5.5.8. The sign chart for \(q\text{.}\)
Figure 5.5.9. A plot of \(q\text{.}\)

In both the sign chart and the figure, we see that \(q\) changes sign at each of its zeros, \(x = -3\) and \(x = 2\text{,}\) and that it does not change as it passes by its vertical asymptote at \(x = 1\text{.}\) The reason \(q\) doesn't change sign at the asympotote is because of the repeated factor of \((x-1)^2\) which is always positive.

To find a formula for a rational function with certain properties, we can reason in ways that are similar to our work with polynomials. Since the rational function must have a polynomial expression in both the numerator and denominator, by thinking about where the numerator and denominator must be zero, we can often generate a formula whose graph will satisfy the desired properties.

Activity 5.5.3.

Find a formula for a rational function that meets the stated criteria as given by words, a sign chart, or graph. Write several sentences to justify why your formula matches the specifications. If no such rational function is possible, explain why.

  1. A rational function \(r\) such that \(r\) has a vertical asymptote at \(x = -2\text{,}\) a zero at \(x = 1\text{,}\) a hole at \(x = 5\text{,}\) and a horizontal asymptote of \(y = -3\text{.}\)

  2. A rational function \(u\) whose numerator has degree \(3\text{,}\) denominator has degree \(3\text{,}\) and that has exactly one vertical asymptote at \(x = -4\) and a horizontal asymptote of \(y = \frac{3}{7}\text{.}\)

  3. A rational function \(w\) whose formula generates a graph with all of the characteristics shown in Figure 5.5.10. Assume that \(w(5) = 0\) but \(w(x) \gt 0\) for all other \(x\) such that \(x \gt 3\text{.}\)

  4. A rational function \(z\) whose formula satisfies the sign chart shown in Figure 5.5.11, and for which \(z\) has no horizontal asymptote and its only vertical asymptotes occur at the middle two values of \(x\) noted on the sign chart.

    Figure 5.5.10. Plot of the rational function \(w\text{.}\)
    Figure 5.5.11. Sign chart for the rational function \(z\text{.}\)
  5. A rational function \(f\) that has exactly two holes, two vertical asymptotes, two zeros, and a horizontal asymptote.

Subsection 5.5.3 Summary

  • If a rational function \(r(x) = \frac{p(x)}{q(x)}\) has the properties that \(p(a) = 0\) and \(q(a) = 0\) and

    \begin{equation*} \lim_{x \to a} r(x) = L\text{,} \end{equation*}

    then \(r\) has a hole at the point \((a,L)\text{.}\) This behavior can occur when there is a matching factor of \((x-a)\) in both \(p\) and \(q\text{.}\)

  • For a rational function \(r(x) = \frac{p(x)}{q(x)}\text{,}\) we determine where the function has zeros and where it has vertical asymptotes by considering where the numerator and denominator are \(0\text{.}\) In particular, if \(p(a) = 0\) and \(q(a) \ne 0\text{,}\) then \(r(a) = 0\text{,}\) so \(r\) has a zero at \(x = a\text{.}\) And if \(q(a) = 0\) and \(p(a) \ne 0\text{,}\) then \(r(a)\) is undefined and \(r\) has a vertical asymptote at \(x = a\text{.}\)

  • By writing a rational function's numerator in factored form, we can generate a sign chart for the function that takes into account all of the zeros and vertical asymptotes of the function, which are the only points where the function can possibly change sign. By testing \(x\)-values in various intervals between zeros and/or vertical asymptotes, we can determine where the rational function is positive and where the function is negative.

Exercises 5.5.4 Exercises

1.
2.
3.
4.
5.
6.

For each of the following rational functions, determine, with justification, the exact locations of all (i) horizontal asymptotes, (ii) vertical asymptotes, (iii) zeros, and (iv) holes of the function. Clearly show your work and thinking.

  1. \(\displaystyle \displaystyle r(x) = \frac{-19(x+11.3)^2(x-15.1)(x-17.3)}{41(x+5.7)(x+11.3)(x-8.4)(x-15.1)}\)

  2. \(\displaystyle \displaystyle s(x) = \frac{-29(x^2-16)(x^2+99)(x-53)}{101(x^2-4)(x-13)^2(x+104)}\)

  3. \(\displaystyle \displaystyle u(x) = \frac{-71(x^2 - 13x + 36)(x-58.4)(x+78.2)}{83(x+58.4)(x-78.2)(x^2 - 12x + 27)}\)

7.

Find a formula for a rational function that meets the stated criteria, with justification. If no such formula is possible, explain why.

  1. A rational function \(r(x)\) in the form \(r(x) = \frac{k}{x-a} + b\) so that \(r\) has a horizontal asymptote of \(y = -\frac{3}{7}\text{,}\) a vertical asymptote of \(x = \frac{5}{2}\text{,}\) and \(r(0) = 4\text{.}\)

  2. A rational function \(s(x)\) that has no horizontal asymptote, has zeros at \(x = -5\) and \(x = 3\text{,}\) has a single vertical asymptote at \(x = -1\text{,}\) and satisfies \(\lim_{x \to \infty} s(x) = -\infty\) and \(\lim_{x \to -\infty} s(x) = +\infty\text{.}\)

  3. A rational function \(u(x)\) that is positive for \(x \lt -4\text{,}\) negative for \(-4 \lt x \lt -2\text{,}\) negative for \(-2 \lt x \lt 1\text{,}\) positive for \(1 \lt x \lt 5\text{,}\) and negative for \(x \gt 5\text{.}\) The only zeros of \(u\) are located at \(x = -4\) and \(x = -2\text{.}\) In addition, \(u\) has a hole at \(x = 4\text{.}\)

  4. A rational function \(w(x)\) whose graph is shown in Figure 5.5.12.

    Figure 5.5.12. A plot of the rational function \(w\text{.}\)
8.

Graph each of the following rational functions and decide whether or not each function has an inverse function. If an inverse function exists, find its formula. In addition, state the domain and range of each function you consider (the original function as well as its inverse function, if the inverse function exists).

  1. \(\displaystyle \displaystyle r(x) = -\frac{3}{x-4} + 5 \)

  2. \(\displaystyle \displaystyle s(x) = \frac{4 - 3x}{7x - 2}\)

  3. \(\displaystyle \displaystyle u(x) = \frac{2x - 1}{(x-1)^2}\)

  4. \(\displaystyle \displaystyle w(x) = \frac{11}{(x+4)^3} - 7\)

9.

For each of the following rational functions, identify the location of any potential hole in the graph. Then, create a table of function values for input values near where the hole should be located. Use your work to decide whether or not the graph indeed has a hole, with written justification.

  1. \(\displaystyle \displaystyle r(x) = \frac{x^2-16}{x+4}\)

  2. \(\displaystyle \displaystyle s(x) = \frac{(x-2)^2(x+3)}{x^2 - 5x - 6}\)

  3. \(\displaystyle \displaystyle u(x) = \frac{(x-2)^3(x+3)}{(x^2 - 5x - 6)(x-7)}\)

  4. \(\displaystyle \displaystyle w(x) = \frac{x^2 + x - 6}{(x^2 + 5x + 6)(x+3)}\)

  5. True or false: given \(r(x) = \frac{p(x)}{q(x)}\text{,}\) if \(p(a) = 0\) and \(q(a) = 0\text{,}\) then \(r\) has a hole at \(x = a\text{.}\)

10.

In the questions that follow, we explore the average rate of change of power functions on the interval \([1,x]\text{.}\) To begin, let \(f(x) = x^2\) and let \(A(x)\) be the average rate of change of \(f\) on \([1,x]\text{.}\)

  1. Explain why \(A\) is a rational function of \(x\text{.}\)

  2. What is the domain of \(A\text{?}\)

  3. At the point where \(A\) is undefined, does \(A\) have a vertical asymptote or a hole? Justify your thinking clearly.

  4. What can you say about the average rate of change of \(f\) on \([1,x]\) as \(x\) gets closer and closer (but not equal) to \(1\text{?}\)

  5. Now let \(g(x) = x^3\) and \(B(x)\) be the average rate of change of \(B\) on \([1,x]\text{.}\) Respond to prompts (a) - (d) but this time for the function \(B\) instead of \(A\text{.}\)

  6. Finally, let \(h(x) = x^4\) and \(C(x)\) be the average rate of change of \(C\) on \([1,x]\text{.}\) Respond to prompts (a) - (d) but this time for the function \(C\) instead of \(A\text{.}\)