$$\newcommand{\id}{\mathrm{id}}$$ $$\newcommand{\Span}{\mathrm{span}}$$ $$\newcommand{\kernel}{\mathrm{null}\,}$$ $$\newcommand{\range}{\mathrm{range}\,}$$ $$\newcommand{\RealPart}{\mathrm{Re}}$$ $$\newcommand{\ImaginaryPart}{\mathrm{Im}}$$ $$\newcommand{\Argument}{\mathrm{Arg}}$$ $$\newcommand{\norm}[1]{\| #1 \|}$$ $$\newcommand{\inner}[2]{\langle #1, #2 \rangle}$$ $$\newcommand{\Span}{\mathrm{span}}$$

# 4.1: Introduction to Rational Functions

$$\newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} }$$ $$\newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}}$$$$\newcommand{\id}{\mathrm{id}}$$ $$\newcommand{\Span}{\mathrm{span}}$$ $$\newcommand{\kernel}{\mathrm{null}\,}$$ $$\newcommand{\range}{\mathrm{range}\,}$$ $$\newcommand{\RealPart}{\mathrm{Re}}$$ $$\newcommand{\ImaginaryPart}{\mathrm{Im}}$$ $$\newcommand{\Argument}{\mathrm{Arg}}$$ $$\newcommand{\norm}[1]{\| #1 \|}$$ $$\newcommand{\inner}[2]{\langle #1, #2 \rangle}$$ $$\newcommand{\Span}{\mathrm{span}}$$ $$\newcommand{\id}{\mathrm{id}}$$ $$\newcommand{\Span}{\mathrm{span}}$$ $$\newcommand{\kernel}{\mathrm{null}\,}$$ $$\newcommand{\range}{\mathrm{range}\,}$$ $$\newcommand{\RealPart}{\mathrm{Re}}$$ $$\newcommand{\ImaginaryPart}{\mathrm{Im}}$$ $$\newcommand{\Argument}{\mathrm{Arg}}$$ $$\newcommand{\norm}[1]{\| #1 \|}$$ $$\newcommand{\inner}[2]{\langle #1, #2 \rangle}$$ $$\newcommand{\Span}{\mathrm{span}}$$

If we add, subtract or multiply polynomial functions according to the function arithmetic rules defined in Section 1.5, we will produce another polynomial function. If, on the other hand, we divide two polynomial functions, the result may not be a polynomial. In this chapter we study rational functions - functions which are ratios of polynomials.

Definition 4.1: Rational Functions

A rational function is a function which is the ratio of polynomial functions. Said differently, $$r$$ is a rational function if it is of the form

$r(x) = \dfrac{p(x)}{q(x)},$

where $$p$$ and $$q$$ are polynomial functions. According to this definition, all polynomial functions are also rational functions (take $$q(x) = 1$$).

As we recall from Section 1.4, we have domain issues anytime the denominator of a fraction is zero. In the example below, we review this concept as well as some of the arithmetic of rational expressions.

Example 4.1.1:

Find the domain of the following rational functions. Write them in the form $$\frac{p(x)}{q(x)}$$ for polynomial functions $$p$$ and $$q$$ and simplify.

1. $$f(x) = \dfrac{2x-1}{x+1}$$
2. $$g(x) = 2 - \dfrac{3}{x+1}$$
3. $$h(x) = \dfrac{2x^2-1}{x^2-1} - \dfrac{3x-2}{x^2-1}$$
4. $$r(x) = \dfrac{2x^2-1}{x^2-1} \div \dfrac{3x-2}{x^2-1}$$

Solution

1. To find the domain of $$f$$, we proceed as we did in Section 1.4: we find the zeros of the denominator and exclude them from the domain. Setting $$x+1=0$$ results in $$x=-1$$. Hence, our domain is $$(-\infty, -1) \cup (-1,\infty)$$. The expression $$f(x)$$ is already in the form requested and when we check for common factors among the numerator and denominator we find none, so we are done.

2. Proceeding as before, we determine the domain of $$g$$ by solving $$x+1=0$$. As before, we find the domain of $$g$$ is $$(-\infty, -1) \cup (-1,\infty)$$. To write $$g(x)$$ in the form requested, we need to get a common denominator

$\begin{array}{rclclcl} g(x) & = & 2 - \dfrac{3}{x+1} & = & \dfrac{2}{1} - \dfrac{3}{x+1} & = & \dfrac{(2)(x+1)}{(1)(x+1)} - \dfrac{3}{x+1} \\ & = & \dfrac{(2x+2) - 3}{x+1} & = & \dfrac{2x-1}{x+1} & & \\ \end{array}$

This formula is now completely simplified.

3. The denominators in the formula for $$h(x)$$ are both $$x^2-1$$ whose zeros are $$x = \pm 1$$. As a result, the domain of $$h$$ is $$(-\infty, -1) \cup (-1,1) \cup (1, \infty)$$. We now proceed to simplify $$h(x)$$. Since we have the same denominator in both terms, we subtract the numerators. We then factor the resulting numerator and denominator, and cancel out the common factor.

$\begin{array}{rclcl} h(x) & = & \dfrac{2x^2-1}{x^2-1} - \dfrac{3x-2}{x^2-1} & = & \dfrac{\left(2x^2-1\right) - \left(3x-2\right)}{x^2-1} \\ & = & \dfrac{2x^2-1 - 3x+2}{x^2-1} & = & \dfrac{2x^2 - 3x+1}{x^2-1} \\ & = & \dfrac{(2x-1)(x-1)}{(x+1)(x-1)} & = & \dfrac{(2x-1)\cancel{(x-1)}}{(x+1)\cancel{(x-1)}} \\ & = & \dfrac{2x-1}{x+1} & & \\ \end{array}$

4. To find the domain of $$r$$, it may help to temporarily rewrite $$r(x)$$ as

$r(x) = \dfrac{\dfrac{2x^2-1}{x^2-1} }{\dfrac{3x-2}{x^2-1}\vphantom{\left(\dfrac{X}{X}\right)}}$

We need to set all of the denominators equal to zero which means we need to solve not only $$x^2-1= 0$$, but also $$\frac{3x-2}{x^2-1}=0$$. We find $$x = \pm 1$$ for the former and $$x= \frac{2}{3}$$ for the latter. Our domain is $$(-\infty, -1) \cup \left(-1,\frac{2}{3}\right) \cup \left(\frac{2}{3},1\right) \cup (1, \infty)$$. We simplify $$r(x)$$ by rewriting the division as multiplication by the reciprocal and then by canceling the common factor

$\begin{array}{rclclcl} r(x) & = & \dfrac{2x^2-1}{x^2-1} \div \dfrac{3x-2}{x^2-1} & = & \dfrac{2x^2-1}{x^2-1} \cdot \dfrac{x^2-1}{3x-2} & = & \dfrac{\left(2x^2-1\right)\left(x^2-1\right)}{\left(x^2-1\right)(3x-2)} \\ & = & \dfrac{\left(2x^2-1\right)\cancel{\left(x^2-1\right)}}{\cancel{\left(x^2-1\right)}(3x-2)} & = & \dfrac{2x^2-1}{3x-2} & & \\ \end{array}$

A few remarks about Example 4.1.1 are in order. Note that the expressions for $$f(x)$$, $$g(x)$$ and $$h(x)$$ work out to be the same. However, only two of these functions are actually equal. Recall that functions are ultimately sets of ordered pairs, so for two functions to be equal, they need, among other things, to have the same domain (you scan review Sections 1.2 and 1.3 if this statement caught you off guard). Since $$f(x) = g(x)$$ and $$f$$ and $$g$$ have the same domain, they are equal functions. Even though the formula $$h(x)$$ is the same as $$f(x)$$, the domain of $$h$$ is different than the domain of $$f$$, and thus they are different functions.

We now turn our attention to the graphs of rational functions. Consider the function $$f(x) = \frac{2x-1}{x+1}$$ from Example 4.1.1. Using a graphing calculator, we obtain

Two behaviors of the graph are worthy of further discussion. First, note that the graph appears to 'break' at $$x=-1$$. We know from our last example that $$x=-1$$ is not in the domain of $$f$$ which means $$f(-1)$$ is undefined. When we make a table of values to study the behavior of $$f$$ near $$x=-1$$ we see that we can get 'near' $$x=-1$$ from two directions. We can choose values a little less than $$-1$$, for example $$x=-1.1$$, $$x=-1.01$$, $$x=-1.001$$, and so on. These values are said to 'approach $$-1$$ from the left.' Similarly, the values $$x=-0.9$$, $$x=-0.99$$, $$x=-0.999$$, etc., are said to 'approach $$-1$$ from the right.' If we make two tables, we find that the numerical results confirm what we see graphically.

As the $$x$$ values approach $$-1$$ from the left, the function values become larger and larger positive numbers.\footnote{We would need Calculus to confirm this analytically.} We express this symbolically by stating as $$x \rightarrow -1^{-}$$, $$f(x) \rightarrow \infty$$. Similarly, using analogous notation, we conclude from the table that as $$x \rightarrow -1^{+}$$, $$f(x) \rightarrow -\infty$$. For this type of unbounded behavior, we say the graph of $$y=f(x)$$ has a vertical asymptote of $$x = -1$$. Roughly speaking, this means that near $$x=-1$$, the graph looks very much like the vertical line $$x=-1$$.

The other feature worthy of note about the graph of $$y=f(x)$$ is that it seems to 'level off' on the left and right hand sides of the screen. This is a statement about the end behavior of the function. As we discussed in Section 3.1, the end behavior of a function is its behavior as $$x$$ as $$x$$ attains larger\footnote{Here, the word 'larger' means larger in absolute value.} and larger negative values without bound, $$x \rightarrow -\infty$$, and as $$x$$ becomes large without bound, $$x \rightarrow \infty$$. Making tables of values, we find

From the tables, we see that as $$x \rightarrow -\infty$$, $$f(x) \rightarrow 2^{+}$$ and as $$x \rightarrow \infty$$, $$f(x) \rightarrow 2^{-}$$. Here the '$$+$$' means 'from above' and the '$$-$$' means 'from below'. In this case, we say the graph of $$y=f(x)$$ has a $$\textbf{horizontal asymptote}$$ of $$y=2$$. This means that the end behavior of $$f$$ resembles the horizontal line $$y=2$$, which explains the 'leveling off' behavior we see in the calculator's graph. We formalize the concepts of vertical and horizontal asymptotes in the following definitions.

Definition 4.2: Vertical Asymptote

The line $$x=c$$ is called a vertical asymptote of the graph of a function $$y=f(x)$$ if as $$x \rightarrow c^{-}$$ or as $$x \rightarrow c^{+}$$, either $$f(x) \rightarrow \infty$$ or $$f(x) \rightarrow -\infty$$.

Definition 4.3: Horizontal Asymptote

The line $$y=c$$ is called a horizontal asymptote of the graph of a function $$y=f(x)$$ if as $$x \rightarrow -\infty$$ or as $$x \rightarrow \infty$$, $$f(x) \rightarrow c$$.

Note that in Definition 4.3, we write $$f(x) \rightarrow c$$ (not $$f(x) \rightarrow c^{+}$$ or $$f(x) \rightarrow c^{-}$$) because we are unconcerned from which direction the values $$f(x)$$ approach the value $$c$$, just as long as they do so.\footnote{As we shall see in the next section, the graphs of rational functions may, in fact, cross their horizontal asymptotes. If this happens, however, it does so only a finite number of times, and so for each choice of $$x \rightarrow -\infty$$ and $$x \rightarrow \infty$$, $$f(x)$$ will approach $$c$$ from either below (in the case $$f(x) \rightarrow c^{-}$$) or above (in the case $$f(x) \rightarrow c^{+}$$.) We leave $$f(x) \rightarrow c$$ generic in our definition, however, to allow this concept to apply to less tame specimens in the Precalculus zoo, such as in Section 10.5.}

In our discussion following Example 4.1.1, we determined that, despite the fact that the formula for $$h(x)$$ reduced to the same formula as $$f(x)$$, the functions $$f$$ and $$h$$ are different, since $$x=1$$ is in the domain of $$f$$, but $$x=1$$ is not in the domain of $$h$$. If we graph $$h(x)=\frac{2x^2-1}{x^2-1} - \frac{3x-2}{x^2-1}$$ using a graphing calculator, we are surprised to find that the graph looks identical to the graph of $$y=f(x)$$. There is a vertical asymptote at $$x=-1$$, but near $$x=1$$, everything seem fine. Tables of values provide numerical evidence which supports the graphical observation.

We see that as $$x \rightarrow 1^{-}$$, $$h(x) \rightarrow 0.5^{-}$$ and as $$x \rightarrow 1^{+}$$, $$h(x) \rightarrow 0.5^{+}$$. In other words, the points on the graph of $$y=h(x)$$ are approaching $$(1,0.5)$$, but since $$x=1$$ is not in the domain of $$h$$, it would be inaccurate to fill in a point at $$(1,0.5)$$. As we've done in past sections when something like this occurs,\footnote{For instance, graphing piecewise defined functions in Section 1.6.} we put an open circle (also called a {\bf hole}\index{hole ! in a graph}\index{graph ! hole in} in this case\footnote{In Calculus, we will see how these 'holes' can be 'plugged' when embarking on a more advanced study of continuity.}) at $$(1,0.5)$$. Below is a detailed graph of $$y=h(x)$$, with the vertical and horizontal asymptotes as dashed lines.

Neither $$x=-1$$ nor $$x=1$$ are in the domain of $$h$$, yet the behavior of the graph of $$y=h(x)$$ is drastically different near these $$x$$-values. The reason for this lies in the second to last step when we simplified the formula for $$h(x)$$ in Example 4.1.1, where we had $$h(x) = \frac{(2x-1)(x-1)}{(x+1)(x-1)}$$. The reason $$x=-1$$ is not in the domain of $$h$$ is because the factor $$(x+1)$$ appears in the denominator of $$h(x)$$; similarly, $$x=1$$ is not in the domain of $$h$$ because of the factor $$(x-1)$$ in the denominator of $$h(x)$$. The major difference between these two factors is that $$(x-1)$$ cancels with a factor in the numerator whereas $$(x+1)$$ does not. Loosely speaking, the trouble caused by $$(x-1)$$ in the denominator is canceled away while the factor $$(x+1)$$ remains to cause mischief. This is why the graph of $$y=h(x)$$ has a vertical asymptote at $$x=-1$$ but only a hole at $$x=1$$. These observations are generalized and summarized in the theorem below, whose proof is found in Calculus.

Theorem 4.1: Location of Vertical Asymptotes and Holes

Suppose $$r$$ is a rational function which can be written as $$r(x) = \frac{p(x)}{q(x)}$$ where $$p$$ and $$q$$ have no common zeros.\footnote{In other words, $$r(x)$$ is in lowest terms.} Let $$c$$ be a real number which is not in the domain of $$r$$.

• If $$q(c) \neq 0$$, then the graph of $$y=r(x)$$ has a hole at $$\left(c, \frac{p(c)}{q(c)}\right)$$.
• If $$q(c) = 0$$, then the line $$x=c$$ is a vertical asymptote of the graph of $$y=r(x)$$.

In English, Theorem 4.1 says that if $$x=c$$ is not in the domain of $$r$$ but, when we simplify $$r(x)$$, it no longer makes the denominator $$0$$, then we have a hole at $$x=c$$. Otherwise, the line $$x=c$$ is a vertical asymptote of the graph of $$y=r(x)$$.

Example $$\PageIndex{2}$$: Finding Vertical Asymptotes

Find the vertical asymptotes of, and/or holes in, the graphs of the following rational functions. Verify your answers using a graphing calculator, and describe the behavior of the graph near them using proper notation.

1. $$f(x) = \dfrac{2x}{x^2-3}$$
2. $$g(x) = \dfrac{x^2-x-6}{x^2-9}$$
3. $$h(x) = \dfrac{x^2-x-6}{x^2+9}$$
4. $$r(x) = \dfrac{x^2-x-6}{x^2+4x+4}$$

Solution

1. To use Theorem 4.1, we first find all of the real numbers which aren't in the domain of $$f$$. To do so, we solve $$x^2 - 3 = 0$$ and get $$x = \pm \sqrt{3}$$. Since the expression $$f(x)$$ is in lowest terms, there is no cancellation possible, and we conclude that the lines $$x = -\sqrt{3}$$ and $$x=\sqrt{3}$$ are vertical asymptotes to the graph of $$y=f(x)$$. The calculator verifies this claim, and from the graph, we see that as $$x \rightarrow -\sqrt{3}^{\, -}$$, $$f(x) \rightarrow -\infty$$, as $$x\rightarrow -\sqrt{3}^{\, +}$$, $$f(x) \rightarrow \infty$$, as $$x \rightarrow \sqrt{3}^{\, -}$$, $$f(x) \rightarrow -\infty$$, and finally as $$x\rightarrow \sqrt{3}^{\, +}$$, $$f(x) \rightarrow \infty$$.
2. Solving $$x^2 - 9 = 0$$ gives $$x = \pm 3$$. In lowest terms $$g(x) = \frac{x^2-x-6}{x^2-9} = \frac{(x-3)(x+2)}{(x-3)(x+3)} = \frac{x+2}{x+3}$$. Since $$x=-3$$ continues to make trouble in the denominator, we know the line $$x=-3$$ is a vertical asymptote of the graph of $$y=g(x)$$. Since $$x=3$$ no longer produces a $$0$$ in the denominator, we have a hole at $$x=3$$. To find the $$y$$-coordinate of the hole, we substitute $$x=3$$ into $$\frac{x+2}{x+3}$$ and find the hole is at $$\left(3, \frac{5}{6}\right)$$. When we graph $$y=g(x)$$ using a calculator, we clearly see the vertical asymptote at $$x=-3$$, but everything seems calm near $$x=3$$. Hence, as $$x \rightarrow -3^{-}$$, $$g(x) \rightarrow \infty$$, as $$x \rightarrow -3^{+}$$, $$g(x) \rightarrow -\infty$$, as $$x \rightarrow 3^{-}$$, $$g(x) \rightarrow \frac{5}{6}^{-}$$, and as $$x \rightarrow 3^{+}$$, $$g(x) \rightarrow \frac{5}{6}^{+}$$.

3. The domain of $$h$$ is all real numbers, since $$x^2+9 = 0$$ has no real solutions. Accordingly, the graph of $$y=h(x)$$ is devoid of both vertical asymptotes and holes.

4. Setting $$x^2+4x+4 = 0$$ gives us $$x=-2$$ as the only real number of concern. Simplifying, we see $r(x) = \frac{x^2-x-6}{x^2+4x+4} = \frac{(x-3)(x+2)}{(x+2)^2} = \frac{x-3}{x+2}.$ Since $$x=-2$$ continues to produce a $$0$$ in the denominator of the reduced function, we know $$x=-2$$ is a vertical asymptote to the graph. The calculator bears this out, and, moreover, we see that as $$x\rightarrow -2^{-}$$, $$r(x) \rightarrow \infty$$ and as $$x \rightarrow -2^{+}$$, $$r(x) \rightarrow -\infty$$.

Our next example gives us a physical interpretation of a vertical asymptote. This type of model arises from a family of equations cheerily named 'doomsday' equations. These functions arise in Differential Equations. The unfortunate name will make sense shortly.

Example $$\PageIndex{3}$$: Doomsday Equations

A mathematical model for the population $$P$$, in thousands, of a certain species of bacteria, $$t$$ days after it is introduced to an environment is given by $$P(t) = \frac{100}{(5-t)^{2}}$$, $$0 \leq t < 5$$.

1. Find and interpret $$P(0)$$.
2. When will the population reach $$100,\!000$$?
3. Determine the behavior of $$P$$ as $$t \rightarrow 5^{-}$$. Interpret this result graphically and within the context of the problem.

Solution

1. Substituting $$t=0$$ gives $$P(0) = \frac{100}{(5-0)^2} = 4$$, which means $$4000$$ bacteria are initially introduced into the environment.
2. To find when the population reaches $$100,\! 000$$, we first need to remember that $$P(t)$$ is measured in thousands. In other words, $$100,\! 000$$ bacteria corresponds to $$P(t) = 100$$. Substituting for $$P(t)$$ gives the equation $$\frac{100}{(5-t)^2} = 100$$. Clearing denominators and dividing by $$100$$ gives $$(5-t)^2=1$$, which, after extracting square roots, produces $$t = 4$$ or $$t=6$$. Of these two solutions, only $$t=4$$ in in our domain, so this is the solution we keep. Hence, it takes $$4$$ days for the population of bacteria to reach $$100,\! 000$$.
3. To determine the behavior of $$P$$ as $$t \rightarrow 5^{-}$$, we can make a table

In other words, as $$t \rightarrow 5^{-}$$, $$P(t) \rightarrow \infty$$. Graphically, the line $$t=5$$ is a vertical asymptote of the graph of $$y=P(t)$$. Physically, this means that the population of bacteria is increasing without bound as we near 5 days, which cannot actually happen. For this reason, $$t=5$$ is called the 'doomsday' for this population. There is no way any environment can support infinitely many bacteria, so shortly before $$t = 5$$ the environment would collapse. $$\Box$$

Now that we have thoroughly investigated vertical asymptotes, we can turn our attention to horizontal asymptotes. The next theorem tells us when to expect horizontal asymptotes.

Theorem 4.2: Location of Horizontal Asymptotes

Suppose $$r$$ is a rational function and $$r(x) = \frac{p(x)}{q(x)}$$, where $$p$$ and $$q$$ are polynomial functions with leading coefficients $$a$$ and $$b$$, respectively.

• If the degree of $$p(x)$$ is the same as the degree of $$q(x)$$, then $$y=\frac{a}{b}$$ is the horizontal asymptote of the graph of $$y=r(x)$$.
• If the degree of $$p(x)$$ is less than the degree of $$q(x)$$, then $$y=0$$ is the horizontal asymptote of the graph of $$y=r(x)$$.
• If the degree of $$p(x)$$ is greater than the degree of $$q(x)$$, then the graph of $$y=r(x)$$ has no horizontal asymptotes.

Like Theorem 4.1, Theorem 4.2 is proved using Calculus. Nevertheless, we can understand the idea behind it using our example $$f(x) = \frac{2x-1}{x+1}$$. If we interpret $$f(x)$$ as a division problem, $$(2x-1) \div (x+1)$$, we find that the quotient is $$2$$ with a remainder of $$-3$$. Using what we know about polynomial division, specifically Theorem 3.4, we get $$2x-1 = 2(x+1) -3$$. Dividing both sides by $$(x+1)$$ gives $$\frac{2x-1}{x+1} = 2 - \frac{3}{x+1}$$. (You may remember this as the formula for $$g(x)$$ in Example 4.1.1.) As $$x$$ becomes unbounded in either direction, the quantity $$\frac{3}{x+1}$$ gets closer and closer to $$0$$ so that the values of $$f(x)$$ become closer and closer\footnote{As seen in the tables immediately preceding Definition \ref{va}.} to $$2$$. In symbols, as $$x \rightarrow \pm \infty$$, $$f(x) \rightarrow 2$$, and we have the result.\footnote{More specifically, as $$x \rightarrow -\infty$$, $$f(x) \rightarrow 2^{+}$$, and as $$x \rightarrow \infty$$, $$f(x) \rightarrow 2^{-}$$.} Notice that the graph gets close to the same $$y$$ value as $$x \rightarrow -\infty$$ or $$x \rightarrow \infty$$. This means that the graph can have only \underline{one} horizontal asymptote if it is going to have one at all. Thus we were justified in using 'the' in the previous theorem.

Alternatively, we can use what we know about end behavior of polynomials to help us understand this theorem. From Theorem 3.2, we know the end behavior of a polynomial is determined by its leading term. Applying this to the numerator and denominator of $$f(x)$$, we get that as $$x \rightarrow \pm \infty$$, $$f(x) = \frac{2x-1}{x+1} \approx \frac{2x}{x} = 2$$. This last approach is useful in Calculus, and, indeed, is made rigorous there. (Keep this in mind for the remainder of this paragraph.) Applying this reasoning to the general case, suppose $$r(x) = \frac{p(x)}{q(x)}$$ where $$a$$ is the leading coefficient of $$p(x)$$ and $$b$$ is the leading coefficient of $$q(x)$$. As $$x \rightarrow \pm \infty$$, $$r(x) \approx \frac{ax^n}{bx^m}$$, where $$n$$ and $$m$$ are the degrees of $$p(x)$$ and $$q(x)$$, respectively. If the degree of $$p(x)$$ and the degree of $$q(x)$$ are the same, then $$n=m$$ so that $$r(x) \approx \frac{a}{b}$$, which means $$y=\frac{a}{b}$$ is the horizontal asymptote in this case. If the degree of $$p(x)$$ is less than the degree of $$q(x)$$, then $$n < m$$, so $$m-n$$ is a positive number, and hence, $$r(x) \approx \frac{a}{bx^{m-n}} \rightarrow 0$$ as $$x \rightarrow \pm \infty$$. If the degree of $$p(x)$$ is greater than the degree of $$q(x)$$, then $$n > m$$, and hence $$n-m$$ is a positive number and $$r(x) \approx \frac{ax^{n-m}}{ b}$$, which becomes unbounded as $$x \rightarrow \pm \infty$$. As we said before, if a rational function has a horizontal asymptote, then it will have only one. (This is not true for other types of functions we shall see in later chapters.)

Example $$\PageIndex{4}$$:

List the horizontal asymptotes, if any, of the graphs of the following functions. Verify your answers using a graphing calculator, and describe the behavior of the graph near them using proper notation.

1. $$f(x) = \dfrac{5x}{x^2+1}$$
2. $$g(x) = \dfrac{x^2-4}{x+1}$$
3. $$h(x) = \dfrac{6x^3-3x+1}{5-2x^3}$$

Solution

1. The numerator of $$f(x)$$ is $$5x$$, which has degree $$1$$. The denominator of $$f(x)$$ is $$x^2+1$$, which has degree $$2$$. Applying Theorem 4.2, $$y=0$$ is the horizontal asymptote. Sure enough, we see from the graph that as $$x \rightarrow - \infty$$, $$f(x) \rightarrow 0^{-}$$ and as $$x \rightarrow \infty$$, $$f(x) \rightarrow 0^{+}$$.
2. The numerator of $$g(x)$$, $$x^2-4$$, has degree $$2$$, but the degree of the denominator, $$x+1$$, has degree $$1$$. By Theorem 4.2, there is no horizontal asymptote. From the graph, we see that the graph of $$y=g(x)$$ doesn't appear to level off to a constant value, so there is no horizontal asymptote.\footnote{Sit tight! We'll revisit this function and its end behavior shortly.}
3. The degrees of the numerator and denominator of $$h(x)$$ are both three, so Theorem 4.2 tells us $$y = \frac{6}{-2} = -3$$ is the horizontal asymptote. We see from the calculator's graph that as $$x \rightarrow -\infty$$, $$h(x) \rightarrow -3^{+}$$, and as $$x \rightarrow \infty$$, $$h(x) \rightarrow -3^{-}$$.

