Linearization of a Function

Recall the definition of \(f'(x_{0})\): \[\lim_{\Delta x\to0}\frac{f(x_{0}+\Delta x)-f(x_{0})}{\Delta x}=f'(x_{0}).\] From the definition of a limit, we know that for \(x\) close to \(x_{0}\), the fraction \([f(x_{0}+\Delta x)-f(x_{0})]/\Delta x\) must be close to \(f'(x_{0})\); that is, for \(x\) close to \(x_{0}\) \[\frac{f(x_{0}+\Delta x)-f(x_{0})}{\Delta x}\approx f'(x_{0}).\] Multiplying both sides by \(\Delta x\), we get \[f(x_{0}+\Delta x)-f(x_{0})\approx f'(x_{0})\Delta x.\] In terms of \(x=x_{0}+\Delta x\), we have \[f(x)-f(x_{0})\approx f'(x_{0})(x-x_{0})\] or \[f(x)\approx f(x_{0})+f'(x_{0})(x-x_{0}).\] Let’s denote the right-hand side by \(L(x)\): \[L(x)=f(x_{0})+f'(x_{0})(x-x_{0}).\] The graph of the function \(L\) is the tangent line to the curve \(y=f(x)\) at \(\left(x_{0},f(x_{0})\right)\).1 It is also clear from Figure 1 that the tangent line at \(\left(x_{0},f(x_{0})\right)\) is a good approximation to \(f(x)\) when \(x\) is close to \(x_{0}\).

