APSkills

How to find holes and asymptotes of rational functions

How to tell a hole from a vertical asymptote, find the hole's coordinates, and get the horizontal or slant asymptote from the degrees, the way AP Precalculus asks.

By the Generation STEM test prep teamUpdated November 20, 2026 12 min read

The short answer

Factor the top and the bottom. A factor of the bottom that cancels completely gives a hole, and plugging its input into the simplified function gives the hole's height. A factor that still has a copy on the bottom gives a vertical asymptote, and comparing the degrees of the top and the bottom gives the horizontal or slant asymptote.

On this page
  1. 01Factor first
  2. 02Hole or vertical asymptote: count the copies
  3. 03Finding the hole's coordinates
  4. 04What the graph does near a vertical asymptote
  5. 05Horizontal asymptotes: compare the degrees
  6. 06Slant asymptotes and other end behavior
  7. 07The whole routine on one function
  8. 08How this shows up on the AP Precalculus exam

A rational function's graph can break only where its bottom is zero, and factoring tells you how it breaks. If the factor that makes the bottom zero cancels completely, the graph has a hole. If a copy of it stays on the bottom, the graph has a vertical asymptote. Far out to the sides, the degrees of the top and the bottom decide the horizontal or slant asymptote.

In AP Precalculus you'll meet these as formulas, graphs, and tables, and you'll describe what the graph does using limits.

Factor first

A rational function is one polynomial divided by another. The top is the numerator, and the bottom is the denominator. We'll use one example the whole way through:

f(x) = (x² − 2x − 15)/(x² − 9x + 20)

You can't divide by zero, so any input that makes the bottom zero is left out of the function's domain, the set of inputs it accepts. Those inputs are the only places the graph can break. Factor the top and the bottom to find them:

f(x) = (x − 5)(x + 3)/((x − 5)(x − 4))

The bottom is zero at x = 5 and at x = 4. Each of those is either a hole or a vertical asymptote, and the factors tell you which.

The top is zero at 5 and at −3. A rational function's zeros are the zeros of its top that are in the domain, so f has just one zero, x = −3. The 5 doesn't count, because f isn't defined there.

Hole or vertical asymptote: count the copies

Cancel any factor that appears on both the top and the bottom. Then look at each input that made the bottom zero.

  • The factor cancels completely. No copy is left on the bottom, so the graph has a hole, a single missing point in an otherwise unbroken curve. In f, x − 5 cancels, so there's a hole at x = 5.
  • A copy stays on the bottom. The graph has a vertical asymptote, a vertical line the graph gets closer and closer to without touching. In f, x − 4 stays on the bottom, so x = 4 is a vertical asymptote.

After canceling, f(x) = (x + 3)/(x − 4) for every input except 5.

The number of copies of a factor is its multiplicity, and it settles the close cases:

  • In (x − 1)/(x − 1)², one copy cancels and one stays on the bottom, leaving 1/(x − 1). So x = 1 is a vertical asymptote.
  • In (x − 1)²/(x − 1), the bottom's only copy cancels, leaving x − 1. So x = 1 is a hole. The leftover x − 1 is 0 when x = 1, so this hole sits right on the x-axis, at (1, 0). It still isn't a zero, because 1 isn't in the domain.

The rule: if the top has at least as many copies of a factor as the bottom, you get a hole. If the bottom has more, you get a vertical asymptote.

Finding the hole's coordinates

The hole's x-coordinate is the input whose factor canceled. For its y-coordinate, put that input into the simplified function.

For f, the simplified function is (x + 3)/(x − 4). At x = 5, that's 8/1 = 8, so the hole is at (5, 8).

The graph shows what that 8 means. At x = 4.999, f is about 8.007, and at x = 5.001, it's about 7.993. The outputs close in on 8 from both sides, even though f(5) doesn't exist.

In limit notation, that's lim x→5 f(x) = 8. Read it as "the limit of f(x) as x approaches 5 is 8." For a hole, the limit is the hole's height.

Find the hole

The function r is given by r(x) = (x² + x − 12)/(x² − 9). The graph of r has a hole at which point?

What the graph does near a vertical asymptote

Use the simplified form, (x + 3)/(x − 4). Near x = 4, its bottom gets close to 0 while its top stays close to 7. A number near 7 divided by a number near 0 is huge, so the outputs grow without bound. What's left to find is which way they go on each side.

Only the signs matter. Check each factor just to the left and just to the right of 4.

xx + 3x − 4f(x)
3.996.99, positive−0.01, negative−699
4.017.01, positive0.01, positive701

So the graph dives down on the left of x = 4 and shoots up on the right. In limit notation, a small minus after the 4 means "from the left," and a small plus means "from the right."

  • lim x→4⁻ f(x) = −∞
  • lim x→4⁺ f(x) = ∞

The ∞ doesn't mean f reaches a number called infinity. It means the outputs grow past any number you could name. In words, as x approaches 4 from the left, f(x) decreases without bound.

The multiplicity of the leftover factor tells you whether the two sides split. A factor with an odd power, like x − 4, changes sign as you cross it, so one side goes up and the other goes down. A squared factor is never negative, so both sides go the same way. In 1/(x + 2)², both sides of x = −2 go up.

One-sided limits

The function g is given by g(x) = (x + 1)/(x² − 2x − 8). Which of the following is true?

Horizontal asymptotes: compare the degrees

End behavior is what a function does far out to the sides, as x → ∞ and x → −∞. A polynomial's degree is its highest power, and its leading term is the term with that power. The number in front of the leading term is the leading coefficient.