Our next example of the section gives us a real-world application of a horizontal asymptote.\footnote{Though the population below is more accurately modeled with the functions in Chapter 6, we approximate it (using Calculus, of course!) using a rational function.}

Example $$\PageIndex{5}$$:

The number of students $$N$$ at local college who have had the flu $$t$$ months after the semester begins can be modeled by the formula $$N(t) = 500 - \frac{450}{1+3t}$$ for $$t \geq 0$$.

1. Find and interpret $$N(0)$$.
2. How long will it take until $$300$$ students will have had the flu?
3. Determine the behavior of $$N$$ as $$t \rightarrow \infty$$. Interpret this result graphically and within the context of the problem.

Solution

1. $$N(0) = 500 - \frac{450}{1+3(0)} = 50$$. This means that at the beginning of the semester, $$50$$ students have had the flu.
2. We set $$N(t) = 300$$ to get $$500 - \frac{450}{1+3t} = 300$$ and solve. Isolating the fraction gives $$\frac{450}{1+3t} = 200$$. Clearing denominators gives $$450 = 200(1+3t)$$. Finally, we get $$t = \frac{5}{12}$$. This means it will take $$\frac{5}{12}$$ months, or about 13 days, for $$300$$ students to have had the flu.
3. To determine the behavior of $$N$$ as $$t\rightarrow \infty$$, we can use a table.

