Skip to main content
Mathematics LibreTexts

3.7: Rational Functions

  • Page ID
    117121
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\dsum}{\displaystyle\sum\limits} \)

    \( \newcommand{\dint}{\displaystyle\int\limits} \)

    \( \newcommand{\dlim}{\displaystyle\lim\limits} \)

    \( \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}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \(\newcommand{\longvect}{\overrightarrow}\)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    Using Arrow Notation

    We have seen the graphs of the basic reciprocal function and the squared reciprocal function from our study of toolkit functions. Examine these graphs, as shown in Figure \(\PageIndex{1}\), and notice some of their features.

    Graphs of f(x)=1/x and f(x)=1/x^2
    Figure \(\PageIndex{1}\)

    Several things are apparent if we examine the graph of \(f(x)=\frac{1}{x}\).

    • On the left branch of the graph, the curve approaches the \(x\)-axis \((y=0)\) as \(x\rightarrow -\infty\).
    • As the graph approaches \(x = 0\) from the left, the curve drops, but as we approach zero from the right, the curve rises.
    • Finally, on the right branch of the graph, the curves approaches the \(x\)-axis \((y=0) \) as \(x\rightarrow \infty\).

    To summarize, we use arrow notation to show that \(x\) or \(f (x)\) is approaching a particular value (Table \(\PageIndex{1}\)).

    Table \(\PageIndex{1}\)
    Symbol Meaning
    \(x\rightarrow a^-\) \(x\) approaches a from the left (\(x<a\) but close to \(a\) )
    \(x\rightarrow a^+\) \(x\) approaches a from the right (\(x>a\) but close to \(a\) )
    \(x\rightarrow \infty\) \(x\) approaches infinity (\(x\) increases without bound)
    \(x\rightarrow −\infty\) \(x\) approaches negative infinity (\(x\) decreases without bound)
    \(f(x)\rightarrow \infty\) the output approaches infinity (the output increases without bound)
    \(f(x)\rightarrow −\infty\) the output approaches negative infinity (the output decreases without bound)
    \(f(x)\rightarrow a\) the output approaches \(a\)

    Local Behavior of \(f(x)=\frac{1}{x}\)

    Let’s begin by looking at the reciprocal function, \(f(x)=\frac{1}{x}\). We cannot divide by zero, which means the function is undefined at \(x=0\); so zero is not in the domain. As the input values approach zero from the left side (becoming very small, negative values), the function values decrease without bound (in other words, they approach negative infinity). We can see this behavior in Table \(\PageIndex{2}\).

    Table \(\PageIndex{2}\)
    \(x\) –0.1 –0.01 –0.001 –0.0001
    \(f(x)=\frac{1}{x}\) –10 –100 –1000 –10,000

    We write in arrow notation

    as \(x\rightarrow 0^−,f(x)\rightarrow −\infty\)

    As the input values approach zero from the right side (becoming very small, positive values), the function values increase without bound (approaching infinity). We can see this behavior in Table \(\PageIndex{3}\).

    Table \(\PageIndex{3}\)
    \(x\) 0.1 0.01 0.001 0.0001
    \(f(x)=\frac{1}{x}\) 10 100 1000 10,000

    We write in arrow notation

    As \(x\rightarrow 0^+, f(x)\rightarrow \infty\).

    See Figure \(\PageIndex{2}\).

    Graph of f(x)=1/x which denotes the end behavior. As x goes to negative infinity, f(x) goes to 0, and as x goes to 0^-, f(x) goes to negative infinity. As x goes to positive infinity, f(x) goes to 0, and as x goes to 0^+, f(x) goes to positive infinity.
    Figure \(\PageIndex{2}\).

    This behavior creates a vertical asymptote, which is a vertical line that the graph approaches but never crosses. In this case, the graph is approaching the vertical line \(x=0\) as the input becomes close to zero (Figure \(\PageIndex{3}\)).

    Graph of f(x)=1/x with its vertical asymptote at x=0.
    Figure \(\PageIndex{3}\).
    Definition: VERTICAL ASYMPTOTE

    A vertical asymptote of a graph is a vertical line \(x=a\) where the graph tends toward positive or negative infinity as the inputs approach \(a\). We write

    As \(x\rightarrow a\), \(f(x)\rightarrow \infty\), or as \(x\rightarrow a\), \(f(x)\rightarrow −\infty\).

    End Behavior of \(f(x)=\frac{1}{x}\)

    As the values of \(x\) approach infinity, the function values approach \(0\). As the values of \(x\) approach negative infinity, the function values approach \(0\) (Figure \(\PageIndex{4}\)). Symbolically, using arrow notation

    As \(x\rightarrow \infty\), \(f(x)\rightarrow 0\),and as \(x\rightarrow −\infty\), \(f(x)\rightarrow 0\).

    Graph of f(x)=1/x which highlights the segments of the turning points to denote their end behavior.
    Figure \(\PageIndex{4}\).

    Based on this overall behavior and the graph, we can see that the function approaches 0 but never actually reaches 0; it seems to level off as the inputs become large. This behavior creates a horizontal asymptote, a horizontal line that the graph approaches as the input increases or decreases without bound. In this case, the graph is approaching the horizontal line \(y=0\). See Figure \(\PageIndex{5}\).

    Graph of f(x)=1/x with its vertical asymptote at x=0 and its horizontal asymptote at y=0.
    Figure \(\PageIndex{5}\).
    Definition: HORIZONTAL ASYMPTOTE

    A horizontal asymptote of a graph is a horizontal line \(y=b\) where the graph approaches the line as the inputs increase or decrease without bound. We write

    As \(x\rightarrow \infty \text{ or } x\rightarrow −\infty\), \(f(x)\rightarrow b\).

    Solving Applied Problems Involving Rational Functions

    In Example \(\PageIndex{2}\), we shifted a toolkit function in a way that resulted in the function \(f(x)=\frac{3x+7}{x+2}\). This is an example of a rational function. A rational function is a function that can be written as the quotient of two polynomial functions. Many real-world problems require us to find the ratio of two polynomial functions. Problems involving rates and concentrations often involve rational functions.

    Definition: RATIONAL FUNCTION

    A rational function is a function that can be written as the quotient of two polynomial functions \(P(x)\) and \(Q(x)\).

    \[f(x)=\dfrac{P(x)}{Q(x)}=\dfrac{a_px^p+a_{p−1}x^{p−1}+...+a_1x+a_0}{b_qx^q+b_{q−1}x^{q−1}+...+b_1x+b_0},\space Q(x)≠0\]

    Finding the Domains of Rational Functions

    A vertical asymptote represents a value at which a rational function is undefined, so that value is not in the domain of the function. A reciprocal function cannot have values in its domain that cause the denominator to equal zero. In general, to find the domain of a rational function, we need to determine which inputs would cause division by zero.

    Definition: DOMAIN OF A RATIONAL FUNCTION

    The domain of a rational function includes all real numbers except those that cause the denominator to equal zero.

    How To: Given a rational function, find the domain.
    1. Set the denominator equal to zero.
    2. Solve to find the x-values that cause the denominator to equal zero.
    3. The domain is all real numbers except those found in Step 2.

    Identifying Vertical Asymptotes of Rational Functions

    By looking at the graph of a rational function, we can investigate its local behavior and easily see whether there are asymptotes. We may even be able to approximate their location. Even without the graph, however, we can still determine whether a given rational function has any asymptotes, and calculate their location.

    Vertical Asymptotes

    The vertical asymptotes of a rational function may be found by examining the factors of the denominator that are not common to the factors in the numerator. Vertical asymptotes occur at the zeros of such factors.

    How To: Given a rational function, identify any vertical asymptotes of its graph
    1. Factor the numerator and denominator.
    2. Note any restrictions in the domain of the function.
    3. Reduce the expression by canceling common factors in the numerator and the denominator.
    4. Note any values that cause the denominator to be zero in this simplified version. These are where the vertical asymptotes occur.
    5. Note any restrictions in the domain where asymptotes do not occur. These are removable discontinuities, or “holes.”

    Removable Discontinuities

    Occasionally, a graph will contain a hole: a single point where the graph is not defined, indicated by an open circle. We call such a hole a removable discontinuity. For example, the function \(f(x)=\dfrac{x^2−1}{x^2−2x−3}\) may be re-written by factoring the numerator and the denominator.

    \[f(x)=\dfrac{(x+1)(x−1)}{(x+1)(x−3)} \nonumber \]

    Notice that \(x+1\) is a common factor to the numerator and the denominator. The zero of this factor, \(x=−1\), is the location of the removable discontinuity. Notice also that \( (x–3) \) is not a factor in both the numerator and denominator. The zero of this factor, \(x=3\), is the vertical asymptote. See Figure \(\PageIndex{11}\). [Note that removable discontinuities may not be visible when we use a graphing calculator, depending upon the window selected.]

    Graph of f(x)=(x^2-1)/(x^2-2x-3) with its vertical asymptote at x=3 and a removable discontinuity at x=-1.
    Figure \(\PageIndex{11}\).
    REMOVABLE DISCONTINUITIES OF RATIONAL FUNCTIONS

    A removable discontinuity occurs in the graph of a rational function at \(x=a\) if \(a\) is a zero for a factor in the denominator that is common with a factor in the numerator. We factor the numerator and denominator and check for common factors. If we find any, we set the common factor equal to 0 and solve. This is the location of the removable discontinuity. This is true if the multiplicity of this factor is greater than or equal to that in the denominator. If the multiplicity of this factor is greater in the denominator, then there is still an asymptote at that value.

    Identifying Horizontal Asymptotes of Rational Functions

    While vertical asymptotes describe the behavior of a graph as the output gets very large or very small, horizontal asymptotes help describe the behavior of a graph as the input gets very large or very small. Recall that a polynomial’s end behavior will mirror that of the leading term. Likewise, a rational function’s end behavior will mirror that of the ratio of the function that is the ratio of the leading terms.

    There are three distinct outcomes when checking for horizontal asymptotes:

    Case 1: If the degree of the denominator > degree of the numerator, there is a horizontal asymptote at \(y=0\).

    Example: \(f(x)=\dfrac{4x+2}{x^2+4x−5}\)

    In this case, the end behavior is \(f(x)≈\dfrac{4x}{x^2}=\dfrac{4}{x}\). This tells us that, as the inputs increase or decrease without bound, this function will behave similarly to the function \(g(x)=\dfrac{4}{x}\), and the outputs will approach zero, resulting in a horizontal asymptote at \(y=0\). See Figure \(\PageIndex{13}\). Note that this graph crosses the horizontal asymptote.

    Graph of f(x)=(4x+2)/(x^2+4x-5) with its vertical asymptotes at x=-5 and x=1 and its horizontal asymptote at y=0.
    Figure \(\PageIndex{13}\): Horizontal asymptote \(y=0\) when \(f(x)=\dfrac{p(x)}{q(x)}\), \(q(x)≠0\) where degree of \(p\) < degree of \(q\).

    Case 2: If the degree of the denominator < degree of the numerator by one, we get a slant asymptote.

    Example: \(f(x)=\dfrac{3x^2−2x+1}{x−1}\)

    In this case, the end behavior is \(f(x)≈\dfrac{3x^2}{x}=3x\). This tells us that as the inputs increase or decrease without bound, this function will behave similarly to the function \(g(x)=3x\). As the inputs grow large, the outputs will grow and not level off, so this graph has no horizontal asymptote. However, the graph of \(g(x)=3x\) looks like a diagonal line, and since \(f\) will behave similarly to \(g\), it will approach a line close to \(y=3x\). This line is a slant asymptote.

    To find the equation of the slant asymptote, divide \(\dfrac{3x^2−2x+1}{x−1}\). The quotient is \(3x+1\), and the remainder is 2. The slant asymptote is the graph of the line \(g(x)=3x+1\). See Figure \(\PageIndex{14}\).

    Graph of f(x)=(3x^2-2x+1)/(x-1) with its vertical asymptote at x=1 and a slant asymptote aty=3x+1.
    Figure \(\PageIndex{14}\): Slant asymptote when \(f(x)=\dfrac{p(x)}{q(x)}\), \(q(x)≠0\) where degree of \(p\) >degree of \(q\) by 1.

    Case 3: If the degree of the denominator = degree of the numerator, there is a horizontal asymptote at \(y=\dfrac{a_n}{b_n}\), where \(a_n\) and \(b_n\) are respectively the leading coefficients of \(p(x)\) and \(q(x)\) for \(f(x)=\dfrac{p(x)}{q(x)}\), \(q(x)≠0\).

    Example: \(f(x)=\dfrac{3x^2+2}{x^2+4x−5}\)

    In this case, the end behavior is \(f(x)≈\dfrac{3x^2}{x^2}=3\). This tells us that as the inputs grow large, this function will behave like the function \(g(x)=3\), which is a horizontal line. As \(x\rightarrow \pm \infty\), \(f(x)\rightarrow 3\), resulting in a horizontal asymptote at \(y=3\). See Figure \(\PageIndex{15}\). Note that this graph crosses the horizontal asymptote.

    Graph of f(x)=(3x^2+2)/(x^2+4x-5) with its vertical asymptotes at x=-5 and x=1 and its horizontal asymptote at y=3.
    Figure \(\PageIndex{15}\): Horizontal asymptote when \(f(x)=\dfrac{p(x)}{q(x)}\), \(q(x)≠0\) where degree of \(p\) = degree of \(q\).

    Notice that, while the graph of a rational function will never cross a vertical asymptote, the graph may or may not cross a horizontal or slant asymptote. Also, although the graph of a rational function may have many vertical asymptotes, the graph will have at most one horizontal (or slant) asymptote.

    It should be noted that, if the degree of the numerator is larger than the degree of the denominator by more than one, the end behavior of the graph will mimic the behavior of the reduced end behavior fraction. For instance, if we had the function

    \[f(x)=\dfrac{3x^5−x^2}{x+3} \nonumber \]

    with end behavior

    \[f(x)≈\dfrac{3x^5}{x}=3x^4 \nonumber \]

    the end behavior of the graph would look similar to that of an even polynomial with a positive leading coefficient.

    \(x\rightarrow \pm \infty, f(x)\rightarrow \infty\)
    HORIZONTAL ASYMPTOTES OF RATIONAL FUNCTIONS

    The horizontal asymptote of a rational function can be determined by looking at the degrees of the numerator and denominator.

    • Degree of numerator is less than degree of denominator: horizontal asymptote at \(y=0\).
    • Degree of numerator is greater than degree of denominator by one: no horizontal asymptote; slant asymptote.
    • Degree of numerator is equal to degree of denominator: horizontal asymptote at ratio of leading coefficients.
    Example \(\PageIndex{7}\): Identifying Horizontal and Slant Asymptotes

    For the functions listed, identify the horizontal or slant asymptote.

    1. \(g(x)=\dfrac{6x^3−10x}{2x^3+5x^2}\)
    2. \(h(x)=\dfrac{x^2−4x+1}{x+2}\)
    3. \(k(x)=\dfrac{x^2+4x}{x^3−8}\)

    Solution

    For these solutions, we will use \(f(x)=\dfrac{p(x)}{q(x)},\space q(x)≠0\).

    1. \(g(x)=\dfrac{6x^3−10x}{2x^3+5x^2}\): The degree of \(p = \) degree of \(q=3\), so we can find the horizontal asymptote by taking the ratio of the leading terms. There is a horizontal asymptote at \(y =\frac{6}{2}\) or \(y=3\).
    2. \(h(x)=\dfrac{x^2−4x+1}{x+2}\): The degree of \(p=2\) and degree of \(q=1\). Since \(p>q\) by 1, there is a slant asymptote found at \(\dfrac{x^2−4x+1}{x+2}\).
      clipboard_e5ff4f00a1466e92caa3ddac0dac32f5b.png
    3. \(k(x)=\dfrac{x^2+4x}{x^3−8}\) : The degree of \(p=2\) < degree of \(q=3\), so there is a horizontal asymptote \(y=0\).
    Example \(\PageIndex{8}\) Identifying Horizontal Asymptotes
    In the sugar concentration problem earlier, we created the equation \(C(t)=\dfrac{5+t}{100+10t}\).

    Find the horizontal asymptote and interpret it in context of the problem.

    Solution

    Both the numerator and denominator are linear (degree 1). Because the degrees are equal, there will be a horizontal asymptote at the ratio of the leading coefficients. In the numerator, the leading term is \(t\), with coefficient 1. In the denominator, the leading term is 10t, with coefficient 10. The horizontal asymptote will be at the ratio of these values:

    \(t\rightarrow \infty,\space C(t)\rightarrow \frac{1}{10}\)

    This function will have a horizontal asymptote at \(y=\frac{1}{10}\).

    This tells us that as the values of \(t\) increase, the values of \(C\) will approach \(\frac{1}{10}\). In context, this means that, as more time goes by, the concentration of sugar in the tank will approach one-tenth of a pound of sugar per gallon of water or \(\frac{1}{10}\) pounds per gallon.

    Example \(\PageIndex{9}\): Identifying Horizontal and Vertical Asymptotes

    Find the horizontal and vertical asymptotes of the function \(f(x)=\dfrac{(x−2)(x+3)}{(x−1)(x+2)(x−5)}\)

    Solution

    First, note that this function has no common factors, so there are no potential removable discontinuities.

    The function will have vertical asymptotes when the denominator is zero, causing the function to be undefined. The denominator will be zero at \(x=1,–2,\)and \(5\), indicating vertical asymptotes at these values.

    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 \(x\rightarrow \pm \infty\), \(f(x)\rightarrow 0\). This function will have a horizontal asymptote at \(y =0.\) See Figure \(\PageIndex{16}\).

    Graph of f(x)=(x-2)(x+3)/(x-1)(x+2)(x-5) with its vertical asymptotes at x=-2, x=1, and x=5 and its horizontal asymptote at y=0.
    Figure \(\PageIndex{16}\).
    Exercise \(\PageIndex{6}\)

    Find the vertical and horizontal asymptotes of the function:

    \(f(x)=\dfrac{(2x−1)(2x+1)}{(x−2)(x+3)}\)

    Answer

    Vertical asymptotes at \(x=2\) and \(x=–3\)

    horizontal asymptote at \(y =4\).

    INTERCEPTS OF RATIONAL FUNCTIONS

    A rational function will have a \(y\)-intercept at \(f(0),\) if the function is defined at zero. A rational function will not have a \(y\)-intercept if the function is not defined at zero.

    Likewise, a rational function will have \(x\)-intercepts at the inputs that cause the output to be zero. Since a fraction is only equal to zero when the numerator is zero, x-intercepts can only occur when the numerator of the rational function is equal to zero.

    Graphing Rational Functions

    In Example \(\PageIndex{10}\), we see that the numerator of a rational function reveals the x-intercepts of the graph, whereas the denominator reveals the vertical asymptotes of the graph. As with polynomials, factors of the numerator may have integer powers greater than one. Fortunately, the effect on the shape of the graph at those intercepts is the same as we saw with polynomials.

    The vertical asymptotes associated with the factors of the denominator will mirror one of the two toolkit reciprocal functions. When the degree of the factor in the denominator is odd, the distinguishing characteristic is that on one side of the vertical asymptote the graph heads towards positive infinity, and on the other side the graph heads towards negative infinity. See Figure \(\PageIndex{18}\).

    Graph of y=1/x with its vertical asymptote at x=0.
    Figure \(\PageIndex{18}\).

    When the degree of the factor in the denominator is even, the distinguishing characteristic is that the graph either heads toward positive infinity on both sides of the vertical asymptote or heads toward negative infinity on both sides. See Figure \(\PageIndex{19}\).

    Graph of y=1/x^2 with its vertical asymptote at x=0.
    Figure \(\PageIndex{19}\).

    For example, the graph of \(f(x)=\dfrac{{(x+1)}^2(x−3)}{{(x+3)}^2(x−2)}\) is shown in Figure \(\PageIndex{20}\).

    Graph of f(x)=(x+1)^2(x-3)/(x+3)^2(x-2) with its vertical asymptotes at x=-3 and x=2, its horizontal asymptote at y=1, and its intercepts at (-1, 0), (0, 1/6), and (3, 0).
    Figure \(\PageIndex{20}\).
    • At the x-intercept \(x=−1\) corresponding to the \({(x+1)}^2\) factor of the numerator, the graph "bounces", consistent with the quadratic nature of the factor.
    • At the x-intercept \(x=3\) corresponding to the \((x−3)\) factor of the numerator, the graph passes through the axis as we would expect from a linear factor.
    • At the vertical asymptote \(x=−3\) corresponding to the \({(x+3)}^2\) factor of the denominator, the graph heads towards positive infinity on both sides of the asymptote, consistent with the behavior of the function \(f(x)=\dfrac{1}{x^2}\).
    • At the vertical asymptote \(x=2\), corresponding to the \((x−2)\) factor of the denominator, the graph heads towards positive infinity on the left side of the asymptote and towards negative infinity on the right side, consistent with the behavior of the function \(f(x)=\dfrac{1}{x}\).
    Howto: Given a rational function, sketch a graph.
    1. Evaluate the function at 0 to find the y-intercept.
    2. Factor the numerator and denominator.
    3. For factors in the numerator not common to the denominator, determine where each factor of the numerator is zero to find the x-intercepts.
    4. Find the multiplicities of the x-intercepts to determine the behavior of the graph at those points.
    5. For factors in the denominator, note the multiplicities of the zeros to determine the local behavior. For those factors not common to the numerator, find the vertical asymptotes by setting those factors equal to zero and then solve.
    6. For factors in the denominator common to factors in the numerator, find the removable discontinuities by setting those factors equal to 0 and then solve.
    7. Compare the degrees of the numerator and the denominator to determine the horizontal or slant asymptotes.
    8. Sketch the graph.

    This page titled 3.7: Rational Functions is shared under a CC BY 4.0 license and was authored, remixed, and/or curated by OpenStax via source content that was edited to the style and standards of the LibreTexts platform.