Definition. The function \(L\) \[L(x)=f(x_{0})+f'(x_{0})(x-x_{0})\] is called the linearization of \(f\) at \(x_{0}\), and the approximation \(f(x)\approx L(x)\) or \[f(x)\approx f(x_{0})+f'(x_{0})(x-x_{0}).\] is called the linear approximation or tangent line approximation of \(f\) at \(x_{0}\).2 
  • If we use the delta notation \(\Delta y=f(x)-f(x_{0})\) and \(\Delta x=x-x_{0}\), then we can write the linear approximation as \[\underbrace{\Delta y}_{f(x)-f(x_{0})}\approx f'(x)\underbrace{\Delta x}_{x-x_{0}}\]
Figure 1. The tangent line to the curve \(y=f(x)\) at \((x_{0},f(x_{0}))\) is the line \(L(x)=f(x_{0})+f'(x_{0})(x-x_{0})\). When \(x\) is close to \(x_{0}\), \(f(x)\approx L(x)\).


Read more about the meaning of linearization

For example, if \(y=f(x)=x^{2}\), then \[f'(x)=2x\] and the linear approximation is \[\underbrace{f(x+\Delta x)}_{(x+\Delta x)^{2}}\approx\underbrace{f(x)}_{x^{2}}+2x\Delta x\] and by expanding \((x+\Delta x)^{2}\), we have \[x^{2}+2x\,\Delta x+\left(\Delta x\right)^{2}\approx x^{2}+2x\,\Delta x.\] This approximation tells us that if \(\Delta x\) is small, \((\Delta x)^{2}\) is negligible. This makes sense, because when \(\Delta x\) is small, \((\Delta x)^{2}\) is the square of a small number and this is much smaller than \(\Delta x\) itself. For example, if \(\Delta x=0.001\) then \((\Delta x)^{2}=0.000000001\).

For the geometrical interpretation of this approximation, consider a square having sides \(x\) by \(x\), and suppose that each side is increased to \(x+\Delta x\) (Figure 2). The enlarged square is made up of the original square of area \(x^{2}\), two rectangles at the top and on the right, each of which is of area \(x\cdot\Delta x\), and the little square at the top right corner of area \((\Delta x)^{2}\). We may ignore this little square and say that the area of the enlarged square is approximately \(x^{2}+2x\,\Delta x.\)

Figure 2


Example 1

Use the linearization of \(f(x)=\sqrt{x}\) at \(x_{0}=9\) to approximate \(\sqrt{10}\) and \(\sqrt{8}\).

Solution 1

The linearization of \(f\) at \(x=9\) is \[L(x)=f(9)+f'(9)(x-9).\] Because \[f(x)=\sqrt{x}\Rightarrow f'(x)=\frac{1}{2\sqrt{x}},\] we have \(f(9)=3\) and \(f'(9)=1/6\), and thus \[L(x)=3+\frac{1}{6}(x-9).\] The graphs of \(f\) and \(L\) are illustrated in Figure 3.

At \(x=10\), the linearization gives \[L(10)=3+\frac{1}{6}\cdot(10-9)\approx3.16667.\] The true value of \(\sqrt{10}\) to 5 digits is 3.16228.

At \(x=8\), the linearization gives \[L(8)=3+\frac{1}{6}\cdot(8-9)\approx2.83333.\] The true value of \(\sqrt{8}\) to 5 digits is 2.8284.

Figure 3. The graghs of \(f(x)=\sqrt{3}\) and its linearization at \(x=9\), \(L(x)=3+(x-9)/6\).
Example 2

Approximate \(\sin(31^{\circ})\) and \(\sin(29^{\circ})\).

Solution 2

Because we know the exact value of \(\sin(30^{\circ})=\sin(\pi/6)\), we can use the linearization of \(f(x)=\sin x\) at \(x=\pi/6\) to approximate \(\sin(31^{\circ})\) and \(\sin(29^{\circ})\). The derivative of \(f\) is \[f'(x)=\cos x.\] So we have \(f(\pi/6)=1/2\) and \(f'(\pi/6)=\cos(\pi/6)=\sqrt{3}/2\).

The linearization of \(f\) at \(x=\pi/6\) is \[L(x)=\underbrace{\frac{1}{2}}_{f(\pi/6)}+\underbrace{\frac{\sqrt{3}}{2}}_{f'(\pi/6)}\underbrace{\Delta x}_{\left(x-\frac{\pi}{6}\right)}.\] Notice that \(\frac{d}{dx}\sin x=\cos x\) works only when \(x\) is in radian measure. Therefore, \(\Delta x\) is also in radians.

Because \[1^{\circ}=\frac{\pi}{180}\text{ radian,}\] we have

\[\begin{aligned} \sin(31^{\circ}) & \approx L\left(\frac{\pi}{6}+\frac{\pi}{180}\right)=\frac{1}{2}+\frac{\sqrt{3}}{2}\left(\frac{\pi}{180}\right)\\ & \approx0.5151.\end{aligned}\] and \[\begin{aligned} \sin(29^{\circ}) & \approx L\left(\frac{\pi}{6}-\frac{\pi}{180}\right)=\frac{1}{2}+\frac{\sqrt{3}}{2}\left(-\frac{\pi}{180}\right)\\ & \approx0.4849.\end{aligned}\] The true values of \(\sin(31^{\circ})\) and \(\sin(29^{\circ})\) to 4 digits are 0.5150 and 0.4848, respectively. The graphs of \(f\) and its linearization are illustrated in Figure 4.

Figure 4. The graphs of \(y=\sin x\) and \(y=\frac{1}{2}+\frac{\sqrt{3}}{2}\left(x-\frac{\pi}{6}\right)\).
Example 3

What is the linear approximation of \(f(x)=\sin x\) at \(x=0\)? For what values of \(x\) is this linear approximation accurate to within 0.01?

Solution 3

Since \[f'(x)=\cos x,\] we have \(f(0)=\sin0=0\) and \(f'(0)=\cos0=1\). Therefore, the linearization of \(f\) is \[\begin{aligned} L(x) & =f(0)+f'(0)(x-0)\\ & =0+1(x-0)=x.\end{aligned}\] The graphs of \(f\) and \(L\) are shown in Figure 5.

Figure 5. The graph of \(y=f(x)=\sin x\) and its linear approximation at \(x=0\).


The accuracy to within 0.01 means that the difference between \(f\) and \(L\) is less than 0.01; that is, \[|f(x)-L(x)|<0.01\] or \[|\sin x-x|<0.01.\] The graph of \(y=|\sin x-x|\) is shown in Figure 6 (the blue curve). In this figure, the vertical lines show where \(y=|\sin x-x|\) meets the horizontal line \(y=0.01\). If \(x\) is between these two vertical lines, the error (i.e. \(|\sin x-x|\)) is less than \(0.01\). The vertical lines are at \(x\approx0.39\) and \(x\approx-0.39\). Notice that here \(x\) is radian measure. So if \[-0.39\text{ rad}<x<0.39\text{ rad}\] or \[-22.4^{\circ}<x<22.4^{\circ},\] the difference between \(\sin x\) and \(x\) is less than 0.01.

Figure 6. When \(-0.39<x<0.39\), the error in the linear approximation \(\sin x\approx x\) is less than 0.01.

Is the Linear Approximation Always a Good Approximation?

Show the answer

The linear approximation is based on the assumption that the tangent line remains close to the curve \(y=f(x)\) when \(x\) is close to \(x_{0}\). If the curve has a pronounced bend at \(\left(x_{0},f(x_{0})\right)\) (for example, see Figure 7), then the linear approximation does not do a good job unless \(x\) is really close to \(x_{0}\). The bending of a curve is measured by the second derivative. We will talk about the bending of curves in the next chapter.

Figure 7. The linear approximation does not do a good job if the curve is bending sharply near \((x_{0},f(x_{0}))\) unless \(x\) is really close to \(x_{0}\).



An Application of Linearization in Physics Problems

Show the application

Linearization can simplify some equations. Here is an example:

A simple pendulum is a body of mass \(m\) on the end of a massless string suspended from a point (Figure 8). When displaced a little bit and released, the pendulum swings back and forth. Let \(\theta\) denote the angle that the string makes with the vertical. The displacement of the body from equilibrium is then \(s=L\theta\), where \(L\) is the length of the string. The force along the direction of motion is \(-mg\sin\theta\) where \(g\) is acceleration due to gravity (\(g\approx9.81\) m/s\(^{2}\) or \(g\approx32\) ft/s\(^{2}\)). It follows from Newton’s second law that \[F=ma=-mg\sin\theta\Rightarrow a=-g\sin\theta.\] Because \(a=d^{2}s/dt^{2}\) and \(s=L\theta\) we have \[\underbrace{\frac{d^{2}}{dt^{2}}(L\theta)}_{a}=-g\sin\theta\] or \[L\frac{d^{2}\theta}{dt^{2}}=-g\sin\theta.\] To describe the oscillation of the pendulum, we look for a function \(\theta=f(t)\) that satisfies the following equation: \[\underbrace{f^{\prime\prime}(t)}_{\frac{d^{2}\theta}{dt^{2}}}+\frac{g}{L}\sin(\underbrace{f(t)}_{\theta})=0.\] There is no function (among the functions that we know) that can satisfy the above equation. However, we can use the linear approximation \(\sin\theta\approx\theta\) or \(\sin(f(t))\approx f(t)\) and rewrite the equation as \[f^{\prime\prime}(t)+\frac{g}{L}f(t)=0.\] We can show that the solution of this equation is \[f(t)=\theta_{0}\cos\left(\sqrt{\frac{g}{L}}\ t\right),\] where \(\theta_{0}=f(0)\) is initial angular displacement. As long as \(\theta_{0}\) is small (about \(22.5^{\circ}\) or less as we showed in the last example), the linear approximation is valid.




Figure 8. A simple pendulum

  1. Recall that the equation of a line through \((x_{0},y_{0})\) with slope \(m\) is \(y-y_{0}=m(x-x_{0})\) or \(y=y_{0}+m(x-x_{0}).\) So because the slope of the tangent line to the curve \(y=f(x)\) at \(\left(x_{0},f(x_{0})\right)\) is \(f'(x_{0})\), its equation is \(y=f(x_{0})+f'(x_{0})(x-x_{0}).\)↩︎
  2. Notice that \(L\) is not a linear function unless \(f(x_{0})=0\). However, even if \(f(x_{0})\neq0\), we may loosely call \(L\) a linear function because its graph is a line.↩︎