The table suggests that as $$t \rightarrow \infty$$, $$N(t) \rightarrow 500$$. (More specifically, $$500^{-}$$.) This means as time goes by, only a total of 500 students will have ever had the flu. $$\Box$$

We close this section with a discussion of the third (and final!) kind of asymptote which can be associated with the graphs of rational functions. Let us return to the function $$g(x) = \frac{x^2-4}{x+1}$$ in Example 4.1.4. Performing long division,\footnote{See the remarks following Theorem 4.2.} we get $$g(x) = \frac{x^2-4}{x+1} = x-1 - \frac{3}{x+1}$$. Since the term $$\frac{3}{x+1} \rightarrow 0$$ as $$x \rightarrow \pm \infty$$, it stands to reason that as $$x$$ becomes unbounded, the function values $$g(x) = x-1 - \frac{3}{x+1} \approx x-1$$. Geometrically, this means that the graph of $$y=g(x)$$ should resemble the line $$y = x-1$$ as $$x \rightarrow \pm \infty$$. We see this play out both numerically and graphically below.

The way we symbolize the relationship between the end behavior of $$y=g(x)$$ with that of the line $$y=x-1$$ is to write 'as $$x \rightarrow \pm \infty$$, $$g(x) \rightarrow x-1$$.' In this case, we say the line $$y=x-1$$ is a $$\textbf{slant asymptote}$$\footnote{Also called an 'oblique' asymptote in some, ostensibly higher class (and more expensive), texts.} to the graph of $$y=g(x)$$. Informally, the graph of a rational function has a slant asymptote if, as $$x \rightarrow \infty$$ or as $$x \rightarrow -\infty$$, the graph resembles a non-horizontal, or 'slanted' line. Formally, we define a slant asymptote as follows.

