MAT1051 · Week 4 · Limits at Infinity, Continuity

Limits at infinity and continuity

Limits as x goes to infinity, horizontal and oblique asymptotes, the three conditions of continuity, types of discontinuity and the Intermediate Value Theorem. Asymptote questions and 'what should k be' questions come from here.

limit at infinityhorizontal asymptoteoblique (slant) asymptotecontinuityremovable discontinuityjump discontinuityinfinite discontinuityIntermediate Value TheoremMax-Min Theorem

Last week xx approached a number. This week there are two new questions: what does the function do as xx goes to infinity, and can a function be drawn “without a break”? The first brings asymptote questions, and the second brings “what should kk be for the function to be continuous” questions. These are almost guaranteed on the midterm. Keep in mind:

  1. For a rational function, the limit at infinity is found by looking at the degrees. Divide by the highest power.
  2. x2=∣x∣\sqrt{x^2}=|x|. As x→−∞x\to-\infty this means −x-x.
  3. If ∞−∞\infty-\infty involves roots, multiply by the conjugate.
  4. Continuity = the limit equals the value of the function. For a piecewise function, check the junction points.
  5. The Intermediate Value Theorem shows that a root exists, it does not find the root itself.

Limits at infinity

lim⁡x→∞f(x)=L\displaystyle\lim_{x\to\infty}f(x)=L: as xx grows, f(x)f(x) approaches LL. In this case y=Ly=L is a horizontal asymptote. x→−∞x\to-\infty is examined separately; the two directions may give different results.

Basic fact: for p>0p>0, lim⁡x→±∞1xp=0\displaystyle\lim_{x\to\pm\infty}\frac{1}{x^p}=0.

Rational functions: the degree rule

Divide the numerator and denominator by the highest power in the denominator.

Example 1.

lim⁡x→∞4x3−x2x3+5x2=lim⁡x→∞4−1x22+5x=42=2\lim_{x\to\infty}\frac{4x^3-x}{2x^3+5x^2}=\lim_{x\to\infty}\frac{4-\frac{1}{x^2}}{2+\frac{5}{x}}=\frac{4}{2}=2

Short rule table:

CaseLimit (x→±∞x\to\pm\infty)Example
numerator degree < denominator00x2+1x3−2→0\dfrac{x^2+1}{x^3-2}\to0
equalratio of leading coefficients4x3−x2x3+5x2→2\dfrac{4x^3-x}{2x^3+5x^2}\to2
numerator degree > denominator±∞\pm\inftyx3x2+1→∞\dfrac{x^3}{x^2+1}\to\infty

If the numerator’s degree is exactly one more, there is an oblique asymptote: do polynomial division, and the quotient part is the asymptote line.

Roots and the sign trap

x2=∣x∣\sqrt{x^2}=|x|. That is why a minus sign appears when you pull xx out of a root as x→−∞x\to-\infty.

Example 2. f(x)=x2+12x+3f(x)=\dfrac{\sqrt{x^2+1}}{2x+3}.

x -> +inf:  sqrt(x^2+1) = x sqrt(1 + 1/x^2)
            f = sqrt(1+1/x^2) / (2 + 3/x)  ->  1/2
x -> -inf:  sqrt(x^2+1) = |x| sqrt(1+1/x^2) = -x sqrt(1+1/x^2)
            f = -sqrt(1+1/x^2) / (2 + 3/x)  ->  -1/2

Two horizontal asymptotes: y=12y=\tfrac12 and y=−12y=-\tfrac12.

PITFALL · pulling xx out of a root when x→−∞x\to-\infty. If you write x2=x\sqrt{x^2}=x, the sign comes out wrong. At negative infinity, x2=−x\sqrt{x^2}=-x.

The ∞−∞\infty-\infty indeterminate form

Example 3. lim⁡x→∞(x2+x−x2−x)\displaystyle\lim_{x\to\infty}\left(\sqrt{x^2+x}-\sqrt{x^2-x}\right).

Multiply and divide by the conjugate:

