<meta http-equiv="refresh" content="1; url=/nojavascript/"> Graphs of Rational Functions | CK-12 Foundation
You are reading an older version of this FlexBook® textbook: CK-12 Algebra I - Second Edition Go to the latest version.

12.2: Graphs of Rational Functions

Created by: CK-12

Learning Objectives

• Compare graphs of inverse variation equations.
• Graph rational functions.
• Solve real-world problems using rational functions.

Introduction

In this section, you’ll learn how to graph rational functions. Graphs of rational functions are very distinctive, because they get closer and closer to certain values but never reach those values. This behavior is called asymptotic behavior, and we will see that rational functions can have horizontal asymptotes, vertical asymptotes or oblique (or slant) asymptotes.

Compare Graphs of Inverse Variation Equations

Inverse variation problems are the simplest example of rational functions. We saw that an inverse variation has the general equation: $y= \frac{k}{x}$. In most real-world problems, $x$ and $y$ take only positive values. Below, we will show graphs of three inverse variation functions.

Example 1

On the same coordinate grid, graph inverse variation relationships with the proportionality constants $k = 1, k = 2,$ and $k = \frac{1}{2}$.

Solution

We’ll skip the table of values for this problem, and just show the graphs of the three functions on the same coordinate axes. Notice that for larger constants of proportionality, the curve decreases at a slower rate than for smaller constants of proportionality. This makes sense because the value of $y$ is related directly to the proportionality constants, so we should expect larger values of $y$ for larger values of $k$.

Graph Rational Functions

Now we’ll extend the domain and range of rational equations to include negative values of $x$ and $y$. First we’ll plot a few rational functions by using a table of values, and then we’ll talk about the distinguishing characteristics of rational functions that can help us make better graphs.

As we graph rational functions, we need to always pay attention to values of $x$ that will cause us to divide by 0. Remember that dividing by 0 doesn’t give us an actual number as a result.

Example 2

Graph the function $y = \frac{1}{x}$.

Solution

Before we make a table of values, we should notice that the function is not defined for $x = 0$. This means that the graph of the function won’t have a value at that point. Since the value of $x = 0$ is special, we should make sure to pick enough values close to $x = 0$ in order to get a good idea how the graph behaves.

Let’s make two tables: one for $x-$values smaller than zero and one for $x-$values larger than zero.

$x$ $y=\frac {1}{x}$ $x$ $y=\frac {1}{x}$
$-5$ $y =\frac {1}{-5}=-0.2$ 0.1 $y=\frac {1}{0.1}=10$
-4 $y =\frac {1}{-4}=-0.25$ 0.2 $y =\frac {1}{0.2}=5$
-3 $y=\frac {1}{-3}=-0.33$ 0.3 $y=\frac {1}{0.3}=3.3$
-2 $y=\frac {1}{-2}=-0.5$ 0.4 $y =\frac {1}{0.4}=2.5$
-1 $y=\frac {1}{-1}=-1$ 0.5 $y=\frac {1}{0.5}=2$
-0.5 $y =\frac {1}{-0.5}=-2$ 1 $y=\frac {1}{1}=1$
-0.4 $y =\frac {1}{-0.4}=-2.5$ 2 $y =\frac {1}{2}=0.5$
-0.3 $y=\frac {1}{-0.3}=-3.3$ 3 $y=\frac {1}{3}=0.33$
-0.2 $y =\frac {1}{-0.2}=-5$ 4 $y=\frac {1}{4}=0.25$
-0.1 $y =\frac {1}{-0.1}=-10$ 5 $y =\frac {1}{5}=0.2$

We can see that as we pick positive values of $x$ closer and closer to zero, $y$ gets larger, and as we pick negative values of $x$ closer and closer to zero, $y$ gets smaller (or more and more negative).

Notice on the graph that for values of $x$ near 0, the points on the graph get closer and closer to the vertical line $x = 0$. The line $x = 0$ is called a vertical asymptote of the function $y = \frac{1}{x}$.

We also notice that as the absolute values of $x$ get larger in the positive direction or in the negative direction, the value of $y$ gets closer and closer to $y = 0$ but will never gain that value. Since $y = \frac{1}{x}$, we can see that there are no values of $x$ that will give us the value $y = 0$. The horizontal line $y = 0$ is called a horizontal asymptote of the function $y = \frac{1}{x}$

Asymptotes are usually denoted as dashed lines on a graph. They are not part of the function; instead, they show values that the function approaches, but never gets to. A horizontal asymptote shows the value of $y$ that the function approaches (but never reaches) as the absolute value of $x$ gets larger and larger. A vertical asymptote shows that the absolute value of $y$ gets larger and larger as $x$ gets closer to a certain value which it can never actually reach.