Definition 4.4: Slant Asymptote

The line $$y = mx+b$$ where $$m \neq 0$$ is called a slant asymptote of the graph of a function $$y=f(x)$$ if as $$x \rightarrow -\infty$$ or as $$x \rightarrow \infty$$, $$f(x) \rightarrow mx+b$$.

A few remarks are in order. First, note that the stipulation $$m \neq 0$$ in Definition 4.4 is what makes the 'slant' asymptote 'slanted' as opposed to the case when $$m=0$$ in which case we'd have a horizontal asymptote. Secondly, while we have motivated what me mean intuitively by the notation '$$f(x) \rightarrow mx+b$$,' like so many ideas in this section, the formal definition requires Calculus. Another way to express this sentiment, however, is to rephrase '$$f(x) \rightarrow mx+b$$' as '$$f(x) - (mx+b) \rightarrow 0$$.' In other words, the graph of $$y=f(x)$$ has the slant asymptote $$y = mx+b$$ if and only if the graph of $$y = f(x) - (mx+b)$$ has a horizontal asymptote $$y=0$$.

Our next task is to determine the conditions under which the graph of a rational function has a slant asymptote, and if it does, how to find it. In the case of $$g(x) = \frac{x^2-4}{x+1}$$, the degree of the numerator $$x^2-4$$ is $$2$$, which is exactly one more than the degree if its denominator $$x+1$$ which is $$1$$. This results in a linear quotient polynomial, and it is this quotient polynomial which is the slant asymptote. Generalizing this situation gives us the following theorem.\footnote{Once again, this theorem is brought to you courtesy of Theorem 3.4 and Calculus.}

