Tutorials › Calculus II › Choosing A Taylor Center To Reduce Error

Remainders and Error Estimates · Tutorial 862 of 998

Choosing A Taylor Center To Reduce Error

Compare the Lagrange factors for different Taylor centers and use them to choose an expansion center and degree that guarantee a specified accuracy.

Advanced 10 min read

What You'll Learn

  • Identify the interval on which the Lagrange derivative bound must hold for each candidate center.
  • Compare centers using the product of a valid derivative bound and the distance-to-center factor.
  • Recognize when a closer center does not automatically guarantee a smaller error bound.
  • Choose a Taylor degree that meets a prescribed error tolerance.
  • Check that the derivative bound, interval, and arithmetic support the claimed error guarantee.

Why the Taylor Center Matters

A Taylor polynomial approximates a function near a chosen center. When the target point is fixed, changing that center changes two parts of the Lagrange error bound: the distance from the center to the target, and the largest relevant derivative value on the interval between them. A useful center is therefore not determined by distance alone.

This choice matters in practical approximation. If a required tolerance is prescribed, one can compare candidate centers, calculate the resulting error bounds, and select a center and degree that certify the requested accuracy. The goal is not to guess which polynomial looks best, but to use a valid bound to justify a choice.

The Center-Dependent Lagrange Bound

For a function \(f\), a Taylor polynomial of degree \(n\) centered at \(a\) is

$$ T_{n,a}(x)=\sum_{k=0}^{n}\frac{f^{(k)}(a)}{k!}(x-a)^k. $$

Here \(f^{(0)}=f\), and \(n\) is a nonnegative integer. The approximation error at a target \(x\) is \(R_{n,a}(x)=f(x)-T_{n,a}(x)\).

Theorem: Suppose \(f\) has continuous derivatives through order \(n+1\) on the closed interval joining \(a\) and \(x\), and is defined on an open interval containing it. If \(M_a\) is any number satisfying \(\lvert f^{(n+1)}(t)\rvert\le M_a\) throughout that interval, then $$ \lvert R_{n,a}(x)\rvert\le \frac{M_a\lvert x-a\rvert^{n+1}}{(n+1)!}. $$

Both the derivative bound and the distance factor depend on the chosen center. The subscript in \(M_a\) emphasizes that a different center can require a different interval and hence a different derivative bound. A valid \(M_a\) need not be the smallest possible bound; it only needs to bound the derivative everywhere on the interval between \(a\) and \(x\).

For a fixed degree \(n\), the factorial \((n+1)!\) is the same for every candidate center. Thus, when comparing centers at the same target and degree, compare the products \(M_a\lvert x-a\rvert^{n+1}\). A smaller product gives a smaller Lagrange guarantee. This does not prove that the actual error is smaller, only that the stated upper bound is smaller.

How to Compare Candidate Centers

1
Fix the target and degree.
The target \(x\) is the point to approximate, and \(n\) is the Taylor degree being compared.
2
Find the required interval for each center.
For a candidate \(a\), use the closed interval with endpoints \(a\) and \(x\).
3
Bound the next derivative on that interval.
Find a valid \(M_a\) for \(\lvert f^{(n+1)}\rvert\); do not use only its value at the center unless it bounds the derivative on the whole interval.
4
Calculate and compare the bounds.
Evaluate \(M_a\lvert x-a\rvert^{n+1}/(n+1)!\) for each candidate.
5
Check the tolerance.
A bound no greater than the requested tolerance certifies that the approximation error meets that tolerance.

This procedure follows directly from the theorem: each valid choice of \(M_a\) and interval produces an upper bound on the same error at the target. Comparing the resulting products is justified because the denominator is common when the degree is fixed. If the degree changes as well, compare the complete bounds, including their factorials.

Worked Example: Moving the Center for an Exponential

Worked Example: Comparing Two Centers for \(e^x\)

Approximate \(e^1\) with a degree-two Taylor polynomial, comparing centers \(a=0\) and \(a=\frac12\).

First use \(a=0\). Since every derivative of \(e^x\) is \(e^x\), the Taylor polynomial is

$$T_{2,0}(x)=1+x+\frac{x^2}{2}.$$