Now we’ll show the graph of a rational function that has a vertical asymptote at a non-zero value of $x$.

Example 3

Graph the function $y = \frac{1}{(x - 2)^2}$.

Solution

We can see that the function is not defined for $x = 2$, because that would make the denominator of the fraction equal zero. This tells us that there should be a vertical asymptote at $x = 2$, so we can start graphing the function by drawing the vertical asymptote.

Now let’s make a table of values.

$x$ $y = \frac {1}{(x-2)^2}$
0 $y= \frac {1}{(0-2)^2} = \frac {1}{4}$
1 $y= \frac {1}{(1-2)^2} = 1$
1.5 $y= \frac {1}{(1.5-2)^2} = 4$
2 $\text{undefined}$
2.5 $y = \frac {1}{(2.5-2)^2} = 4$
3 $y= \frac {1}{(3-2)^2} = 1$
4 $y= \frac {1}{(4-2)^2} = \frac {1}{4}$

Here’s the resulting graph:

Notice that we didn’t pick as many values for our table this time, because by now we have a pretty good idea what happens near the vertical asymptote.

We also know that for large values of $|x|$, the value of $y$ could approach a constant value. In this case that value is $y = 0$: this is the horizontal asymptote.

A rational function doesn’t have to have a vertical or horizontal asymptote. The next example shows a rational function with no vertical asymptotes.

Example 4

Graph the function $y= \frac{x^2}{x^2 + 1}$.

Solution

We can see that this function will have no vertical asymptotes because the denominator of the fraction will never be zero. Let’s make a table of values to see if the value of $y$ approaches a particular value for large values of $x$, both positive and negative.

$x$ $y= \frac {x^2}{x^2+1}$
$-3$ $y= \frac {(-3)^2}{(-3)^2+1} = \frac {9}{10} = 0.9$
-2 $y= \frac {(-2)^2}{(-2)^2+1} = \frac {4}{5} = 0.8$
-1 $y= \frac {(-1)^2}{(-1)^2+1} = \frac {1}{2} = 0.5$
0 $y= \frac {(0)^2}{(0)^2+1} = \frac {0}{1} = 0$
1 $y= \frac {(1)^2}{(1)^2+1} = \frac {1}{2} = 0.5$
2 $y= \frac {(2)^2}{(2)^2+1} = \frac {4}{5} = 0.8$
3 $y= \frac {(3)^2}{(3)^2+1} = \frac {9}{10} = 0.9$

Below is the graph of this function.

The function has no vertical asymptote. However, we can see that as the values of $|x|$ get larger, the value of $y$ gets closer and closer to 1, so the function has a horizontal asymptote at $y = 1$.

Finding Horizontal Asymptotes

We said that a horizontal asymptote is the value of $y$ that the function approaches for large values of $|x|$. When we plug in large values of $x$ in our function, higher powers of $x$ get larger much quickly than lower powers of $x$. For example, consider:

$y = \frac{2x^2 + x - 1}{3x^2 - 4x + 3}$

If we plug in a large value of $x$, say $x = 100$, we get:

$y = \frac{2(100)^2 + (100) - 1}{3(100)^2 - 4(100) + 3} = \frac{20000 + 100 - 1}{30000 - 400 + 2}$

We can see that the beginning terms in the numerator and denominator are much bigger than the other terms in each expression. One way to find the horizontal asymptote of a rational function is to ignore all terms in the numerator and denominator except for the highest powers.

In this example the horizontal asymptote is $y = \frac{2x^2}{3x^2}$, which simplifies to $y = \frac{2}{3}$.

In the function above, the highest power of $x$ was the same in the numerator as in the denominator. Now consider a function where the power in the numerator is less than the power in the denominator:

$y = \frac{x}{x^2 + 3}$

As before, we ignore all the terms except the highest power of $x$ in the numerator and the denominator. That gives us $y = \frac{x}{x^2}$, which simplifies to $y = \frac{1}{x}$.

For large values of $x$, the value of $y$ gets closer and closer to zero. Therefore the horizontal asymptote is $y = 0$.

To summarize:

• Find vertical asymptotes by setting the denominator equal to zero and solving for $x$.
• For horizontal asymptotes, we must consider several cases:
• If the highest power of $x$ in the numerator is less than the highest power of $x$ in the denominator, then the horizontal asymptote is at $y = 0$.
• If the highest power of $x$ in the numerator is the same as the highest power of $x$ in the denominator, then the horizontal asymptote is at $y = \frac{coefficient \ of \ highest \ power \ of \ x}{coefficient \ of \ highest \ power \ of \ x}$.
• If the highest power of $x$ in the numerator is greater than the highest power of $x$ in the denominator, then we don’t have a horizontal asymptote; we could have what is called an oblique (slant) asymptote, or no asymptote at all.