(x2+x)−(x2−x)x2+x+x2−x=2xx2+x+x2−x=21+1x+1−1x→22=1\frac{(x^2+x)-(x^2-x)}{\sqrt{x^2+x}+\sqrt{x^2-x}}=\frac{2x}{\sqrt{x^2+x}+\sqrt{x^2-x}}=\frac{2}{\sqrt{1+\frac1x}+\sqrt{1-\frac1x}}\to\frac{2}{2}=1

Exponential and inverse trigonometric functions

lim⁡x→∞e−x=0,lim⁡x→−∞ex=0,lim⁡x→±∞arctan⁡x=±π2\lim_{x\to\infty}e^{-x}=0,\qquad \lim_{x\to-\infty}e^{x}=0,\qquad \lim_{x\to\pm\infty}\arctan x=\pm\frac{\pi}{2}

In ratios containing exe^x, for x→∞x\to\infty divide by exe^x; for x→−∞x\to-\infty take exe^x directly as 00.

Continuity

ff is continuous at x=ax=a if and only if:

  1. f(a)f(a) is defined,
  2. lim⁡x→af(x)\displaystyle\lim_{x\to a}f(x) exists,
  3. lim⁡x→af(x)=f(a)\displaystyle\lim_{x\to a}f(x)=f(a).

Polynomials, exe^x, sin⁡x\sin x, cos⁡x\cos x are continuous everywhere. Rational functions, ln⁡x\ln x, x\sqrt{x}, tan⁡x\tan x are continuous on their domains. Sums, products and compositions of continuous functions are also continuous.

Types of discontinuity

TypeWhat happens?Example
Removablethe limit exists but f(a)f(a) is undefined or differentx2−4x−2\dfrac{x^2-4}{x-2}, x=2x=2
Jumpthe left and right limits differ∣x∣x\dfrac{\lvert x\rvert}{x}, x=0x=0
Infinitethe limit is ±∞\pm\infty1x−3\dfrac{1}{x-3}, x=3x=3

Example 4. f(x)=x2−4x−2f(x)=\dfrac{x^2-4}{x-2} (x≠2x\ne2), f(2)=3f(2)=3. lim⁡x→2f(x)=lim⁡(x+2)=4≠3=f(2)\lim_{x\to2}f(x)=\lim(x+2)=4\ne3=f(2). A removable discontinuity. If you redefine f(2)=4f(2)=4, it becomes continuous.