At \(x=1\), \(T_{2,0}(1)=1+1+\frac12=\frac52\). On \([0,1]\), the third derivative satisfies \(e^t\le e\), so \(M_0=e\) is valid. The bound is

$$\lvert R_{2,0}(1)\rvert\le\frac{e\lvert1-0\rvert^3}{3!}=\frac{e}{6}\approx0.45305.$$

Now use \(a=\frac12\). The value of each derivative at the center is \(e^{1/2}\), so

$$T_{2,1/2}(x)=e^{1/2}\left(1+(x-\tfrac12)+\frac{(x-\tfrac12)^2}{2}\right).$$

At \(x=1\), the displacement is \(\frac12\), and therefore

$$T_{2,1/2}(1)=e^{1/2}\left(1+\frac12+\frac18\right)=\frac{13e^{1/2}}{8}\approx2.67917.$$

On \([\frac12,1]\), \(e^t\le e\), so \(M_{1/2}=e\) is valid. Hence

$$\lvert R_{2,1/2}(1)\rvert\le\frac{e(\frac12)^3}{3!}=\frac{e}{48}\approx0.05663.$$

For a numerical check, \(e\approx2.71828\). The two polynomial values are \(2.5\) and approximately \(2.67917\), giving actual errors of about \(0.21828\) and \(0.03911\), respectively. Each is below its corresponding Lagrange bound. The shifted center gives a much smaller bound because the derivative bound is unchanged while the distance factor falls from \(1^3\) to \((\frac12)^3\).

Worked Example: The Derivative Bound Can Also Change

Worked Example: Comparing Centers for \(\ln x\)