Example 5

Find the vertical and horizontal asymptotes for the following functions.

a) $y = \frac {1}{x-1}$

b) $y= \frac {3x}{4x+2}$

c) $y=\frac {x^2-2}{2x^2+3}$

d) $y=\frac {x^3}{x^2-3x+2}$

Solution

a) Vertical asymptotes:

Set the denominator equal to zero. $x-1=0\Rightarrow x=1$ is the vertical asymptote.

Horizontal asymptote:

Keep only the highest powers of $x$. $y=\frac {1}{x}\Rightarrow y=0$ is the horizontal asymptote.

b) Vertical asymptotes:

Set the denominator equal to zero. $4x+2=0\Rightarrow x=-\frac{1}{2}$ is the vertical asymptote.

Horizontal asymptote:

Keep only the highest powers of $x$. $y=\frac {3x}{4x}\Rightarrow y=\frac{3}{4}$ is the horizontal asymptote.

c) Vertical asymptotes:

Set the denominator equal to zero: $2x^2+3 = 0 \Rightarrow 2x^2 = -3 \Rightarrow x^2 = -\frac{3}{2}$. Since there are no solutions to this equation, there is no vertical asymptote.

Horizontal asymptote:

Keep only the highest powers of $x$. $y=\frac {x^2}{2x^2} \Rightarrow y= \frac {1}{2}$ is the horizontal asymptote.

d) Vertical asymptotes:

Set the denominator equal to zero: $x^2 - 3x + 2 =0$

Factor: $(x - 2)(x - 1) = 0$

Solve: $x = 2$ and $x = 1$ are the vertical asymptotes.

Horizontal asymptote. There is no horizontal asymptote because the power of the numerator is larger than the power of the denominator.

Notice the function in part d had more than one vertical asymptote. Here’s another function with two vertical asymptotes.

Example 6

Graph the function $y = \frac{-x^2}{x^2 - 4}$.

Solution

$\text{Letâ€™s set the denominator equal to zero:} \qquad x^2 - 4 = 0\!\\\\\text{Factor:} \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad (x - 2)(x + 2) = 0\!\\\\\text{Solve:} \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \ \ x = 2, x = -2$

We find that the function is undefined for $x = 2$ and $x = -2$, so we know that there are vertical asymptotes at these values of $x$.

We can also find the horizontal asymptote by the method we outlined above. It’s at $y = \frac{-x^2}{x^2}$, or $y = -1$.

So, we start plotting the function by drawing the vertical and horizontal asymptotes on the graph.

Now, let’s make a table of values. Because our function has a lot of detail we must make sure that we pick enough values for our table to determine the behavior of the function accurately. We must make sure especially that we pick values close to the vertical asymptotes.

$x$ $y = \frac {-x^2}{x^2-4}$
$-5$ $y = \frac {-(-5)^2}{(-5)^2-4} = \frac {-25}{21} = -1.19$
-4 $y = \frac {-(-4)^2}{(-4)^2-4} = \frac {-16}{12} = -1.33$
-3 $y = \frac {-(-3)^2}{(-3)^2-4} = \frac {-9}{5} = -1.8$
-2.5 $y = \frac {-(-2.5)^2}{(-2.5)^2-4} = \frac {-6.25}{2.25} = -2.8$
-1.5 $y = \frac {-(-1.5)^2}{(-1.5)^2-4} = \frac {-2.25}{-1.75} = 1.3$
-1 $y = \frac {-(-1)^2}{(-1)^2-4} = \frac {-1}{-3} = 0.33$
0 $y = \frac {-0^2}{(0)^2-4} = \frac {0}{-4} = 0$
1 $y= \frac {-1^2}{(1)^2-4} = \frac {-1}{-3} = 0.33$
1.5 $y = \frac {-1.5^2}{(1.5)^2-4} = \frac {-2.25}{-1.75} = 1.3$
2.5 $y = \frac {-2.5^2}{(2.5)^2-4} = \frac {-6.25}{2.25} = -2.8$
3 $y = \frac {-3^2}{(3)^2-4} = \frac {-9}{5} = -1.8$
4 $y = \frac {-4^2}{(4)^2-4} = \frac {-16}{12} = -1.33$
5 $y = \frac {-5^2}{(5)^2-4} = \frac {-25}{21} = -1.19$

Here is the resulting graph.

To explore more graphs of rational functions, try the applets available at http://www.analyzemath.com/rational/rational1.html.

Solve Real-World Problems Using Rational Functions