Theorem 4.3: Determination of Slant Asymptotes

Suppose $$r$$ is a rational function and $$r(x) = \frac{p(x)}{q(x)}$$, where the degree of $$p$$ is exactly one more than the degree of $$q$$. Then the graph of $$y=r(x)$$ has the slant asymptote $$y=L(x)$$ where $$L(x)$$ is the quotient obtained by dividing $$p(x)$$ by $$q(x)$$.

In the same way that Theorem 4.2 gives us an easy way to see if the graph of a rational function $$r(x) = \frac{p(x)}{q(x)}$$ has a horizontal asymptote by comparing the degrees of the numerator and denominator, Theorem 4.3 gives us an easy way to check for slant asymptotes. Unlike Theorem 4.2, which gives us a quick way to find the horizontal asymptotes (if any exist), Theorem 4.3 gives us no such 'short-cut'. If a slant asymptote exists, we have no recourse but to use long division to find it.\footnote{That's OK, though. In the next section, we'll use long division to analyze end behavior and it's worth the effort!}

Example $$\PageIndex{6}$$:

Find the slant asymptotes of the graphs of the following functions if they exist. Verify your answers using a graphing calculator and describe the behavior of the graph near them using proper notation.

1. $$f(x) = \dfrac{x^2-4x+2}{1-x}$$
2. $$g(x) = \dfrac{x^2-4}{x-2}$$
3. $$h(x) = \dfrac{x^3+1}{x^2-4}$$

Solution

\begin{enumerate}

1. The degree of the numerator is $$2$$ and the degree of the denominator is $$1$$, so Theorem 4.3 guarantees us a slant asymptote. To find it, we divide $$1-x = -x+1$$ into $$x^2-4x+2$$ and get a quotient of $$-x+3$$, so our slant asymptote is $$y=-x+3$$. We confirm this graphically, and we see that as $$x \rightarrow -\infty$$, the graph of $$y=f(x)$$ approaches the asymptote from below, and as $$x \rightarrow \infty$$, the graph of $$y=f(x)$$ approaches the asymptote from above.\footnote{Note that we are purposefully avoiding notation like 'as $$x\rightarrow \infty$$, $$f(x) \rightarrow (-x+3)^{+}$$. While it is possible to define these notions formally with Calculus, it is not standard to do so. Besides, with the introduction of the symbol '\textinterrobang' in the next section, the authors feel we are in enough trouble already.}
2. As with the previous example, the degree of the numerator $$g(x) = \frac{x^2-4}{x-2}$$ is $$2$$ and the degree of the denominator is $$1$$, so Theorem 4.3 applies. In this case, $g(x) = \frac{x^2-4}{x-2} = \frac{(x+2)(x-2)}{(x-2)} = \frac{(x+2) \cancel{(x-2)}}{\cancelto{1}{(x-2)}} = x+2, \quad x \neq 2$ so we have that the slant asymptote $$y=x+2$$ is identical to the graph of $$y=g(x)$$ except at $$x=2$$ (where the latter has a 'hole' at $$(2,4)$$.) The calculator supports this claim.\footnote{While the word 'asymptote' has the connotation of 'approaching but not equaling,' Definitions 4.3 and 4.4 invite the same kind of pathologies we saw with Definitions 1.11 in Section 1.6.}
3. For $$h(x) = \frac{x^3+1}{x^2-4}$$, the degree of the numerator is $$3$$ and the degree of the denominator is $$2$$ so again, we are guaranteed the existence of a slant asymptote. The long division $$\left(x^3+1 \right) \div \left(x^2-4\right)$$ gives a quotient of just $$x$$, so our slant asymptote is the line $$y=x$$. The calculator confirms this, and we find that as $$x \rightarrow -\infty$$, the graph of $$y=h(x)$$ approaches the asymptote from below, and as $$x \rightarrow \infty$$, the graph of $$y=h(x)$$ approaches the asymptote from above.

The reader may be a bit disappointed with the authors at this point owing to the fact that in Examples 4.1.2, 4.1.4, and 4.1.6, we used the calculator to determine function behavior near asymptotes. We rectify that in the next section where we, in excruciating detail, demonstrate the usefulness of 'number sense' to reveal this behavior analytically.

## Contributors

• Carl Stitz, Ph.D. (Lakeland Community College) and Jeff Zeager, Ph.D. (Lorain County Community College)