Approximate \(\ln 2\) with degree-two Taylor polynomials centered at \(1\) and \(\frac32\). The relevant derivative is \(f'''(t)=2/t^3\), which decreases for \(t>0\).

At \(a=1\), the Taylor polynomial is \(T_{2,1}(x)=(x-1)-\frac12(x-1)^2\), since \(\ln 1=0\), \(f'(1)=1\), and \(f''(1)=-1\). Thus \(T_{2,1}(2)=1-\frac12=\frac12\). On \([1,2]\), \(2/t^3\le2\), so \(M_1=2\). The error bound is

$$\lvert R_{2,1}(2)\rvert\le\frac{2\cdot1^3}{6}=\frac13\approx0.33333.$$

At \(a=\frac32\), the derivatives at the center are \(f'(a)=\frac23\) and \(f''(a)=-\frac49\). The polynomial is

$$T_{2,3/2}(x)=\ln\left(\frac32\right)+\frac23(x-\tfrac32)-\frac29(x-\tfrac32)^2.$$

At \(x=2\), this gives \(T_{2,3/2}(2)=\ln(\frac32)+\frac13-\frac1{18}=\ln(\frac32)+\frac5{18}\). On \([\frac32,2]\), the decreasing function \(2/t^3\) has maximum \(2/(\frac32)^3=\frac{16}{27}\). Thus \(M_{3/2}=\frac{16}{27}\), and

$$\lvert R_{2,3/2}(2)\rvert\le \frac{(\frac{16}{27})(\frac12)^3}{6} =\frac{16}{27\cdot8\cdot6} =\frac{1}{81} \approx0.01235.$$

To check the approximations numerically, \(\ln 2\approx0.69315\) and \(\ln(\frac32)+\frac5{18}\approx0.68324\). Their errors are approximately \(0.19315\) and \(0.00990\), respectively, both below their calculated bounds. The nearer center reduces the distance factor, and its derivative maximum is also lower because its interval stays farther from zero.

Worked Example: Choosing a Center and Degree for a Tolerance

Worked Example: Certifying an Error Below \(0.001\)

Approximate \(f(x)=1/(1-x)\) at \(x=\frac25\). Compare centers \(0\) and \(\frac15\), and find a degree that guarantees an error no greater than \(0.001\).

For every nonnegative integer \(k\), \(f^{(k)}(x)=k!/(1-x)^{k+1}\). Therefore, for degree \(n\), the derivative of order \(n+1\) is \((n+1)!/(1-x)^{n+2}\). On either interval considered below, this derivative is positive and increases with \(x\), so its maximum occurs at \(x=\frac25\). Its value there is \((n+1)!/(\frac35)^{n+2}\).

With center \(a=0\), the distance to the target is \(\frac25\). The Lagrange bound simplifies to

$$B_0(n)=\frac{(n+1)!}{(\frac35)^{n+2}}\frac{(\frac25)^{n+1}}{(n+1)!} =\frac53\left(\frac23\right)^{n+1}.$$

For \(n=6\), \(B_0(6)=\frac53(\frac23)^7=\frac{640}{6561}\approx0.09755\), which is greater than \(0.001\). Thus degree six at center zero does not meet the specified guarantee.

With center \(a=\frac15\), the distance is \(\frac15\), and the bound becomes

$$B_{1/5}(n)=\frac{(n+1)!}{(\frac35)^{n+2}}\frac{(\frac15)^{n+1}}{(n+1)!} =\frac53\left(\frac13\right)^{n+1}.$$

At \(n=5\), this is \(\frac53(\frac13)^6=\frac5{2187}\approx0.00229\), which exceeds \(0.001\). At \(n=6\), it is \(\frac53(\frac13)^7=\frac5{6561}\approx0.000762\), which is below \(0.001\). So degree six at center \(\frac15\) certifies the requested tolerance; degree five at that center does not.

The polynomial can also be checked explicitly. Writing \(h=x-\frac15\), one has \(f(x)=\frac54\cdot\frac{1}{1-\frac54h}\). Its degree-six Taylor polynomial at the target \(x=\frac25\), where \(h=\frac15\), evaluates to

$$T_{6,1/5}(\tfrac25)=\frac54\sum_{k=0}^{6}\left(\frac14\right)^k =\frac53\left(1-\frac{1}{16384}\right) =\frac{27305}{16384}.$$

The exact function value is \(f(\frac25)=\frac53\). Subtracting the polynomial value gives an actual error of \(\frac5{49152}\approx0.000102\), which is below the Lagrange bound \(\frac5{6561}\approx0.000762\), and below \(0.001\). This check agrees with the guarantee.

A Common Mistake: Using the Derivative at the Center

A derivative evaluated at the center is not automatically a bound for the derivative throughout the interval. For example, in the exponential example with center \(\frac12\) and target \(1\), using \(e^{1/2}\) as the third-derivative bound would give the incorrect estimate \(e^{1/2}/48\approx0.03435\). But \(e^t\) increases on \([\frac12,1]\), so the valid maximum is \(e\), not \(e^{1/2}\). The correct bound is \(e/48\approx0.05663\). Indeed, the actual error is about \(0.03911\), larger than the incorrect estimate. Always bound the derivative over the entire interval joining the center and target.

Using the Bound to Make a Choice

For a fixed degree, a smaller distance often helps substantially because it is raised to the power \(n+1\). However, moving the center can also change the derivative bound, sometimes increasing it. The comparison must use the full product, not distance alone. A candidate center is useful only if the Taylor polynomial is defined and the hypotheses for the Lagrange bound hold on the required interval.

For a prescribed tolerance \(\varepsilon>0\), the decision rule is direct: choose a center \(a\), a degree \(n\), and a valid derivative bound \(M_a\) such that

$$ \frac{M_a\lvert x-a\rvert^{n+1}}{(n+1)!}\le\varepsilon. $$

Then the theorem guarantees \(\lvert f(x)-T_{n,a}(x)\rvert\le\varepsilon\). When the first trial fails, one can test another center, increase the degree, or do both, recalculating the complete bound each time. The guarantee concerns the actual error at the target; it does not claim that the bound is the exact error.

Check Your Understanding

Use the Lagrange-bound framework to answer these questions.

  1. For a fixed Taylor degree and target, which two center-dependent quantities determine the Lagrange error bound?
  2. Why must a derivative bound \(M_a\) hold throughout the interval between the center and the target?
  3. If two centers give the same valid derivative bound but one has half the distance to the target, what is the ratio of their distance factors for degree \(n\)?
  4. What inequality must a calculated Lagrange bound satisfy to certify a prescribed tolerance \(\varepsilon\)?
  5. Does a smaller Lagrange bound prove that the actual approximation error is smaller? Explain the distinction.