Skip to main content
Mathematics LibreTexts

3.3: Local Linearity

  • Page ID
    83926
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    The last two sections examined rate of change in both the discrete and continuous case. The first application for rate of change at a point is to make projections for values of the function close to that point. We want to find the equation of a linear function that can be used to approximate our function. This is straightforward using the point-slope version of a linear equation.

    For the discrete case, given a function \(y=f(x)\text{,}\) where we know value of, \(mf(a+1)\text{,}\) the marginal change in \(f(x)\) to get to \(x=a+1\text{,}\) then our discrete linear approximation has the form:

    \[ \text{discrete linear}\, f_a (x)=f(a)+mf(a+1)*(x-a)\text{.} \nonumber \]

    clipboard_e338acbee7dbcd69c795579fd3aca9470.png

    In the differentiable case, given a function \(y=f(x)\text{,}\) where we know value of, \(f'(a)\text{,}\) the derivative of \(f(x)\) at \(x=a\text{,}\) then our linear approximation has the form:

    \[ \linear f_a (x)=f(a)+f'(a)*(x-a)\text{.} \nonumber \]

    clipboard_e16a113bf40165544829474f26d172a7a.png

    The two formulas are almost the same. The discrete case uses the slope of a secant line obtained by looking at points where the x values differ by 1. In the differentiable case we look at the slope of the tangent line. One of the reasons for looking at the linear approximation of a function is that linear functions are easy to evaluate.

    Example 3.3.1: Estimating Profit.

    The profit from selling 10,000 gizmos is $487,253. We also know that marginal profit(10001)=$45. Estimate the profit from selling 10,013 gizmos.

    Solution

    We use the formula from above:

    \[ \text{discrete linear profit}_a (x)=\profit(a)+\Mprofit(a+1)*(x-a)\text{.} \nonumber \]

    Filling in the values from the problem yields:

    \begin{align*} \text{discrete linear profit}_{10000} (x)\amp =487253+45*(x-10000)\\ \text{discrete linear profit}_{10000} (10013)\amp =487253+45*(13)=487838\text{.} \end{align*}

    Thus we estimate the profit from selling 10013 gizmos to be $487,838.

    Example 3.3.2: Estimating Square Roots.

    Figure \(3.3.3.\) Video presentation of this example

    Use information about \(f(x)=\sqrt{x}\) near \(x_0=100\) to estimate the square roots of 96 through 104. Check the accuracy of your approximations.

    Solution

    We first use Excel to find the value of the function and its derivative at 100. For the derivative we use the calculator approximation.

    clipboard_e1ff2b00d602f9a5142e991a27e412e1f.png
    clipboard_ece023e5a8c6042a28f7e11a86edf8d30.png

    Thus the linear approximation is

    \begin{align*} \linear f(x) \amp = f(100)+f'(100)(x-100)\\ \amp =10+(0.05)(x-100)\text{.} \end{align*}

    We can set up the worksheet to compute the approximation and to give us the error, both as a number and as a percentage of the correct answer.

    clipboard_eab3dc50341d59a30db34ccbe758c20cd.png
    clipboard_e8299ca72f91b90ab52df18df8261b53a.png

    It is then straightforward to compute values and check accuracy. On the given domain, the linear approximation has an error under 0.03%.

    Example 3.3.4: Estimating Reciprocals.

    Figure \(3.3.5.\) Video presentation of this example

    Use information about \(f(x)=100/x\) near \(x_0=400\) to estimate the reciprocals of the integers from of 396 through 404. Check the accuracy of your approximations.

    Solution

    Once again, we use Excel to find the value of the function and its derivative at 400. For the derivative we use the calculator approximation.

    clipboard_e44743c74ca75df0d5da6994854cc5068.png

    Thus the linear approximation is

    \begin{align*} \linear f(x) \amp = f(400)+f'(400)(x-400)\\ \amp =.25+(-0.000625)(x-400)\text{.} \end{align*}

    clipboard_ee7e4ff6d4717b380c7a7b552810dc9bc.png

    It is then straightforward to compute values and check accuracy. On the given domain, the linear approximation has an error under 0.01%.

    Example 3.3.6: Estimating Exponential Functions.

    Figure \(3.3.7.\) Video presentation of this example

    For approximating interest with continual compounding it is useful to have a linear approximation of \(f(r)=exp(r)\) when \(r\) is close to 0. Use information about \(f(r)=exp(r)\) near \(r_0=0\) to estimate the exponential function for numbers near 0. Check the accuracy of your approximations and give a domain where the approximation is good enough to use.

    Solution

    Once again, we use Excel to find the value of the function and its derivative at 0. For the derivative we use the calculator approximation.

    clipboard_e7fa60fd4397a5e6f47fd29feb3897c3f.png

    Thus the linear approximation is

    \begin{align*} \linear f(x) \amp = f(0)+f'(0)(r-0)\\ \amp = 1+(1)(r)\text{.} \end{align*}

    This is much easier to compute than the exponential function. However when we check accuracy we find that it is not very accurate for other integer values.

    clipboard_ee9cefc4ed3983ca13db3904c081f43b1.png

    That brings us back to the last part of the question, which asks for a domain where the approximation is good enough to use. The phrase “good enough to use” will depend on the setting, but we will be happy with an estimate that is within 1%. Since we are going to use this for interest rates, we are interested in positive rates.

    We modify the worksheet to allow a step size, \(\Delta x\text{,}\) to be used. Then we experiment with step sized till we get a domain where the error is under 1%.

    clipboard_e4129ecac7cecd7db355e4c54348c5500.png

    We see that \(\exp(r)\approx 1+r\) for \(0\le r\lt 0.15\text{.}\) This gives us an approximation we can use for rates of up to 15%.

    The last example illustrates that linear approximations should only be used for a limited domain. The size of the domain where the linear approximation is “good enough” will depend on the definition of “good enough” or the acceptable error in our approximation. The good domain will also depend on how far the graph is from linear, or how fast it is bending.

    class="

    Exercises: Local Linearity

    • For Exercise \(3.3.1–3.3.5\), for the given function and value for \(x_0\text{:}\)
    1. Give the formula for the discrete linear approximation.
    2. Evaluate the approximation at \(x_1\text{.}\)
    Exercise 1:

    \(x_0=10\text{,}\) \(f(10)=50\text{,}\) \(mf(11)=6\text{,}\) and \(x_1=15\text{.}\)

    Answer

    \begin{align*} f(x) \amp \approx f(10)+mf(11)*(x-10)\\ f(x) \amp \approx 50+6*(x-10)\text{.} \end{align*}

    Next we evaluate the linear approximation at 15:

    \[ f(15)\approx 50+6*(15-10)=50+30=80\text{.} \nonumber \]

    Exercise 2:

    \(x_0=15\text{,}\) \(\profit(15)=50\text{,}\) \(\Mprofit(16)=2\text{,}\) and \(x_1=6\text{.}\)

    Exercise 3:

    \(x_0=20\text{,}\) \(f(19)=191\text{,}\) \(f(20)=200\text{,}\) \(f(21)=210\text{,}\) and \(x_1=28\text{.}\)

    Answer

    \[ f(x)\approx f(20)+mf(21)*(x-20)\text{.} \nonumber \]

    Note that we have to compute \(mf(21)\text{.}\)

    \begin{align*} mf(21)\amp =f(21)-f(20)= 210-200=10\\ f(x) \amp \approx 200+10*(x-20)\text{.} \end{align*}

    Next we evaluate the linear approximation at 28:

    \[ f(28)\approx 200+10*(28-20)=200+80=280\text{.} \nonumber \]

    Exercise 4:

    \(x_0=50\text{,}\) \(\revenue(49)=1007\text{,}\) \(\revenue(50)=1000\text{,}\) \(\revenue(51)=994\text{,}\) and \(x_1=45\text{.}\)

    Exercise 5:

    \(x_0=100\text{,}\) \(cost(99)=3740\text{,}\) \(cost(100)=3743\text{,}\) \(cost(101)=3754\text{,}\) and \(x_1=112\text{.}\)

    Answer

    \[ \cost(x)\approx \cost(100)+\Mcost(101)*(x-100)\text{.} \nonumber \]

    Note that we have to compute \(\Mcost(101)\)

    \begin{gather*} \Mcost(101)=\cost(101)-\cost(100)=3754-3743=11\\ cost(x)\approx3743+11*(x-100)\text{.} \end{gather*}

    Next we evaluate the linear approximation at 112:

    \[ \cost(112)\approx 3743+11*(112-100)=3743+132=3875\text{.} \nonumber \]

    • For Exercise \(3.3.6–3.3.10\), for the given function and value for \(x_0\text{:}\)
    1. Calculate the numeric approximation of the derivative at \(x_0\text{.}\)
    2. Give the formula for the linear approximation at that point.
    3. Evaluate the approximation at \(x_1\text{.}\)
    4. Evaluate the function at \(x_1\) and compute the accuracy of the approximation.
    Exercise 6:

    \(f(x)=\ln(x)\text{,}\) \(x_0=100\text{,}\) and \(x_1=105\text{.}\)

    Exercise 7:

    \(g(x)=\sqrt{x}\text{,}\) \(x_0=81\) and \(x_1=85\text{.}\)

    Answer
    1. \[ g(x)\approx g(81)+g'(81)*(x-81)\text{.} \nonumber \]

    \[ g'(81)\approx \frac{g(81+.001)-g(81-.001)}{0.002}= \frac{\sqrt{81.001}-\sqrt{80.999}}{0.002}=.056\text{.} \nonumber \]


    This page titled 3.3: Local Linearity is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Mike May, S.J. & Anneke Bart via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.