Far out, the leading terms swamp everything else. At x = 1,000, x² is 1,000,000, while 9x is only 9,000. So a rational function acts like its leading terms divided, and there are three cases.

DegreesLeading terms dividedEnd behavior
Bottom's is biggera number over a power of x, which shrinks to 0horizontal asymptote y = 0
They're equalthe powers cancel, leaving a numberhorizontal asymptote at that number
Top's is biggera power of x is left overno horizontal asymptote

For example:

  • Bottom bigger. In (5x + 2)/(x² + 1), the leading terms give 5x/x² = 5/x, which shrinks to 0. The horizontal asymptote is y = 0.
  • Equal. In (6x² − x)/(3x² + 4), the leading terms give 6x²/3x² = 2. The horizontal asymptote is y = 2.
  • Our f. The leading terms are x² over x², which is 1, so the horizontal asymptote is y = 1. In limit notation, lim x→∞ f(x) = 1 and lim x→−∞ f(x) = 1.

A horizontal asymptote only describes the far ends, so the graph is allowed to cross it in the middle. A vertical asymptote is different. The function isn't defined there, so the graph can't cross it.

Horizontal asymptote

The function p is given by p(x) = (6x² − 5x)/(4 − 3x²). Which of the following is the horizontal asymptote of the graph of p?

Slant asymptotes and other end behavior

When the top's degree is exactly one more than the bottom's, the graph closes in on a slanted line, called a slant asymptote. To find it, divide the top by the bottom with polynomial long division. The quotient is the line.

For (x² + 4x + 7)/(x + 1), long division gives a quotient of x + 3 and a remainder of 4:

(x² + 4x + 7)/(x + 1) = x + 3 + 4/(x + 1)

Far out, 4/(x + 1) shrinks to 0, so the graph hugs the line y = x + 3 on both ends. At x = 1,000, the graph is only about 0.004 above the line.

If the top's degree is two or more higher, the leading terms leave a power like x² or x³, and the function follows that power's end behavior. In (2x³ + 1)/(x − 3), the leading terms give 2x³/x = 2x². So the function goes to ∞ as x → ∞ and also as x → −∞, the same as 2x².

The whole routine on one function

These five steps work on any rational function. Here they are on f.

  1. Factor. f(x) = (x − 5)(x + 3)/((x − 5)(x − 4)).
  2. Holes. The factor x − 5 cancels completely. The simplified function (x + 3)/(x − 4) gives 8 at x = 5, so the hole is at (5, 8).
  3. Vertical asymptotes. The factor x − 4 stays on the bottom, so x = 4 is a vertical asymptote. The graph goes to −∞ on its left and ∞ on its right.
  4. Zeros. The leftover top factor, x + 3, gives the only zero, x = −3.
  5. End behavior. The degrees are equal and both leading coefficients are 1, so the horizontal asymptote is y = 1.

Put together, the graph has two pieces, split by the line x = 4. The left piece starts just under y = 1 far to the left, falls through −3, and dives down beside the asymptote. The right piece comes down from the top, passes the missing point at (5, 8), and flattens toward y = 1.

How this shows up on the AP Precalculus exam

Rational functions are part of Unit 1, Polynomial and Rational Functions, which makes up 30 to 40% of the multiple choice. The course framework gives them four topics: end behavior, zeros, vertical asymptotes, and holes. Another Unit 1 topic covers polynomial long division, which the framework ties to slant asymptotes.

College Board weights the exam by unit, not by topic, so there's no official count of rational function questions. The rest of the layout is in the AP Precalculus exam, explained.

Write limits out in full. Free-response Question 1 asked for end behavior in limit notation in 2024 and 2025, and for a one-sided limit in 2026. Its scoring guidelines wanted the whole statement: lim, the approach, the function, and the value. AP Precalculus FRQ 1, function concepts shows how that point is scored.

Practice by hand. Multiple-choice Part A, worth 43.75% of your score, doesn't allow a calculator, and neither does free-response Part B. On the parts that do, graphing the function in Bluebook's Desmos is a fast way to check your asymptotes.

If you're still deciding on the course, is AP Precalculus worth it covers what's in it and who it suits. Our AP Precalculus Prep has a full lesson on rational functions in Unit 1.

Questions students ask

What's the difference between a hole and a vertical asymptote?

Both happen where a rational function's bottom is zero. A hole is a single missing point, and you get one when that factor cancels completely. A vertical asymptote is a line the graph runs along toward ∞ or −∞, and you get one when a copy of the factor stays on the bottom.

How do you find the y-coordinate of a hole?

Cancel the common factor, then plug the hole's x-value into what's left. Plugging it into the original function gives 0/0, which doesn't tell you the height. In limit notation, the height is the limit of the function as x approaches that value.

Can a graph cross its horizontal asymptote?

Yes. For example, 2x/(x² + 1) crosses y = 0 at the origin, then closes in on 0 again at both ends. The asymptote only describes the far left and far right. A vertical asymptote is the one a graph can't cross.

When does a rational function have a slant asymptote?

When the top's degree is exactly one more than the bottom's. Divide the top by the bottom, and the quotient is the slant asymptote. If the top's degree is two or more higher, there's no slant line, and the end behavior follows a power like x².

Can a rational function have two horizontal asymptotes?

No. Far to the right and far to the left, the leading terms divide to the same thing. So a rational function has at most one horizontal asymptote, and when it has one, both ends approach it.

Where these facts come from

Test formats and scoring rules come from College Board's own pages, checked on November 20, 2026. Policies change, so check them before test day.

Get ready for the AP with a plan.

AP Precalculus Prep teaches every topic on the test from scratch. Your first 7 days are free.