On this screen we’ll introduce linear approximations and, among other things, estimate (3.01)^2 and (0.99)^3, and see how Calculus approximations work using interactive Desmos graphs.
Recall that in the preceding Topic, we considered the scenario of Syd biking up a curved path. As he passed the horizontal position $x=3.00$ m, the path climbs at the rate $\left.\dfrac{dy}{dx}\right|_\text{at x = 3.00 m} = 6.00 \, \tfrac{\text{vertical m}}{\text{horizontal m}}.$ With this information, we calculated the small change in his vertical position, dy, when he moved forward the small horizontal distance dx:
\begin{align*}
{\rm\small small\,change\,in\,vert\,position} &= {\rm\small (rate\,at\,horiz\,position}\,\small { x=3.00}\rm\small m) * \rm\small{(small\,change\,in\,horiz\,position)} \\[8px]
dy &= \left( \left.\frac{dy}{dx}\right|_\text{at $x=3.00$ m} \right)\cdot dx
\end{align*}
And we calculated his vertical position after he had moved forward the small horizontal distance dx as
\[ \overbrace{y(x+dx)}^\text{$y$ value, at $x+dx$} = \overbrace{y(x)}^{\text{$y$ value, at }x} + \overbrace{\text{ small change }dy}^{\text{(rate at $x$)} * \, dx} \]
Let’s now consider a more mathematical example. Note that while the words may be different, the ideas and calculations are exactly the same as in that scenario. Keep the picture of Syd biking uphill in your mind as you consider the requested calculation.
Consider the function $f(x) = x^2,$ graphed to the right.
You know that at $x=3,$ $f(3) = 3^2 = 9.$
For now, we’ll simply tell you that the rate the function “climbs” at $x=3$ is exactly 6: \[\left.\dfrac{df}{dx}\right|_\text{at x = 3.00} = 6\] (Later we’ll show you how to determine this rate for yourself, a fundamental Calculus skill; Activity 2 below will also address this value. For now, so you can start doing “real” Calculus calculations, let’s just take the rate as a given.)
Solution.
(a) Let’s perform exactly the same calculation as we did to find Syd’s change in vertical position.
We know $f(3) = 9$ and $\left.\frac{df}{dx}\right|_\text{at x = 3.00} = 6,$ and we have $dx = 0.01.$
So using the same formulation as before:
\begin{align*}
\overbrace{f(x+dx)}^\text{$f$ value at $x+dx$} &= \overbrace{f(x)}^{\text{$f$ value at }x} + \overbrace{\text{ small change }df}^{\text{(rate at $x$)} * \, dx} \\[8px]
f(3.01) = f(3 + 0.01)&= f(3) + (6) \cdot (0.01) \\[8px]
&= 9 + 0.06 \\[8px]
&= 9.06 \quad \cmark
\end{align*}
Note that the actual value is $f(3.01) = (3.01)^2 = 9.0601,$ so this is a pretty great estimate for such a quick calculation! We’ll discuss the tiny discrepancy between the values 9.06 and 9.0601 (a difference of 0.001%) below.
(b) The formulation for this calculation is the same, but now we have $dx=0.5:$
\begin{align*}
\overbrace{f(x+dx)}^\text{$f$ value at $x+dx$} &= \overbrace{f(x)}^{\text{$f$ value at }x} + \overbrace{\text{ small change }df}^{\text{(rate at $x$)} * \, dx} \\[8px]f(3.5) = f(3 + 0.5)&\approx f(3) + (6) \cdot (0.5) \\[8px]
&\approx 9 + 3 \\[8px]
&\approx 12 \quad \cmark
\end{align*}
The actual value is $f(3.5) = (3.5)^2 = 12.25,$ so this is a less-good estimate than we made in (a). We’ll discuss the larger discrepancy between the values 12 and 12.25 (a difference of 2%) immediately after this example.
Let’s now use the following Activities to dig in and see why in Example 1 the approximation for $(3.01)^2$ works well and yet doesn’t return the exact result, and why the approximation for $(3.5)^2$ works less well.
The interactive Desmos graph below shows the curve $y = x^2.$
Step 1. First, use the “+” button on the graph below to zoom in on the curve. Drag the curve as needed to keep the point $(3,9)$ near the center of the calculator’s window. (Text will appear on the graph as you zoom, and will tell you when to proceed to Step 2.)
Step 2. You’ve just seen one of the key insights of Calculus: for most functions, when you “zoom in” sufficiently and look at a small region around a point of interest, the function’s curve looks like a line. And we like lines, a lot(!), because linear functions are super-easy to work with. Indeed, one MAJOR application of Calculus is to replace a small section of a function’s curve with an appropriate line segment. For instance, in the calculation you did to find $(3.01)^2$ above, we used the fact that the curve looks like a line with slope = 6 close to the point $(3,9).$
To see that this is so, first check this box to zoom the graph above to a convenient size:
And now compare that “curve” above with the line in the graph below: they are essentially indistinguishable – as long as we’re zoomed in sufficiently in the top graph.
If you’d like, you can check this box to show the curve $y=x^2$ on this graph:
If you now zoom out and in, you can see how the green line and red curve look indistinguishable when you’re sufficiently zoomed-in, but are quite different when you’re zoomed-out.
The simple insight here about how the curve and line are indistinguishable when you’re sufficiently “zoomed in” in one of the key insights for all of Calculus.
PART 1. Let’s tie the pieces together and revisit graphically the calculation we made in Example 1 above to find $(3.01)^2$. First, recall that calculation:
\begin{align*}
\overbrace{f(x+dx)}^\text{$f$ value at $x+dx$} &\approx \overbrace{f(x)}^{\text{$f$ value at }x} + \overbrace{\text{ small change }df}^{\text{(rate at $x$)} * \, dx} \\[8px]
f(3.01) = f(3 + 0.01)&\approx f(3) + (6) \cdot (0.01) \\[8px]
&\approx 9 + 0.06 \\[8px]
&\approx 9.06
\end{align*}
The graph below once again shows $y = x^2,$ with the point $(3,9)$ highlighted.
More generally, for any value of dx we have
\begin{align*}
f(3+dx) &= (3 + dx)^2 \\[8px]
&= (3)^2 + 2(3)\, dx + (dx)^2 \\[8px]
&= 9 + 6\,dx + (dx)^2
\end{align*}
Using our linear approximation approach, we again drop the quadratic $(dx)^2$ term, giving us an equation that depends linearly on dx:
\[f(3+dx) \approx 9 + 6\,dx\]
We thus see why we’ve been using the rate near $x=3$ of $\left.\frac{df}{dx}\right|_\text{at x = 3.00} = 6:$ it’s the correct multiplicative factor for this linear approximation. We simply provided that value in Scenario 1 and Example 1 above; here we see through this algebraic approach where the value comes from. Note, however, that although in this case we could use simple algebra [expanding the quadratic $(3+dx)^2$] to find this rate, most functions do not allow for such an algebraic expansion. Hence a lot of our early work in the course will be to find ways to determine the rate of change for any function we encounter.
We’ve seen thus far that our linear approximation method works by replacing a function’s curve in a region around a specific point with a line that mimics the function’s behavior at nearby points. The approach of course introduces some error, since we’re following a line rather than the actual curve – and the farther we get from $x=3,$ the more the line deviates from the curve.
Let’s look more closely at this error that we introduce when using the linear approximation.
We saw in Example 1 above that when we use the linear approximation method to calculate $(3+dx)^2,$ the percentage error when we calculate $(3.01)^2$ is only 0.001%. By contrast, the percentage error when we calculate $(3.5)^2$ is 2%, an error 2000-times as large.
PART 1: Approximation for $(3.5)^2$
Let’s look graphically at each calculation to see why the approximation gets worse as we move away from $x=3.$ We’ll look first at $(3.5)^2$. The exact value is
\begin{align*}
f(3.5) = f(3+0.5) &= (3+ 0.5)^2 \\[8px]
&= (3)^2 + 2(3)(0.5) + (0.5)^2 \\[8px]
&= 9 + 6(0.5) + (0.5)^2 \\[8px]
&= 9 + 3 + 0.25 = 12.25
\end{align*}
On the graph below, we show this point on the red curve $f(x) = x^2$ as “Actual value: $f(3.5) = 12.25.$”
By contrast, our approximation throws away the $(0.5)^2$ term, so we have
\begin{align*}
f(3+0.5) &\approx 9 + 6(0.5) \\[8px]&\approx 9 + 3 = 12
\end{align*}
We show that point in the graph on the green line (with slope = 6) as “Approx value $f(3.5) \approx 12.$”
The vertical distance between those two points is exactly the approximation’s error, equal to $(0.5)^2 = 0.25.$
You might zoom out and in to get a sense for how the line is deviating from the curve here.
PART 2: Approximation for $(3.01)$
Let’s now look once again at our approximation for $(3.01)^2.$ The exact value is
\begin{align*}
f(3.01) = f(3+0.01) &= (3+ 0.01)^2 \\[8px]
&= 9 + 6(0.01) + (0.01)^2 \\[8px]
&= 9 + 0.06 + 0.0001 = 9.0601
\end{align*}
We show this point on the graph below as “Actual value: $f(3.01) = 9.0601.$”
By contrast, our approximation throws away the tiny $(0.01)^2$ term, so we have
\begin{align*}
f(3+0.01) &\approx 9 + 6(0.01) \\[8px]
&\approx 9 + .06 = 9.06
\end{align*}
We show that point on the graph as “Approx value $f(3.01) \approx 9.06.$”
Notice that even though this graph is zoomed-in considerably more than the graph above, you still can’t even see the error initially. Instead you have to zoom in even further to see the gap of $(0.01)^2 = 0.0001$ between the approximate value and the actual value. The reason: the line is much closer to the curve for $dx = 0.01$ than for $dx = 0.5,$ which in turn is the reason we say dx needs to be “small.” Generally, the smaller dx is, the better our approximation will be.
Let’s consider another example function, one for which we’re dropping even more terms when we do our approximation.
Consider the function $g(x) = x^3,$ shown to the right.
You know that at $x = 1,$ $g(1) = (1)^3 = 1.$
We are given that at $x = 1,$ the function changes at the rate
\[\left.\dfrac{dg}{dx}\right|_\text{at x = 1} = 3\]
Using this information, find the approximate value of $(0.99)^3.$
Solution
We’ll use exactly the same approach as we did for Syd’s bike ride and as we did in Example 1. Note that this time dx is negative, $dx = -0.01,$ since the x-value we’re asked about (0.99) is a little less than the value we know about (at $x=1$).
\begin{align*}
\overbrace{g(x+dx)}^\text{$g$ value at $x+dx$} &= \overbrace{g(x)}^{\text{$g$ value at }x} + \overbrace{\text{ small change }dg}^{\text{(rate at $x$)} * \, dx} \\[8px]
g(0.99) = g\big(1 + (-0.01)\big)&\approx g(1) + (3) \cdot (-0.01) \\[8px]
&\approx 1 \,-\, 0.03 \\[8px]
&\approx 0.97 \quad \cmark
\end{align*}
The actual value is $(0.99)^3 = 0.970299,$ a difference of 0.031%.
We’ll once again expore the error between our linear approximation and the actual value in the next Activity.
PART 1. Let’s tie examine graphically the calculation we made in Example 2 above to find the approximation to $(0.99)^3$.
The interactive Desmos graph below shows the curve $y = x^3,$ with the point $(1,1)$ highlighted.
PART 2. Let’s again use some algebra to see why this linear approximation works. First, recall that
\[(a+b)^3 = a^3 + 3a^2b + 3ab^2 + b^3\]
More generally, for any value of dx we have
\begin{align*}
g(1+dx) &= (1 + dx)^3 \\[8px]
&= (1)^2 + 3(1)^2\, dx + 3(1)(dx)^2 + (dx)^3 \\[8px]
&= 1 + 3\,dx + 3(dx)^2 + (dx)^3
\end{align*}
Using our linear approximation approach, we drop the third $3(dx)^2$ term and the fourth $(dx)^3$ term, giving us an equation that depends linearly on dx:
\[g(1+dx) \approx 1 + 3\,dx\]
By the way, by expanding the polynomial we once again just developed the rate of change for the function $g(x) = x^3$ at $x=1$, $\left.\frac{dg}{dx}\right|_\text{at x = 1} = 3,$ which is the multiplicative factor for the linear approximation here. We can again do this because we had a simple polynomial we could expand in $(1+dx)^3.$ Remember that most functions do not allow for such an algebraic expansion, and so we still need to develop methods to determine the rate of change for any function we encounter.
The Examples and Activities above illustrate how linear approximations work: we keep only the linear term dx, which is known as the first-order term because it’s dx to the first-power. By contrast, we drop all of the higher-order terms, here the second-order term $(dx)^2$ and the third-order term $(dx)^3.$ We’ll learn much later in the course how to improve our approximations by including as many such higher-order terms as we’d like.
Time to practice some similar calculations for yourself! On the next screen you will find problems to practice with – each with a complete solution immediately available so you can easily check your work, or in case you need help. In the first problem you’ll see how you can use our linear approximation method to estimate $\sqrt{16.2}.$
☕ Buy us a coffee We're working to add more,
and would appreciate your help
to keep going! 😊
What are your thoughts or questions?