Vertical and Horizontal Asymptotes Explained
An asymptote is a line the graph gets arbitrarily close to without ever settling on it. Rational functions have them, exponentials have them, and the tangent function has infinitely many. Finding them is mechanical once you know which of three tests applies.
Vertical asymptotes
A vertical asymptote occurs where the function blows up: the output runs off
towards positive or negative infinity as x approaches some
fixed value. For a rational function, that happens where the denominator is
zero and the numerator is not.
The method
- Factor the numerator and the denominator fully.
- Cancel any factors that appear in both.
- Set what remains in the denominator equal to zero. Each solution is a vertical asymptote.
Worked example
Find the vertical asymptotes of
y = (x + 1) / (x² - x - 6).
The denominator factors as (x - 3)(x + 2). Nothing cancels
against x + 1. Setting each factor to zero gives
x = 3 and x = -2.
The tangent function has an asymptote everywhere its cosine denominator
vanishes, which is at every odd multiple of π/2 — infinitely
many of them, evenly spaced.
Horizontal asymptotes
A horizontal asymptote describes what the function settles towards as
x runs off to the far left or far right. For a rational
function, compare the degree of the top with the degree of the bottom.
| Degrees | Horizontal asymptote | Example |
|---|---|---|
| Top < bottom | y = 0 | (x + 1)/(x² - 4) |
| Top = bottom | Ratio of the leading coefficients | (3x² + 1)/(2x² - 5) gives y = 3/2 |
| Top > bottom by 1 | None; there is a slant asymptote instead | (x² + 1)/(x - 2) |
| Top > bottom by 2 or more | None | (x³ + 1)/(x - 2) |
The reasoning behind the middle row: for very large x, the
highest-power terms dominate everything else, so
(3x² + 1)/(2x² - 5) behaves like 3x²/2x², which is
3/2.
A horizontal asymptote can be crossed. It describes
behaviour at the far ends, not a wall. y = x/(x² + 1) passes
straight through y = 0 at the origin, then approaches it from
the other side. Only vertical asymptotes are uncrossable.
Slant asymptotes
When the numerator's degree is exactly one higher than the denominator's, the function approaches a sloped line rather than a horizontal one. Find it by polynomial long division; the quotient is the asymptote and the remainder fades away.
Dividing x² + 1 by x - 2 gives
x + 2 with a remainder of 5, so
y = (x² + 1)/(x - 2) = x + 2 + 5/(x - 2)
As x grows, the 5/(x - 2) term shrinks to nothing
and the curve becomes indistinguishable from the line
y = x + 2.
Holes, which are not asymptotes
If a factor cancels completely between numerator and denominator, the graph has a hole at that point rather than an asymptote: a single missing point with the curve continuing normally on both sides.
y = (x² - 4)/(x - 2) factors to
(x - 2)(x + 2)/(x - 2), which cancels to x + 2
everywhere except x = 2, where the original expression is
0/0. The graph is the straight line y = x + 2 with
a single point missing at (2, 4).
Holes are genuinely hard to see on any graphing tool, ours included. A single missing point is smaller than a pixel. Always check for cancelling factors algebraically rather than relying on the picture.
Why a good graph breaks at a pole
A graphing tool samples the function at a series of x-values and joins the dots. Near a vertical asymptote that naive approach goes wrong: the sample just left of the asymptote has a huge negative value, the sample just right has a huge positive one, and joining them draws a near-vertical line that is not part of the function at all.
Plenty of free graphing tools do exactly this, and it is the fastest way to
tell a carefully built grapher from a quick one. Ours detects the situation
and breaks the path instead. The test it applies is whether both sides are
enormous and of opposite sign, which distinguishes a genuine pole
from a function that is merely steep. y = x⁵ crosses the whole
window almost vertically and is correctly drawn as one unbroken curve.
Questions
Can a graph cross its horizontal asymptote?
Yes, and this surprises people. A horizontal asymptote describes behaviour far out at the edges, not a barrier. y = x/(x² + 1) crosses its horizontal asymptote y = 0 at the origin and still approaches it at both ends.
Can a graph cross a vertical asymptote?
No. A vertical asymptote sits at a value where the function is undefined, so there is nothing there to cross.
How do I tell a hole from a vertical asymptote?
Factor the numerator and denominator. If a factor cancels completely, you get a hole: a single missing point. If it remains in the denominator after cancelling, you get a vertical asymptote.
Can a function have both a horizontal and a slant asymptote?
No. Which one you get depends on the degrees of the numerator and denominator, and those degrees can only produce one answer. You can, however, have different horizontal asymptotes at the two ends, which happens with functions such as arctan.
Why does my graph show a vertical line at the asymptote?
Because the tool is joining the last point before the asymptote to the first point after it. That line is an artefact, not part of the function. Well-built graphers detect the pole and break the curve instead.