The price of an approximation
$\sqrt{25.01}$ is about $5.001.$ How far off can that be, at worst — and can you say so without a calculator?
Lecture 4 built the Taylor polynomial $p_{n}$ of Definition 4.19 and asserted $f(x)\approx p_{n}(x)$ near $a,$ with no account of the error. Naming that error turns the approximation into an equation.
Let $f$ be $n+1$ times differentiable on an interval containing $a$ and $x$. Then $$ \begin{aligned} &f(x) = p_{n}(x) + R_{n+1}(x)\,, \\ &R_{n+1}(x) = \frac{f^{(n+1)}(z)}{(n+1)!}\,(x-a)^{n+1} \tag{5.1} \end{aligned} $$ for some number $z$ strictly between $a$ and $x$. In the case $a=0$, which is the one normally used, $R_{n+1}(x) = f^{(n+1)}(z)\,x^{n+1}/(n+1)!$ with $z$ between $0$ and $x$.
The remainder is worth staring at, because it makes the formula memorable rather than arbitrary: $R_{n+1}$ is exactly what the next term of the Taylor polynomial would have been, except that the derivative is evaluated at some unknown $z$ instead of at $a.$ One more derivative, taken somewhere you cannot name.
Guess first. Before the next box, decide what kind of number $z$ is.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Taylor's formula says that for some number $z$ strictly between $0$ and $x$, $$f(x) = p_{n}(x) + \frac{f^{(n+1)}(z)}{(n+1)!}x^{\,n+1}$$
What is $z$?
- Why is that answer tempting? Reads an existence theorem as a formula. $z$ does depend on $f,$ $n$ and $x$ — but there is no expression for it, and none is needed.
- Why is that answer tempting? ‘For some’ read as ‘for all’. A different and much stronger claim, and false. It is the same slip as reading ⟹ as ⟺ in Lecture 2: a weaker statement taken for a stronger one.
- Why is that answer tempting? Confuses the evaluation point of the remainder with a point of agreement. $p_{n}$ is exact at $0,$ not at $z.$
The theorem is an existence statement: it promises that at least one such $z$ is there, and tells you nothing about where.
That sounds useless and is not. If $|f^{(n+1)}| \le M$ between $0$ and $x$, then wherever $z$ is, $$|R_{n+1}(x)| \le \frac{M}{(n+1)!}|x|^{\,n+1}$$
Not knowing z costs nothing — replacing an unknown point by a bound over all points is one of the most useful moves in analysis.
Why B fails: for $f(x) = x^3$, $n = 1$, the formula reads $x^3 = \tfrac12(6z)x^2$, so $z = x/3$. One $z$, not all of them.
Some z, not every z
Test the “for all $z$” misreading on two functions, both with $a=0$ and $n=1.$
Try it yourself first. Then open one step at a time.
Take $f(x)=x^{2}.$ Then $p_{1}=0$ and $f''\equiv2,$ so (5.1) reads $x^{2} = \tfrac12\cdot2\cdot x^{2},$ which is true for every $z.$ So far the misreading survives.
Now take $f(x)=x^{3}.$ Again $p_{1}=0,$ and $f''(z)=6z,$ so the formula reads $$ \begin{aligned} x^{3} &= \tfrac12\cdot 6z\cdot x^{2} = 3zx^{2}\,, \\ &\text{that is}\qquad z = \frac{x}{3}\,. \end{aligned} $$
Exactly one $z$ works, not all of them. The first function was a coincidence of having a constant second derivative.
For $x^{2}$ every $z$ works, because $f''$ is constant. For $x^{3}$ only $z=x/3$ does. So (5.1) is a claim about some $z.$
An existence statement sounds useless. It is not, and the reason is the single most transferable idea in this lecture: you do not need to know where $z$ is if you can bound $f^{(n+1)}$ everywhere it might be.
If $\bigl|f^{(n+1)}(t)\bigr| \le M$ for every $t$ between $a$ and $x$, then $$ \bigl|R_{n+1}(x)\bigr| \;\le\; \frac{M}{(n+1)!}\,|x-a|^{\,n+1}\,. \tag{5.2} $$
The unknown $z$ lies between $a$ and $x,$ so whatever it is, $|f^{(n+1)}(z)|\le M.$ Substituting that into (5.1) gives (5.2). Replacing an unknown point by a bound valid at every point is a move worth remembering; it is how most estimates in analysis are made.
Seven decimals, guaranteed
Estimate $\sqrt{25.01},$ with a guaranteed error, and without a calculator.
Try it yourself first. Then open one step at a time.
Put $f(x)=\sqrt{25+x}$ and $a=0,$ so that the number wanted is $f(0.01);$ take $n=1.$ Then $f(0)=5$ and $f'(x) = \tfrac12(25+x)^{-1/2},$ so $f'(0)=\tfrac1{10}$ and $$ \begin{aligned} \sqrt{25.01} &\approx p_{1}(0.01) \\ &= 5 + \tfrac{1}{10}(0.01) \\ &= 5.001\,. \end{aligned} $$
For the error, $f''(x) = -\tfrac14(25+x)^{-3/2},$ which is largest in size at the left-hand end of the interval, so for $0<z<0.01$ $$ \begin{aligned} |f''(z)| &\le \tfrac14\cdot 25^{-3/2} \\ &= \tfrac14\cdot\tfrac1{125} = \tfrac{1}{500} =: M\,. \end{aligned} $$
Hence by (5.2), $$ \begin{aligned} |R_{2}(0.01)| &\le \frac{M}{2!}\,(0.01)^{2} \\ &= \frac{1}{1000}\cdot10^{-4} \\ &= 10^{-7}\,. \end{aligned} $$ So $\sqrt{25.01} = 5.001$ with an error of at most $10^{-7},$ guaranteed — from one derivative, one crude bound and no calculator.
$\sqrt{25.01}\approx5.001,$ with an error of at most $10^{-7}.$
Two separate things made that error small, and it is worth separating them. The factorial $(n+1)!$ in the denominator grows faster than almost anything, so extra terms help a great deal; and $|x-a|^{n+1}$ shrinks fast whenever $|x-a|<1,$ so being close to the centre helps a great deal. Neither helps when $|x-a|$ is large, which is Watch out 4.22 of the previous lecture stated quantitatively at last.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Approximate $f(x)=\dfrac{1}{1+x}$ about $a=0$ by its Taylor polynomial of degree $1,$ $p_{1}(x)=1-x,$ and use it at $x=0.1.$ Here $f''(t)=\dfrac{2}{(1+t)^{3}}.$ Which bound does Fact 5.4 give for the error $|R_{2}(0.1)|?$
- Why is that answer tempting? Bounds the wrong derivative: $|f'(t)|=\dfrac{1}{(1+t)^{2}}\le1$ gives $1\cdot0.1=0.1.$ For $p_{1}$ the remainder contains $f'',$ one derivative more than the degree.
- Why is that answer tempting? Forgets the factorial: $M\cdot(0.1)^{2}=2\cdot0.01.$ The bound (5.2) divides by $(n+1)!=2.$
- Why is that answer tempting? Takes $M$ at the right-hand end, $f''(0.1)=2/1.1^{3}\approx1.50,$ where $|f''|$ is smallest. That bounds nothing: the true error, about $0.0091,$ is larger.
Between $0$ and $0.1$ the function $|f''(t)|=2/(1+t)^{3}$ is largest at $t=0,$ so $M=2$ works. By (5.2) with $n=1,$ $$ |R_{2}(0.1)|\le\frac{2}{2!}\,(0.1)^{2}=0.01\,. $$ Here the true error can be computed: $\dfrac{1}{1.1}=0.90909\ldots$ against $p_{1}(0.1)=0.9,$ an error of about $0.0091,$ which is indeed below $0.01.$
Limits, properly
Does $\lim_{x\to0}1/x$ exist? And if it does not, is that because $1/x$ has no value at $0?$
Lecture 3 defined $\lim_{x\to a}f(x)$ informally and insisted that $x$ must be allowed to approach $a$ from both sides. That insistence can now be made into something checkable.
$\lim_{x\to a}f(x)$ exists if and only if both one-sided limits exist and are equal, in which case all three agree.
That “if and only if” is the whole content of Definition 5.7: it converts an instruction (approach from both sides) into a test you can carry out. In the picture above, the one-sided limits are $B$ and $A,$ they differ, and so there is no limit at $a.$
One phrase has been carried along untouched since Lecture 3, and it is still an instruction rather than a test: as close as we please. It can be made into a test as well, at the cost of two quantifiers.
Read it as a challenge and a response. Someone names a tolerance $\varepsilon$ (the Greek letter epsilon) — how close to $L$ the values are required to come; you must answer with a distance $\delta$ (delta) — how close to $a$ it is enough to stand for that to happen. The limit is $L$ precisely when you have an answer to every challenge, however small. Two features of (5.3) carry the weight. The $\delta$ is allowed to depend on $\varepsilon,$ and normally must: a tighter tolerance demands a smaller neighbourhood. And the left-hand inequality is strict at both ends — $0<|x-a|$ rules out $x=a$ itself, so the definition never so much as mentions $f(a),$ which need not exist.
One piece of notation needs care. If $f(x)$ grows past every bound as $x\to a,$ it is usual to write $f(x)\to\infty.$
Guess first. The next question is part (a) of the example after it. Answer it before you read on.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Does $$\lim_{x \to 0}\frac{1}{x}$$ exist?
- Why is that answer tempting? Treats $\infty$ as a value a limit can take. Also ignores the left-hand side entirely, where the function runs to $-\infty.$
- Why is that answer tempting? Confuses the limit of $1/x$ as $x\to0$ with its limit as $x\to\infty.$
- Why is that answer tempting? Right conclusion, wrong reason — and the reason contradicts Lecture 3. Being undefined at a point never by itself prevents a limit; that was the whole message of the picture of $(e^{x}-1)/x.$
From the right, $1/x \to +\infty$. From the left, $1/x \to -\infty$. The two one-sided limits disagree, so there is no limit.
C is the interesting wrong answer. It reaches the right verdict for a reason that is false in general. Compare with Lecture 3: $$\frac{e^{x}-1}{x}$$ is also undefined at $0$ — and its limit is $1$. A limit never looks at the value at the point.
And A is worth naming too. Even $1/x^2$, which does run to $+\infty$ from both sides, has no limit at $0$. We write $\to \infty$ to say how it fails, not to give an answer.
Three functions undefined at 0
Decide whether each of these limits exists as $x\to0{:}$
(a) $1/x;$
(b) $1/x^{2};$
(c) $(e^{x}-1)/x.$
Try it yourself first. Then open one step at a time.
(a) From the right $1/x\to+\infty;$ from the left $1/x\to-\infty.$ The one-sided limits disagree, so by Fact 5.8 there is no limit.
(b) Here both one-sided limits behave the same way, $1/x^{2}\to+\infty$ from either side — and there is still no limit, because $+\infty$ is not a value either side can converge to. Agreeing on how they fail is not agreeing on a number.
(c) This function is undefined at $0,$ exactly as (a) and (b) are. Its limit is nevertheless $1{:}$ it is the limit that defined $e$ in Definition 4.1.
(a) No limit (the one-sided limits are $-\infty$ and $+\infty$).
(b) No limit ($1/x^{2}\to+\infty$ from both sides).
(c) The limit exists and is $1.$
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Let $f(x)=3x+1,$ so that $\lim_{x\to2}f(x)=7.$ Someone names a tolerance $\varepsilon>0.$ In (5.3), which $\delta$ answers the challenge for every $\varepsilon?$
- Why is that answer tempting? The factor turned upside down. At $x=2+2\varepsilon,$ which is closer to $2$ than $3\varepsilon,$ the value is $7+6\varepsilon,$ further from $7$ than $\varepsilon.$
- Why is that answer tempting? Forgets that $f$ multiplies distances by $3{:}$ $|f(x)-7|=3|x-2|$ can be nearly $3\varepsilon$ when $|x-2|<\varepsilon.$
- Why is that answer tempting? A fixed $\delta$ cannot meet every challenge. For $\varepsilon=0.3$ the point $x=2.5$ is within $1$ of $2,$ but $f(2.5)=8.5$ is $1.5$ away from $7.$ The $\delta$ has to depend on $\varepsilon.$
The distance of the value from $7$ is exactly three times the distance of $x$ from $2{:}$ $$ |f(x)-7|=|3x-6|=3|x-2|\,. $$ So $|f(x)-7|<\varepsilon$ exactly when $|x-2|<\varepsilon/3,$ and $\delta=\varepsilon/3$ answers every challenge. Any smaller $\delta$ would do as well. A tighter tolerance demands a smaller neighbourhood, as the text after Definition 5.9 says.
Continuity, and the licence to substitute
Let $f(x)=\dfrac{x^{2}-4}{x-2}$ for $x\ne2,$ with $f(2)=1.$ Is $f$ continuous at $2?$
A limit never looks at $f(a).$ The next definition is the one that does: it asks whether the value at the point is the one the limit predicts.
Definition 5.13 and Definition 5.14 are two statements of the same thing: a function satisfies one exactly when it satisfies the other. The second is the standard one, and the one met in every later course, so it is worth being able to read; the first is the one to think with here, because it is the one that says what continuity is for.
The informal version — the graph can be drawn without lifting the pencil — is a good picture and a poor definition, and it is Definition 5.13 that survives contact with a function defined piecewise. Since three conditions must hold, there are two genuinely different ways to fail.
A removable discontinuity is not a defect of the function so much as a defect of its definition at one point: the limit was there all along and the value was wrong or missing. That is worth noticing now, because it is the situation of every problem in the last section of this lecture.
Recap The words of this section
| word | what it means at a point $a$ |
|---|---|
| the value | $f(a),$ the number the definition of $f$ assigns to $a$ |
| the limit | the number $f(x)$ approaches as $x\to a$ |
| continuous | the value exists, the limit exists, and they agree |
| discontinuous | not continuous: one of the three fails |
| removable | the limit exists; only the value is wrong or missing |
| irremovable | the limit does not exist |
A piecewise definition often assigns the value separately, as in “$f(2)=1$”. That line is part of the function and has to be read.
Guess first. The next question is the example after it. Answer it before you read on.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
A function is defined by $$f(x) = \frac{x^{2}-4}{x-2} \;\text{ for } x \neq 2, \qquad f(2) = 1$$
Is $f$ continuous at $x = 2$?
- Why is that answer tempting? Simplifies and forgets to look at the assigned value. Cancelling is legal precisely because x ≠ 2, so it says nothing about f(2).
- Why is that answer tempting? Misses that the limit exists. Confuses this with a genuine jump, where the two sides disagree.
- Why is that answer tempting? It is defined at 2 — the stem says f(2) = 1. Reading the definition to the end is part of the question.
For every $x \neq 2$: $$\frac{x^{2}-4}{x-2} = \frac{(x-2)(x+2)}{x-2} = x+2$$ so the limit as $x \to 2$ is $4$.
But $f(2) = 1$. The limit exists, the value exists, and they disagree — so $f$ is discontinuous at $2$, in the removable way. Set $f(2) = 4$ and it becomes continuous.
| condition | holds? |
|---|---|
| $f(2)$ exists | yes, it is $1$ |
| $\lim_{x\to 2}f(x)$ exists | yes, it is $4$ |
| they agree | no |
A removable discontinuity
Let $f(x) = \dfrac{x^{2}-4}{x-2}$ for $x\ne2,$ with $f(2)=1.$ Is $f$ continuous at $2?$
Try it yourself first. Then open one step at a time.
For every $x\ne2,$ $$ \begin{aligned} \frac{x^{2}-4}{x-2} &= \frac{(x-2)(x+2)}{x-2} \\ &= x+2\,, \end{aligned} $$ so $\lim_{x\to2}f(x)=4.$
But $f(2)=1.$ The value exists, the limit exists, and they disagree, so $f$ is discontinuous at $2$ — removably. Setting $f(2)=4$ repairs it.
Note where the trap is. Cancelling $x-2$ is legal because $x\ne2,$ which is the same move that made the Newton quotient work in Lecture 2 — and which is exactly why the cancellation tells you about the limit and nothing at all about $f(2).$ Simplifying and stopping gives the answer $4$ and misses the question.
No. The limit is $4$ and the value is $1,$ so $f$ is discontinuous at $2.$ The discontinuity is removable: $f(2)=4$ repairs it.
Continuity earns its place because of what it licenses.
If $f$ is continuous at $a$ then $\lim_{x\to a}f(x)=f(a)$: you simply substitute. Moreover anything built from constants and $x$ using addition, subtraction, multiplication, division and composition is continuous wherever it is defined — so polynomials are continuous everywhere, rational functions off the zeros of the denominator, and $e^{x}$, $\ln x$ and powers on their domains.
The second sentence is the reason the limit rules of Fact 3.4 felt so obvious when they were stated: they are precisely the assertion that continuity survives arithmetic. And together the two sentences close a loop opened two lectures ago. If substitution works whenever the function is continuous, and almost everything is continuous where defined, then the only limits that require thought are the ones where substituting fails — which, for a quotient, means the ones that come out as $\tfrac00.$
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
For a constant $c,$ let $$ f(x)=\begin{cases}x^{2}+c, & x<2\,,\\ 3x-1, & x\ge2\,.\end{cases} $$ For which $c$ is $f$ continuous at $2?$
- Why is that answer tempting? Fact 5.17 makes each formula continuous on its own piece. At the joint $x=2$ the two one-sided limits still have to agree with each other and with $f(2).$
- Why is that answer tempting? Two formulas can meet without a jump. That is what the question asks you to arrange, and Definition 5.13 is the test, not the look of the definition.
- Why is that answer tempting? Sets $c$ equal to $f(2)=5$ and forgets that $x^{2}$ contributes $4$ at $x=2.$ The left-hand limit is $4+c,$ not $c.$
The value is $f(2)=3\cdot2-1=5,$ and so is the right-hand limit. The left-hand limit is $2^{2}+c=4+c,$ by substituting into the polynomial $x^{2}+c$ (Fact 5.17). All three agree exactly when $4+c=5,$ that is $c=1.$
Reading the signal: l'Hôpital's rule
Substituting $x=0$ into $\dfrac{e^{x}-1}{x}$ gives $\tfrac00.$ Is there a way to read that signal that does not depend on a trick for each function?
The end of the last section leaves one kind of limit that needs thought: the quotient that comes out as $\tfrac00$ when you substitute. It deserves a name.
Let $f$ and $g$ be differentiable near $a$ with $f(a)=g(a)=0$, and suppose $g'(a)\ne0$. Then $$ \lim_{x\to a}\frac{f(x)}{g(x)} = \frac{f'(a)}{g'(a)}\,. \tag{5.5} $$ More generally, and for $\tfrac{\infty}{\infty}$ as well, $\lim_{x\to a} f/g = \lim_{x\to a} f'/g'$ whenever the right-hand limit exists. If that limit is again indeterminate, apply the rule again.
A ratio of two Newton quotients. Since $f(a)=g(a)=0$ we may write, for $x\ne a,$ $$ \begin{aligned} \frac{f(x)}{g(x)} &= \frac{f(x)-f(a)}{g(x)-g(a)} \\ &= \frac{\bigl[f(x)-f(a)\bigr]/(x-a)}{\bigl[g(x)-g(a)\bigr]/(x-a)}\,, \end{aligned} $$ dividing top and bottom by the same nonzero $x-a.$ That is a ratio of two Newton quotients, and letting $x\to a$ turns it into $f'(a)/g'(a).$
The picture. Geometrically: near $a$ each curve is indistinguishable from its own tangent, and both tangents pass through the same point $(a,0).$ The ratio of two lines through a common point is the ratio of their slopes, and that is all the rule says.
0/0 up close
Two curves through the same point $(a,0),$ so their ratio is $\tfrac00$ at $a$ and well behaved on either side.
- Press zoom in. The window around $a$ shrinks, and the two curves straighten into their dashed tangents.
- Watch the two printed numbers: the ratio $f(x)/g(x)$ at the edge of the window, and $f'(a)/g'(a).$ They close in on each other.
- Press the button with the names of the functions to try other pairs: $\ln x$ against $x-1,$ and $e^{x-1}-1$ against $x^{2}-1.$
- The last pair has $g'(a)=0.$ Zoom in and watch the ratio run away. The condition $g'(a)\ne0$ in Fact 5.19 is doing work.
Guess first. The next question is about part (a) of the example after it. Write the rule down as a formula before you choose.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
A student wants $\displaystyle\lim_{x\to 0}\frac{e^{x}-1}{x}$ and writes:
"By l'Hôpital, differentiate: $\dfrac{d}{dx}\dfrac{e^{x}-1}{x} = \dfrac{xe^{x}-(e^{x}-1)}{x^{2}}$ …"
What has gone wrong?
- Why is that answer tempting? The misreading itself. ‘Differentiate’ in the statement of the rule means the two pieces, never the fraction.
- Why is that answer tempting? It is 0/0 — at x = 0 the numerator is e⁰ − 1 = 0 and the denominator is 0. Rejects a perfectly legitimate application.
- Why is that answer tempting? Once is enough: eˣ/1 → 1. Over-application, usually from pattern-matching on a harder worked example.
Numerator and denominator are differentiated separately. The result is a fraction of derivatives, never the derivative of a fraction — the quotient rule has no business here at all.
A pleasing footnote. That limit is the one that defined $e$ in Lecture 4, and the one drawn in Lecture 3's picture of a hole in a graph. It has now appeared three times and been settled three different ways.
Once, and then twice
Evaluate
(a) $\displaystyle\lim_{x\to0}\frac{e^{x}-1}{x}$ and
(b) $\displaystyle\lim_{x\to0}\frac{e^{x}-1-x}{x^{2}}.$
Try it yourself first. Then open one step at a time.
(a) At $x=0$ both parts vanish, so the form is $\tfrac00$ and the rule applies. Differentiating numerator and denominator separately, $$ \lim_{x\to0}\frac{e^{x}-1}{x} = \lim_{x\to0}\frac{e^{x}}{1} = 1\,. $$
(b) Again $\tfrac00;$ differentiating gives $(e^{x}-1)/2x,$ which at $x=0$ is $\tfrac00$ once more. Apply the rule a second time: $$ \begin{aligned} \lim_{x\to0}\frac{e^{x}-1-x}{x^{2}} &= \lim_{x\to0}\frac{e^{x}-1}{2x} \\ &= \lim_{x\to0}\frac{e^{x}}{2} = \frac12\,. \end{aligned} $$
The limit in (a) has now appeared three times in this course: as the picture of a function with a hole in it, as the limit that defined $e,$ and here as a two-line computation.
(a) $1.$ (b) $\tfrac12$ (the rule twice).
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Find $$ \lim_{x\to0}\frac{e^{2x}-1-2x}{x^{2}}\,. $$
- Why is that answer tempting? After one application the numerator $2e^{2x}-2$ is $0$ at $x=0$ — but so is the denominator $2x.$ That is $\tfrac00$ again, a signal to apply the rule once more, not the answer $0.$
- Why is that answer tempting? The inner derivative $2$ of $e^{2x}$ is lost in the second differentiation: $(2e^{2x})'=4e^{2x},$ not $2e^{2x}.$
- Why is that answer tempting? Comes from differentiating $e^{2x}$ to $e^{2x}{:}$ then the first step gives $(e^{2x}-2)/(2x),$ which looks like $-1/0.$ With the chain rule the numerator is $2e^{2x}-2,$ which is $0$ at $x=0.$
At $x=0$ the form is $\tfrac00.$ Differentiating numerator and denominator separately (with the chain rule on $e^{2x}$): $$ \frac{2e^{2x}-2}{2x}\,, $$ which is $\tfrac00$ again. A second application gives $$ \lim_{x\to0}\frac{4e^{2x}}{2}=\frac{4}{2}=2\,. $$ Compare Example 5.20 (b): there the $2$ inside $e^{2x}$ is $1,$ and the answer is $\tfrac12.$
Check the form first
Differentiate top and bottom of $\dfrac{x^{2}+3x}{2x+1}$ and put $x=1{:}$ you get $\tfrac52.$ The limit is $\tfrac43.$ Where did it go wrong?
L'Hôpital's rule has a condition, and the condition is the content: the form must be indeterminate. The second named misuse of the rule is to forget that.
Guess first. The next question is the example after it. Do the one check before you choose.
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
A student computes $$\lim_{x\to 1}\frac{x^{2}+3x}{2x+1}$$ by l'Hôpital: differentiating top and bottom gives $\dfrac{2x+3}{2}$, which at $x = 1$ is $\dfrac{5}{2}$.
The true value is $\dfrac{4}{3}$. What went wrong?
- Why is that answer tempting? It is not — the derivatives are correct. The error is upstream, in whether the rule applied at all.
- Why is that answer tempting? Applying an inapplicable rule twice does not repair it. A reflex from worked examples where repetition was the fix.
- Why is that answer tempting? Confuses this with the error of Watch out 5.21. Here nothing needed differentiating at all.
At $x = 1$ the numerator is $1 + 3 = 4$ and the denominator is $3.$ That is $\tfrac43$ — an ordinary quotient of continuous functions, not indeterminate.
Both are continuous at $1$ and the denominator is non-zero, so by Fact 5.17 you simply substitute. l'Hôpital never applied.
This is the dangerous failure. The rule did not complain. It returned $\tfrac52,$ which looks exactly like an answer, and only checking the form would have caught it.
A rule that fails silently
A student evaluates $\displaystyle\lim_{x\to1}\frac{x^{2}+3x}{2x+1}$ by differentiating top and bottom, obtaining $(2x+3)/2,$ which at $x=1$ is $\tfrac52.$ The true value is $\tfrac43.$ What went wrong?
Try it yourself first. Then open one step at a time.
Nothing after the first step: the derivatives are correct. The error is that the rule never applied.
At $x=1$ the numerator is $4$ and the denominator is $3,$ so the form is $\tfrac43$ — an ordinary quotient of functions continuous at $1$ with nonzero denominator. By Fact 5.17 you substitute, and you are finished.
The failure is silent. Nothing complained, and $\tfrac52$ looks exactly like an answer. A two-second check of the form would have caught it, which is precisely why the check must become automatic.
The form at $x=1$ is $\tfrac43,$ not indeterminate, so l'Hôpital's rule does not apply. Substituting gives the limit $\tfrac43.$
Everything in this lecture now collapses into one procedure.
The Method at work, once for each of its first three steps. The example is the app's own, not one of the notes' numbered examples.
Method 5.24 on three limits
Find, or show that there is none:
(a) $\displaystyle\lim_{x\to2}\frac{x^{2}+1}{x+3};$
(b) $\displaystyle\lim_{x\to1}\frac{x+2}{x-1};$
(c) $\displaystyle\lim_{x\to0}\frac{\ln(1+2x)}{x}.$
Try it yourself first. Then open one step at a time.
(a) Step 1, substitute. The function is rational and its denominator is $5\ne0$ at $x=2,$ so it is continuous there (Fact 5.17) and the limit is the value, $\dfrac{4+1}{5}=1.$
(b) Step 2, $c/0.$ Substituting gives $\tfrac30.$ There is no limit. To say how it fails: for $x$ just above $1$ the quotient is a positive number over a small positive one, so it tends to $+\infty;$ just below $1$ the denominator is negative and the quotient tends to $-\infty.$ The one-sided limits differ (Fact 5.8).
(c) Step 3, $\tfrac00.$ At $x=0$ the numerator is $\ln1=0$ and the denominator is $0.$ Nothing factors, so use l'Hôpital's rule: the numerator has derivative $\dfrac{2}{1+2x}$ (chain rule), the denominator $1.$
(c) Step 4, repeat from step 1. What is left, $\dfrac{2}{1+2x},$ is continuous at $0,$ so substitute: $$ \lim_{x\to0}\frac{\ln(1+2x)}{x}=\frac{2}{1}=2\,. $$
(a) $1.$ (b) No limit ($-\infty$ from the left, $+\infty$ from the right). (c) $2.$
Addition: limits as $x\to\infty$
What is $\sqrt{4x^{2}+3x}-2x$ close to when $x$ is a million?
This section is not in the lecture notes. It is added here because every exam of the course has a limit as $x\to\infty,$ and the notes compute none. It uses nothing new: Definition 5.18 already names the form $\tfrac{\infty}{\infty},$ and Watch out 5.10 says what $f(x)\to\infty$ means.
$\lim_{x\to\infty}f(x)=L$ means that $f(x)$ can be made as close to $L$ as we please by taking $x$ large enough. Two facts do most of the work: $1/x\to0,$ and so $c/x^{k}\to0$ for every constant $c$ and every $k>0;$ and the limit rules of Fact 3.4 hold as $x\to\infty$ just as they do as $x\to a.$
Leading terms
For large $x$ a polynomial is dominated by its leading term. So divide numerator and denominator by the highest power of $x$ in the denominator: every other term becomes a constant over a power of $x,$ and tends to $0.$
A quotient of polynomials
Find $\displaystyle\lim_{x\to\infty}\frac{3x^{2}-5x+1}{6x^{2}+x-4}.$
Try it yourself first. Then open one step at a time.
The form. Numerator and denominator both grow past every bound, so the form is $\tfrac{\infty}{\infty}{:}$ there is work to do.
Divide by $x^{2}.$ For $x\ne0,$ $$ \frac{3x^{2}-5x+1}{6x^{2}+x-4} =\frac{3-\dfrac5x+\dfrac1{x^{2}}}{6+\dfrac1x-\dfrac4{x^{2}}}\,. $$
Let $x\to\infty.$ Every fraction with $x$ in its denominator tends to $0,$ so the limit is $\dfrac{3}{6}=\dfrac12,$ the ratio of the leading coefficients.
The limit is $\tfrac12.$
The same division settles every quotient of polynomials. If the degrees are equal, the limit is the ratio of the leading coefficients. If the numerator has the lower degree, the limit is $0.$ If it has the higher degree, the quotient grows past every bound in size: there is no limit, and one writes $\to\infty$ or $\to-\infty$ to say how it fails.
A difference with a root: the conjugate
A difference such as $\sqrt{4x^{2}+3x}-2x$ is of the form $\infty-\infty,$ which is just as indeterminate as $\tfrac00{:}$ the two parts grow, and how their difference behaves depends on how fast each grows. The way in is to multiply and divide by the conjugate $\sqrt{4x^{2}+3x}+2x,$ because $$ \bigl(\sqrt{A}-B\bigr)\bigl(\sqrt{A}+B\bigr)=A-B^{2} $$ has no root left in it.
A root minus a line: the conjugate
Find $\displaystyle\lim_{x\to\infty}\Bigl(\sqrt{4x^{2}+3x}-2x\Bigr).$
Try it yourself first. Then open one step at a time.
Multiply and divide by the conjugate. For $x>0$ the root is defined and $$ \begin{aligned} &\sqrt{4x^{2}+3x}-2x \\ &\quad=\frac{(4x^{2}+3x)-4x^{2}}{\sqrt{4x^{2}+3x}+2x} \\ &\quad=\frac{3x}{\sqrt{4x^{2}+3x}+2x}\,. \end{aligned} $$ Now the form is $\tfrac{\infty}{\infty}.$
Divide by $x.$ For $x>0$ we have $x=\sqrt{x^{2}},$ so $$ \begin{aligned} \frac{\sqrt{4x^{2}+3x}}{x}&=\sqrt{\frac{4x^{2}+3x}{x^{2}}}\\ &=\sqrt{4+\frac3x}\,, \end{aligned} $$ and $$ \begin{aligned} &\frac{3x}{\sqrt{4x^{2}+3x}+2x}\\ &\quad=\frac{3}{\sqrt{4+\frac3x}+2}\,. \end{aligned} $$
Let $x\to\infty.$ $\dfrac3x\to0,$ and the root is continuous, so $\sqrt{4+3/x}\to2$ (Fact 5.17). The limit is $\dfrac{3}{2+2}=\dfrac34.$
A check with a number. At $x=1000$ the expression is $\sqrt{4\,003\,000}-2000\approx0.74986.$
The limit is $\tfrac34.$
Two remarks that exam solutions are expected to make.
Why $x>0$ matters. The step $x=\sqrt{x^{2}}$ is true only for $x\ge0;$ for negative $x,$ $\sqrt{x^{2}}=-x.$ As $x\to\infty$ we may take $x>0,$ and the solution should say so.
Not every difference has a limit. If the root and the other term grow at different rates, the larger one wins. For example, for $x>0$ $$ x-\sqrt{4x^{2}+x}=x\Bigl(1-\sqrt{4+\tfrac1x}\Bigr)\,, $$ where the bracket tends to $1-2=-1.$ So the expression tends to $-\infty{:}$ there is no limit (Watch out 5.10).
Pick an answer before reading on. Getting it wrong is fine — that is how you find out what you believe.
Find $\displaystyle\lim_{x\to\infty}\Bigl(x-\sqrt{x^{2}+4x}\Bigr).$
- Why is that answer tempting? Reads $\infty-\infty$ as $0,$ as if $\infty$ were a number (Watch out 5.10). It is an indeterminate form: the two parts grow, and the answer depends on how they grow.
- Why is that answer tempting? Right numerator $-4x,$ but the denominator $x+\sqrt{x^{2}+4x}$ is about $2x,$ not $x{:}$ the root grows like $x$ too.
- Why is that answer tempting? A sign lost in the conjugate step: $(x)^{2}-(x^{2}+4x)=-4x,$ not $+4x.$ The root is larger than $x,$ so the difference is negative.
Multiply and divide by the conjugate $x+\sqrt{x^{2}+4x}{:}$ $$ \begin{aligned} x-\sqrt{x^{2}+4x} &=\frac{x^{2}-(x^{2}+4x)}{x+\sqrt{x^{2}+4x}} \\ &=\frac{-4x}{x+\sqrt{x^{2}+4x}} \\ &=\frac{-4}{1+\sqrt{1+\frac4x}}\,, \end{aligned} $$ dividing by $x>0$ in the last step. As $x\to\infty$ the root tends to $1,$ and the limit is $\dfrac{-4}{2}=-2.$
What you should take away
- Taylor's formula turns $\approx$ into $=$: $f(x) = p_{n}(x) + R_{n+1}(x)$ with $R_{n+1}(x) = f^{(n+1)}(z)(x-a)^{n+1}/(n+1)!$ for some $z$ between $a$ and $x.$ The remainder is the next term with the derivative taken at an unknown point.
- “For some $z$” is an existence claim, not a universal one — and not knowing $z$ costs nothing: bounding $|f^{(n+1)}|$ by $M$ gives $|R_{n+1}(x)|\le M|x-a|^{n+1}/(n+1)!.$ Errors die for two reasons, the factorial and the power.
- The limit at $a$ exists exactly when both one-sided limits exist and agree. $\infty$ is not a number: $f\to\infty$ names a way of failing. A limit never looks at $f(a).$
- Continuous at $a$ means $\lim_{x\to a}f(x)=f(a)$ — three conditions. Failure is removable when the limit exists and the value is wrong, irremovable when the limit does not exist.
- Continuity is the licence to substitute, and almost everything is continuous where defined. So the only limits needing thought are the ones where substitution gives $\tfrac00.$
- l'Hôpital: for $\tfrac00$ or $\tfrac{\infty}{\infty},$ $\lim f/g = \lim f'/g'$ — a fraction of derivatives, never the derivative of a fraction, and void unless the form is indeterminate. It fails silently when misapplied, which is why the check comes first.
Think further
Questions without computation. Think on your own or with a classmate before opening the thought.
Discussion question 1 — what z is
In Taylor's formula, what is $z?$
(A) a number you can compute from $f,$ $n$ and $x;$
(B) any number between $a$ and $x$ — the formula holds for all of them;
(C) a number that exists but is generally unknown;
(D) the point where the approximation is exact.
One way to think about it
(C). Taylor's formula is an existence statement (Watch out 5.2): some $z$ between $a$ and $x$ makes it true, and the theorem does not say which. (A) reads it as a formula; $z$ depends on $f,$ $n$ and $x,$ but there is no expression for it. (B) is refuted by Example 5.3: for $f(x)=x^{3}$ with $a=0$ and $n=1$ only $z=x/3$ works. (D) mixes up the point where the derivative in the remainder is taken with a point where $f$ and $p_{n}$ agree; they agree at $a.$ Not knowing $z$ costs nothing, because Fact 5.4 only needs a bound $M$ that holds wherever $z$ is.
Discussion question 2 — one more term for √25.01
In Example 5.6, how would the bound change if you used $n=2$ instead of $n=1?$ Which of the two factors in (5.2) does the extra term improve?
One way to think about it
With $n=2$ the remainder contains $f'''(t)=\tfrac38(25+t)^{-5/2},$ largest at $t=0{:}$ $M=\tfrac38\cdot25^{-5/2}=\tfrac{3}{25\,000}.$ Then $$ \begin{aligned} |R_{3}(0.01)|&\le\frac{M}{3!}\,(0.01)^{3}\\ &=\frac{1}{50\,000}\cdot10^{-6}=2\cdot10^{-11}\,, \end{aligned} $$ against $10^{-7}$ for $n=1.$ (The approximation itself becomes $p_{2}(0.01)=5.001-10^{-7}=5.0009999.$)
The extra term improves both factors of (5.2): the factorial grows from $2!$ to $3!,$ a gain of a factor $3,$ and the power goes from $(0.01)^{2}$ to $(0.01)^{3},$ a gain of a factor $100.$ Here the power does most of the work, because $|x-a|=0.01$ is small; far from the centre it would be the factorial alone that helps, and not by much. (The new $M$ is also smaller than $\tfrac1{500}.$)
Discussion question 3 — two right verdicts, one right reason
Does $\lim_{x\to0}1/x$ exist?
(A) yes, it is $\infty;$
(B) yes, it is $0;$
(C) no, because $1/x$ is undefined at $0;$
(D) no, because the one-sided limits differ.
Two of these reach a correct verdict. Why is only one of them right?
One way to think about it
(C) and (D) both say “no”. Only (D) gives a reason that is true: by Fact 5.8 the limit fails because the one-sided limits, $-\infty$ and $+\infty,$ differ (and neither is a number). The reason in (C) is false in general: $(e^{x}-1)/x$ is undefined at $0$ too, and its limit is $1$ (Example 5.11, Watch out 5.12). (A) treats $\infty$ as a value (Watch out 5.10), and (B) gives the limit of $1/x$ as $x\to\infty.$
Discussion question 4 — two irremovable discontinuities
Give a function with an irremovable discontinuity at $0$ whose one-sided limits both exist. Then give one whose one-sided limits do not.
One way to think about it
A jump: $f(x)=0$ for $x<0$ and $f(x)=1$ for $x\ge0.$ The left-hand limit is $0$ and the right-hand limit is $1.$ Both exist, they differ, so there is no limit (Fact 5.8) and no value of $f(0)$ can repair it.
For the second, let $g(x)=1/x$ for $x\ne0$ and $g(0)=0.$ Now neither one-sided limit exists: $g(x)\to+\infty$ from the right and $g(x)\to-\infty$ from the left. ($1/x^{2},$ with any value at $0,$ would do as well.)
Discussion question 5 — the misread word
A student differentiates $(e^{x}-1)/x$ using the quotient rule and calls it l'Hôpital. Which word in the statement of the rule did they misread?
One way to think about it
The rule differentiates numerator and denominator separately — the word in step 3 of Method 5.24. In (5.5) the primes stand on $f$ and on $g,$ one each: a fraction of derivatives, $f'/g',$ never the derivative of the fraction $f/g$ (Watch out 5.21). Done correctly, $\dfrac{e^{x}-1}{x}$ gives $\dfrac{e^{x}}{1}\to1.$
Discussion question 6 — l'Hôpital and the linear approximation
Evaluate $\displaystyle\lim_{x\to0}\frac{\ln(1+x)}{x}$ twice: once by l'Hôpital, and once using the linear approximation of Example 4.18. Why do the two agree?
One way to think about it
By l'Hôpital: the form is $\tfrac00,$ and $\dfrac{1/(1+x)}{1}\to1.$ By the linear approximation $\ln(1+x)\approx x$ of Example 4.18 the quotient is close to $\dfrac{x}{x}=1.$ Both give $1.$
They agree because they are the same idea. The why of Fact 5.19 replaces each of $f$ and $g$ near $a$ by its tangent, and the tangent is the linear approximation: here $\ln(1+x)\approx0+1\cdot x$ and $x=0+1\cdot x.$ The ratio of the two slopes, $\tfrac11,$ is $f'(0)/g'(0).$
Discussion question 7 — why substitution comes first
Why does Recipe 5.24 put substitution first, rather than last?
One way to think about it
Because it settles most limits at once: wherever the function is continuous the limit is the value (Fact 5.17), and almost everything is continuous where defined. And because substituting is the check that the later steps need. l'Hôpital's rule is void unless the form is indeterminate (Watch out 5.22); applied to $\tfrac43$ it returns $\tfrac52$ without complaint (Example 5.23). Put last, substitution would come after the only step that can go silently wrong.