Electrical circuits are commonplace is everyday life—for example, they’re in all the electrical appliances in your home. The figure below shows an example of a simple electrical circuit. It consists of a battery which provides a voltage ($V$, measured in Volts, $V$), a resistor ($R$, measured in ohms, $\Omega$) which resists the flow of electricity and an ammeter that measures the current ($I$, measured in amperes, $A$) in the circuit.

Ohm’s Law gives a relationship between current, voltage and resistance. It states that

$I = \frac{V}{R}$

Your light bulbs, toaster and hairdryer are all basically simple resistors. In addition, resistors are used in an electrical circuit to control the amount of current flowing through a circuit and to regulate voltage levels. One important reason to do this is to prevent sensitive electrical components from burning out due to too much current or too high a voltage level. Resistors can be arranged in series or in parallel.

For resistors placed in a series:

the total resistance is just the sum of the resistances of the individual resistors:

$R_{tot} = R_1 + R_2$

For resistors placed in parallel:

the reciprocal of the total resistance is the sum of the reciprocals of the resistances of the individual resistors:

$\frac{1}{R_c} = \frac{1}{R_1} + \frac{1}{R_2}$

Example 7

Find the quantity labeled $x$ in the following circuit.

Solution

$\text{We use the formula} \ I = \frac{V}{R}.\!\\\\\text{Plug in the known values:} I = 2 \ A, V = 12 \ V: \qquad \qquad 2 = \frac{12}{R}\!\\\\\text{Multiply both sides by} \ R: \qquad \qquad \qquad \qquad \qquad \qquad 2R = 12\!\\\\\text{Divide both sides by}\ 2: \qquad \qquad \qquad \qquad \qquad \qquad \quad R = 6 \Omega \quad \mathbf{Answer}$

Example 8

Find the quantity labeled $x$ in the following circuit.

Solution

$\text{Ohmâ€™s Law also tells us that} \ I_{total} = \frac{V_{total}}{R_{total}}\!\\\\\text{Plug in the values we know}, I = 2.5 \ A \ \text{and}\ E = 9 \ V: \quad \qquad \qquad \qquad \ 2.5 = \frac{9}{R_{tot}}\!\\\\\text{Multiply both sides by}\ R: \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \quad 2.5R_{tot} = 9\!\\\\\text{Divide both sides by}\ 2.5: \ \ \quad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad R_{tot} = 3.6 \Omega\!\\\\\text{Since the resistors are placed in parallel, the total resistance is given by:}\ \frac{1}{R_{tot}} = \frac{1}{X} + \frac{1}{20}\!\\\\{\;} \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \Rightarrow \frac{1}{36} = \frac{1}{X} + \frac{1}{20}\!\\\\\text{Multiply all terms by} \ 72X: \qquad \qquad \qquad \qquad \qquad \qquad \frac{1}{3.6}(72X) = \frac{1}{X}(72X) + \frac{1}{20}(72X)\!\\\\\text{Cancel common factors:} \qquad \qquad \qquad \qquad \qquad \qquad \quad \ 20X = 72 + 3.6X\!\\\\\text{Solve:} \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \quad \ 16.4X = 72\!\\\\\text{Divide both sides by}\ 16.4: \ \quad \qquad \qquad \qquad \qquad \qquad \quad X = 4.39 \Omega \quad \mathbf{Answer}$

Review Questions

Find all the vertical and horizontal asymptotes of the following rational functions.

1. $y=\frac {4}{x+2}$
2. $y=\frac {5x-1}{2x-6}$
3. $y=\frac {10}{x}$
4. $y=\frac {x + 1}{x^2}$
5. $y=\frac {4x^2}{4x^2+1}$
6. $y=\frac {2x}{x^2-9}$
7. $y=\frac {3x^2}{x^2-4}$
8. $y=\frac {1}{x^2+4x+3}$
9. $y=\frac {2x+5}{x^2-2x-8}$

Graph the following rational functions. Draw dashed vertical and horizontal lines on the graph to denote asymptotes.

1. $y=\frac {2}{x-3}$
2. $y=\frac {3}{x^2}$
3. $y=\frac {x}{x-1}$
4. $y=\frac {2x}{x+1}$
5. $y=\frac {-1}{x^2+2}$
6. $y=\frac {x}{x^2+9}$
7. $y=\frac {x^2}{x^2+1}$
8. $y=\frac {1}{x^2-1}$
9. $y=\frac {2x}{x^2-9}$
10. $y=\frac {x^2}{x^2-16}$
11. $y=\frac {3}{x^2-4x+4}$
12. $y=\frac {x}{x^2-x-6}$

Find the quantity labeled $x$ in each of the following circuits.

Feb 23, 2012

Dec 23, 2014