Example 4b (jump). g(x)={x+1,x<0x2−2,x≥0g(x)=\begin{cases}x+1, & x<0\\ x^2-2, & x\ge0\end{cases}. At x=0x=0 the left limit is 11 and the right limit is −2-2. The limit does not exist; this is a jump discontinuity. No value of g(0)g(0) can fix it; that is the difference from a removable discontinuity.

One-sided continuity and continuity on an interval

If lim⁡x→a+f(x)=f(a)\lim_{x\to a^+}f(x)=f(a), then ff is continuous from the right at aa; similarly from the left. Continuous on a closed interval [a,b][a,b] means: continuous at every interior point, continuous from the right at aa, and from the left at bb. For example x\sqrt{x} is continuous on [0,∞)[0,\infty); at 00 only the right side is considered, because it is not defined on the left.

Composition and limits

If gg is continuous at LL and lim⁡x→af(x)=L\lim_{x\to a}f(x)=L, then

lim⁡x→ag(f(x))=g(lim⁡x→af(x))=g(L)\lim_{x\to a}g\big(f(x)\big)=g\Big(\lim_{x\to a}f(x)\Big)=g(L)

So a continuous function can “go inside” the limit. Example: lim⁡x→∞cos⁡(πx2x+1)=cos⁡(lim⁡x→∞πx2x+1)=cos⁡π2=0\displaystyle\lim_{x\to\infty}\cos\left(\frac{\pi x}{2x+1}\right)=\cos\left(\lim_{x\to\infty}\frac{\pi x}{2x+1}\right)=\cos\frac{\pi}{2}=0. First we found the inner limit with the degree rule, then applied the cosine.

“What should k be?” questions

In a piecewise function, each piece is continuous on its own interval. The only suspicious place is the junction point. There, write value of the left piece = value of the right piece.

Example 5. f(x)={x2+k,x<2kx−1,x≥2f(x)=\begin{cases} x^2+k, & x<2\\ kx-1, & x\ge2\end{cases}

lim⁡x→2−f=4+k,f(2)=lim⁡x→2+f=2k−1\lim_{x\to2^-}f=4+k,\qquad f(2)=\lim_{x\to2^+}f=2k-1

4+k=2k−1⇒k=54+k=2k-1 \Rightarrow k=5.

If there are two unknowns, there are two junction points and you set up two equations.

The Intermediate Value Theorem

If ff is continuous on the closed interval [a,b][a,b] and NN is a number between f(a)f(a) and f(b)f(b), there is at least one c∈(a,b)c\in(a,b) with f(c)=Nf(c)=N.

The special case used to find roots: if f(a)f(a) and f(b)f(b) have opposite signs, there is a root in between.

Example 6. Does the equation x3−2x−5=0x^3-2x-5=0 have a root in (2,3)(2,3)?

f(2)=8−4−5=−1<0f(2)=8-4-5=-1<0, f(3)=27−6−5=16>0f(3)=27-6-5=16>0. The polynomial is continuous, so by the IVT yes. To find the root approximately, halve the interval (bisection):

f(2.5)  =  5.625 > 0   ->  the root is in (2, 2.5)
f(2.25) =  1.891 > 0   ->  the root is in (2, 2.25)
...                     ->  root ≈ 2.0946

Template to write on an exam: ”ff is continuous on [a,b][a,b] (polynomial), f(a)<0<f(b)f(a)<0<f(b), so by the IVT there exists c∈(a,b)c\in(a,b) with f(c)=0f(c)=0.” If you forget to state continuity, you lose points.

PITFALL · the IVT for a discontinuous function. For f(x)=1xf(x)=\tfrac1x, f(−1)=−1<0<1=f(1)f(-1)=-1<0<1=f(1) but there is no root in (−1,1)(-1,1). The function is not continuous at x=0x=0, so the theorem cannot be applied.

The Max-Min Theorem

If ff is continuous on the closed and bounded interval [a,b][a,b], it attains an absolute maximum and an absolute minimum on that interval. This theorem is the basis of the absolute extremum questions in week 8.

Common mistakes

Wrong thinkingCorrect
x2=x\sqrt{x^2}=x when x→−∞x\to-\inftyx2=∣x∣=−x\sqrt{x^2}=\lvert x\rvert=-x
∞−∞=0\infty-\infty=0Indeterminate; multiply by the conjugate
Every rational function has a single horizontal asymptoteWith roots or exe^x the two directions may differ
The numerator’s degree is larger, so there is no asymptoteIf it is larger by one, there is an oblique asymptote
The limit exists, so it is continuousf(a)f(a) must also equal the limit
A piecewise function is continuous everywhere because the pieces are polynomialsCheck the junction point
The IVT gives the rootIt only shows that it exists
Not stating continuity in the IVTFirst write ”ff is continuous on [a,b][a,b]”
∞⋅0=0\infty\cdot0=0Indeterminate; xsin⁡1x→1x\sin\tfrac1x\to1

Test yourself

Exam-style questions. Solve them on paper first, then reveal the answer.

Question 1easy

Evaluate lim⁡x→∞3x2−x+45x2+2\displaystyle\lim_{x\to\infty}\frac{3x^2-x+4}{5x^2+2}.

Show answer
35\dfrac35

The numerator and denominator have equal degree (2). Divide both by x2x^2: 3−1x+4x25+2x2→35\dfrac{3-\frac1x+\frac{4}{x^2}}{5+\frac{2}{x^2}}\to\dfrac{3}{5}. In short: the ratio of the leading coefficients.

Question 2medium

Evaluate lim⁡x→−∞4x2+x3x−1\displaystyle\lim_{x\to-\infty}\frac{\sqrt{4x^2+x}}{3x-1}.

Show answer
−23-\dfrac23

4x2+x=x24+1x=∣x∣4+1x\sqrt{4x^2+x}=\sqrt{x^2}\sqrt{4+\frac1x}=|x|\sqrt{4+\frac1x}. As x→−∞x\to-\infty, ∣x∣=−x|x|=-x. Ratio: −x4+1/xx(3−1/x)=−4+1/x3−1/x→−23\dfrac{-x\sqrt{4+1/x}}{x(3-1/x)}=\dfrac{-\sqrt{4+1/x}}{3-1/x}\to-\dfrac{2}{3}. If you miss the sign, you write +23+\tfrac23.

Question 3medium

Evaluate lim⁡x→∞(x2+6x−x)\displaystyle\lim_{x\to\infty}\left(\sqrt{x^2+6x}-x\right).

Show answer
3

∞−∞\infty-\infty is indeterminate. Multiply by the conjugate: (x2+6x)−x2x2+6x+x=6xx2+6x+x\dfrac{(x^2+6x)-x^2}{\sqrt{x^2+6x}+x}=\dfrac{6x}{\sqrt{x^2+6x}+x}. Divide by xx: 61+6/x+1→62=3\dfrac{6}{\sqrt{1+6/x}+1}\to\dfrac{6}{2}=3.

Question 4medium

Find all horizontal asymptotes of f(x)=2ex+3ex−1f(x)=\dfrac{2e^{x}+3}{e^{x}-1}.

Show answer
y=2y=2 (as x→∞x\to\infty) and y=−3y=-3 (as x→−∞x\to-\infty)

x→∞x\to\infty: divide the numerator and denominator by exe^x: 2+3e−x1−e−x→2\dfrac{2+3e^{-x}}{1-e^{-x}}\to 2. x→−∞x\to-\infty: ex→0e^x\to 0, the ratio is 0+30−1=−3\dfrac{0+3}{0-1}=-3. There are two different horizontal asymptotes.

Question 5medium

Evaluate lim⁡x→∞xsin⁡1x\displaystyle\lim_{x\to\infty}x\sin\frac1x.

Show answer
1

Let t=1xt=\tfrac1x. As x→∞x\to\infty, t→0+t\to0^+. The expression becomes sin⁡tt\dfrac{\sin t}{t}, whose limit is 11. (The ∞⋅0\infty\cdot 0 indeterminate form was resolved by a change of variable.)

Question 6easy

Find all horizontal and vertical asymptotes of f(x)=2x2+3xx2−4f(x)=\dfrac{2x^2+3x}{x^2-4}.

Show answer
y=2y=2; x=2x=2 and x=−2x=-2

The degrees are equal: y=21=2y=\tfrac21=2. The denominator is zero at x=±2x=\pm2. Numerator: at x=2x=2, 8+6=14≠08+6=14\ne0; at x=−2x=-2, 8−6=2≠08-6=2\ne0. There is no cancellation, so both are vertical asymptotes.

Question 7easy

Find cc so that f(x)={cx2+1,x<23x−c,x≥2f(x)=\begin{cases} cx^2+1, & x<2\\ 3x-c, & x\ge 2\end{cases} is continuous everywhere.

Show answer
c = 1

Each piece is a polynomial, so the only suspicious point is x=2x=2. The left limit is 4c+14c+1; the right limit and f(2)f(2) are 6−c6-c. Equate: 4c+1=6−c⇒5c=5⇒c=14c+1=6-c \Rightarrow 5c=5 \Rightarrow c=1.

Question 8medium

Find and classify the discontinuities of f(x)=x2−x−2x2−4f(x)=\dfrac{x^2-x-2}{x^2-4}.

Show answer
x=2x=2: removable (limit 34\tfrac34); x=−2x=-2: infinite

f(x)=(x−2)(x+1)(x−2)(x+2)f(x)=\dfrac{(x-2)(x+1)}{(x-2)(x+2)}. At x=2x=2 the factor cancels, lim⁡x→2x+1x+2=34\lim_{x\to2}\dfrac{x+1}{x+2}=\dfrac34: a removable discontinuity. If f(2)=34f(2)=\tfrac34 is defined, it becomes continuous. At x=−2x=-2 the simplified form is x+1x+2\dfrac{x+1}{x+2}: the numerator is −1≠0-1\ne0 and the denominator is 00. The limit is infinite, so this is an infinite discontinuity and x=−2x=-2 is a vertical asymptote.

Question 9easy

Show that the equation x3+x−3=0x^3+x-3=0 has a root in the interval (1,2)(1,2).

Show answer
By the IVT, since f(1) = -1 < 0 < 7 = f(2).

f(x)=x3+x−3f(x)=x^3+x-3 is a polynomial, continuous on [1,2][1,2]. f(1)=1+1−3=−1<0f(1)=1+1-3=-1<0, f(2)=8+2−3=7>0f(2)=8+2-3=7>0. 00 lies between f(1)f(1) and f(2)f(2). By the Intermediate Value Theorem there is a c∈(1,2)c\in(1,2) with f(c)=0f(c)=0.

Question 10medium

Prove that e−x=xe^{-x}=x has a solution in (0,1)(0,1).

Show answer
Apply the IVT to g(x) = e^{-x} - x.

Move the equation to one side: g(x)=e−x−xg(x)=e^{-x}-x. gg is continuous (a difference of continuous functions). g(0)=1>0g(0)=1>0, g(1)=e−1−1≈−0.632<0g(1)=e^{-1}-1\approx-0.632<0. By the IVT there is a c∈(0,1)c\in(0,1) with g(c)=0g(c)=0, that is e−c=ce^{-c}=c.

Question 11hard

Find aa and bb so that ff is continuous everywhere: f(x)={x2−1,x<−1ax+b,−1≤x≤2x+3,x>2f(x)=\begin{cases} x^2-1, & x<-1\\ ax+b, & -1\le x\le 2\\ x+3, & x>2\end{cases}

Show answer
a=53a=\dfrac53, b=53b=\dfrac53

Two junction points, two equations. x=−1x=-1: left (−1)2−1=0(-1)^2-1=0, middle piece −a+b-a+b. So −a+b=0-a+b=0. x=2x=2: middle 2a+b2a+b, right 2+3=52+3=5. So 2a+b=52a+b=5. From the first equation b=ab=a; substitute into the second: 3a=53a=5, a=b=53a=b=\tfrac53.

Question 12hard

Find the oblique (slant) asymptote of f(x)=x3−2xx2+1f(x)=\dfrac{x^3-2x}{x^2+1}.

Show answer
y=xy=x

The numerator's degree is 1 more than the denominator's: there is an oblique asymptote. Polynomial division: x3−2x=x(x2+1)−3xx^3-2x=x(x^2+1)-3x. So f(x)=x−3xx2+1f(x)=x-\dfrac{3x}{x^2+1}. As x→±∞x\to\pm\infty the second term goes to 00, and the graph approaches the line y=xy=x.

Verification: All answers were checked with node (verify/MAT1051/04.mjs): limits at infinity by evaluating near x = ±1e7, continuity constants by equating the values of the two pieces, the IVT with a sign change and bisection.

Review card

x -> ±inf, rational: degree(num) < degree(den) -> 0 equal -> ratio of leading coefficients numerator larger -> ±inf (if larger by 1, oblique asymptote: polynomial division) sqrt(x^2) = |x| -> -x when x -> -inf (sign trap) inf - inf with roots: multiply by the conjugate e^x: 0 when x -> -inf e^(-x): 0 when x -> inf arctan x -> ±π/2 Continuous (at a): 1) f(a) defined 2) lim f exists 3) lim f = f(a) Discontinuity: removable (lim exists, ≠ f(a) or f(a) undefined) / jump (left ≠ right) / infinite To make a piecewise function continuous: at the junction left = right = f(a) IVT: continuous on [a,b], f(a) and f(b) of opposite sign -> a root in between Max-Min: continuous on closed [a,b] -> absolute max and min are attained