Dove's LibraryDove's Library

10.12 - Lagrange Error Bound

Introduction to Error Bounds

Last lesson we learned about Taylor polynomials, which are polynomial approximations of functions. Now we need to answer a follow-up question: how accurate is that approximation?
The Lagrange error bound tells us the maximum possible error when you use a Taylor polynomial to approximate a function.

Exact Value vs. Approximation

For any function f(x)f(x) and its Taylor polynomial approximation Pn(x)P_n(x):
f(x)=Pn(x)+Rn(x)f(x) = P_n(x) + R_n(x)
where: - f(x)f(x) = the exact value - Pn(x)P_n(x) = the Taylor polynomial approximation, of degree nn - Rn(x)R_n(x) = the remainder, which is the error
Rearranging to find the remainder:
Rn(x)=f(x)−Pn(x)R_n(x) = f(x) - P_n(x)
The error is the absolute value of the remainder:
Error=∣Rn(x)∣=∣f(x)−Pn(x)∣\text{Error} = |R_n(x)| = |f(x) - P_n(x)|

The Lagrange Error Bound Formula

The Lagrange error bound, also called Taylor’s Remainder Theorem, says:
∣Rn(x)∣≤M⋅∣x−c∣n+1(n+1)!\boxed{|R_n(x)| \leq \frac{M \cdot |x-c|^{n+1}}{(n+1)!}}
where: - nn = the degree of the Taylor polynomial - cc = the center of the Taylor polynomial - xx = the point where we’re approximating - MM = the maximum value of ∣f(n+1)(z)∣|f^{(n+1)}(z)| for zz between cc and xx
Full formula with the derivative written out:
∣Rn(x)∣≤max⁡z∈[c,x]∣f(n+1)(z)∣⋅∣x−c∣n+1(n+1)!|R_n(x)| \leq \frac{\max_{z \in [c,x]} |f^{(n+1)}(z)| \cdot |x-c|^{n+1}}{(n+1)!}
Key idea: the error is bounded by the next term in the Taylor series, using the maximum value of the (n+1)th(n+1)^{\text{th}} derivative on the interval.

Understanding the Variable zz

What is zz?
zz is some unknown value between cc, the center, and xx, the point of approximation:
c<z<xorx<z<cc < z < x \quad \text{or} \quad x < z < c
Why zz instead of cc?
We don’t know the exact point where the derivative hits its maximum, so we look across the entire interval and take the largest value.
Important: we find max⁡∣f(n+1)(z)∣\max |f^{(n+1)}(z)| over the interval [c,x][c, x], or [x,c][x, c] if x<cx < c.

Step-by-Step Strategy

To find the Lagrange error bound:
  1. Identify the degree nn of the Taylor polynomial
  1. Find the (n+1)th(n+1)^{\text{th}} derivative of f(x)f(x)
  1. Determine the interval for zz, which is between cc and xx
  1. Find the maximum of ∣f(n+1)(z)∣|f^{(n+1)}(z)| on that interval
  1. Calculate M⋅∣x−c∣n+1(n+1)!\frac{M \cdot |x-c|^{n+1}}{(n+1)!}
  1. Interpret. That’s the maximum possible error

Example 1: Fourth-Degree Maclaurin Polynomial for Cosine

Use the fourth-degree Maclaurin polynomial P4(x)=1−x22!+x44!P_4(x) = 1 - \frac{x^2}{2!} + \frac{x^4}{4!} to approximate cos⁡(0.2)\cos(0.2), then find the Lagrange error bound.
Step 1: Identify the given information
  • Function: f(x)=cos⁡(x)f(x) = \cos(x)
  • Degree: n=4n = 4
  • Center: c=0c = 0, since it’s a Maclaurin polynomial
  • Approximating at: x=0.2x = 0.2
Step 2: Find the approximation (not needed for the error bound, but useful)
P4(0.2)=1−(0.2)22+(0.2)424≈0.980067P_4(0.2) = 1 - \frac{(0.2)^2}{2} + \frac{(0.2)^4}{24} \approx 0.980067
Step 3: Find the (n+1)th(n+1)^{\text{th}} derivative
We need the 5th5^{\text{th}} derivative:
f(x)=cos⁡(x)f(x) = \cos(x)f′(x)=−sin⁡(x)f'(x) = -\sin(x)f′′(x)=−cos⁡(x)f''(x) = -\cos(x)f′′′(x)=sin⁡(x)f'''(x) = \sin(x)f(4)(x)=cos⁡(x)f^{(4)}(x) = \cos(x)f(5)(x)=−sin⁡(x)f^{(5)}(x) = -\sin(x)
Step 4: Determine the interval for zz
0<z<0.20 < z < 0.2
Step 5: Find the maximum of ∣f(5)(z)∣=∣−sin⁡(z)∣=∣sin⁡(z)∣|f^{(5)}(z)| = |-\sin(z)| = |\sin(z)|
Key shortcut for sine and cosine: since ∣sin⁡(z)∣≤1|\sin(z)| \leq 1 for all zz:
M=1M = 1
We use M=1M = 1 as an upper bound, even though sin⁡(0.2)\sin(0.2) is actually much less than 1.
MM doesn’t have to be the exact maximum. Any number that is at least as big as ∣f(n+1)(z)∣|f^{(n+1)}(z)| everywhere between cc and xx works. A bigger MM only makes the bound a little looser, and the bound is still true.
Step 6: Calculate the error bound
∣R4(0.2)∣≤1⋅∣0.2−0∣55!=(0.2)5120=0.00032120=2.667×10−6≈0.0000027|R_4(0.2)| \leq \frac{1 \cdot |0.2 - 0|^5}{5!} = \frac{(0.2)^5}{120} = \frac{0.00032}{120} = 2.667 \times 10^{-6} \approx 0.0000027
Interpretation:
The approximation P4(0.2)≈0.980067P_4(0.2) \approx 0.980067 is accurate to within 0.00000270.0000027. In other words, the actual value of cos⁡(0.2)\cos(0.2) differs from our approximation by at most 2.667×10−62.667 \times 10^{-6}.
Accuracy: you’d have to go out six decimal places before the digit might be off by 2 or 3 units. That’s an excellent approximation.

Example 2: Third-Degree Maclaurin for the Exponential

Use the third-degree Maclaurin polynomial to approximate e1e^1, then find the Lagrange error bound.
Step 1: Find the Taylor polynomial for f(x)=exf(x) = e^x centered at c=0c = 0
Since f(k)(x)=exf^{(k)}(x) = e^x for every kk, and f(k)(0)=e0=1f^{(k)}(0) = e^0 = 1:
P3(x)=1+x+x22!+x33!P_3(x) = 1 + x + \frac{x^2}{2!} + \frac{x^3}{3!}
Step 2: Calculate the approximation at x=1x = 1
P3(1)=1+1+12+16=1+1+0.5+0.1667≈2.667P_3(1) = 1 + 1 + \frac{1}{2} + \frac{1}{6} = 1 + 1 + 0.5 + 0.1667 \approx 2.667
Step 3: Find the (n+1)th=4th(n+1)^{\text{th}} = 4^{\text{th}} derivative
f(4)(x)=exf^{(4)}(x) = e^x
Step 4: Determine the interval for zz
0<z<10 < z < 1
Step 5: Find the maximum of ∣f(4)(z)∣=ez|f^{(4)}(z)| = e^z
Since eze^z is increasing, the maximum happens at z=1z = 1:
M=e1=e≈2.71828M = e^1 = e \approx 2.71828
Step 6: Calculate the error bound
∣R3(1)∣≤e⋅∣1−0∣44!=e⋅124≈2.7182824≈0.1133|R_3(1)| \leq \frac{e \cdot |1-0|^4}{4!} = \frac{e \cdot 1}{24} \approx \frac{2.71828}{24} \approx 0.1133
Verification:
Actual error: ∣e−83∣≈∣2.71828−2.66667∣≈0.0516\left|e - \frac{8}{3}\right| \approx |2.71828 - 2.66667| \approx 0.0516
And sure enough, 0.0516<0.11330.0516 < 0.1133 ✓
The actual error is less than the error bound, exactly as it should be.

Example 3: Finding the Minimum Degree for Required Accuracy

What is the smallest degree nn for a Taylor polynomial of f(x)=ex−1f(x) = e^{x-1} centered at c=1c = 1 so that the error in approximating f(3)f(3) is less than 11?
Step 1: Set up the error bound inequality
M⋅∣3−1∣n+1(n+1)!<1\frac{M \cdot |3-1|^{n+1}}{(n+1)!} < 1
Step 2: Find the (n+1)th(n+1)^{\text{th}} derivative
For f(x)=ex−1f(x) = e^{x-1}, every derivative is the same:
f(k)(x)=ex−1 for all k⇒f(n+1)(x)=ex−1f^{(k)}(x) = e^{x-1} \text{ for all } k \quad \Rightarrow \quad f^{(n+1)}(x) = e^{x-1}
Step 3: Determine the interval and find the maximum
Interval: 1<z<31 < z < 3. The maximum happens at z=3z = 3:
M=e3−1=e2M = e^{3-1} = e^2
Step 4: Set up the inequality
e2⋅∣3−1∣n+1(n+1)!<1⇒e2⋅2n+1(n+1)!<1\frac{e^2 \cdot |3-1|^{n+1}}{(n+1)!} < 1 \quad \Rightarrow \quad \frac{e^2 \cdot 2^{n+1}}{(n+1)!} < 1
Step 5: Use a calculator to test values
nn
e2⋅2n+1(n+1)!\frac{e^2 \cdot 2^{n+1}}{(n+1)!}
Less than 1?
1
e2⋅42≈14.778\frac{e^2 \cdot 4}{2} \approx 14.778
✗
2
e2⋅86≈9.852\frac{e^2 \cdot 8}{6} \approx 9.852
✗
3
e2⋅1624≈4.926\frac{e^2 \cdot 16}{24} \approx 4.926
✗
4
e2⋅32120≈1.970\frac{e^2 \cdot 32}{120} \approx 1.970
✗
5
e2⋅64720≈0.657\frac{e^2 \cdot 64}{720} \approx 0.657
✓
Answer: the minimum degree is n=5n = 5, a fifth-order Taylor polynomial.

Special Shortcut: Sine and Cosine Functions

For anything involving sin⁡(x)\sin(x) or cos⁡(x)\cos(x), all the derivatives are ±sin⁡(x)\pm\sin(x) or ±cos⁡(x)\pm\cos(x).
Since ∣sin⁡(z)∣≤1|\sin(z)| \leq 1 and ∣cos⁡(z)∣≤1|\cos(z)| \leq 1 for every zz:
M=1M = 1
You can always use M=1M = 1 for sine and cosine derivatives, which simplifies things enormously.
Examples: - If f(n+1)(z)=sin⁡(z)f^{(n+1)}(z) = \sin(z), then M=1M = 1 - If f(n+1)(z)=−cos⁡(z)f^{(n+1)}(z) = -\cos(z), then M=1M = 1 - If f(n+1)(z)=3sin⁡(z)−2cos⁡(z)f^{(n+1)}(z) = 3\sin(z) - 2\cos(z), then M=5M = 5, by the triangle inequality

Calculator Tips for Testing Multiple Values

When you’re finding the minimum degree nn for a required error:
Method 1: Using the table feature
  1. Enter the formula in Y1: Y1 = M*(X-C)^(N+1)/((N+1)!)
  1. Replace the variables with the values you know
  1. View the TABLE with 2nd → GRAPH
  1. Scroll to find where the value drops below your threshold
Method 2: Using the list feature
  1. Store the values in lists
  1. Calculate the error for each nn value
  1. Identify the first value that meets the criterion
Note: nn has to be a whole number, since it’s the degree of a polynomial. So don’t solve algebraically for decimal values.

Common Patterns and Shortcuts

Exponential Functions

For f(x)=ekxf(x) = e^{kx}, all the derivatives are f(n)(x)=knekxf^{(n)}(x) = k^n e^{kx}.
The maximum on [a,b][a, b] happens at whichever endpoint makes ekxe^{kx} largest.

Polynomials

Taylor polynomials of degree nn for polynomials of degree ≤n\leq n are exact.
Error bound: Rn(x)=0R_n(x) = 0, meaning no error at all.

Logarithmic Functions

For f(x)=ln⁡(x)f(x) = \ln(x):
f(n)(x)=(−1)n+1(n−1)!xnf^{(n)}(x) = \frac{(-1)^{n+1}(n-1)!}{x^n}
The maximum depends on the interval and on the sign of (−1)n+1(-1)^{n+1}.

Important Notes

Why Use the Maximum?

The (n+1)th(n+1)^{\text{th}} derivative varies across the interval [c,x][c, x]. To guarantee our error bound holds for any point in that interval, we use the maximum value.

Actual Error vs. Error Bound

Actual Error≤Error Bound\text{Actual Error} \leq \text{Error Bound}
The error bound is usually an overestimate, so the actual error tends to be smaller.

Increasing Accuracy

To reduce the error:
  1. Increase the degree nn, meaning use more terms
  1. Approximate closer to the center, meaning a smaller ∣x−c∣|x-c|
  1. Choose a better center, one where the derivatives are smaller

Free Response vs. Multiple Choice

Free response: often just asks you to set up the error bound formula, not compute it all the way out.
Multiple choice: usually wants a numerical answer.

Visual Understanding of the Error Bound

10.12 - Lagrange Error Bound
Key insight: the error is smallest near the center cc and grows as you move away from it.

Relationship to the Alternating Series Error Bound

For alternating series, which we covered earlier, the error bound is the magnitude of the next term.
For general Taylor polynomials (Lagrange), the error bound is the magnitude of the next term evaluated at the maximum over the interval.
Both use the same underlying principle: the next term bounds the error.

Using the Alternating Series Error Bound for a Taylor Polynomial

Sometimes you can skip Lagrange. If the Taylor series, with your xx value plugged in, is an alternating series whose terms keep getting smaller and approach 0 (the AST conditions from 10.7), then the error of the Taylor polynomial is at most the size of the first term you left out.
Example 4: Bound the error of P4(0.2)P_4(0.2) for cos⁡(0.2)\cos(0.2) from Example 1, this time with the alternating series error bound.
Step 1: Put x=0.2x = 0.2 into the cosine series
cos⁡(0.2)=1−(0.2)22!+(0.2)44!−(0.2)66!+⋯\cos(0.2) = 1 - \frac{(0.2)^2}{2!} + \frac{(0.2)^4}{4!} - \frac{(0.2)^6}{6!} + \cdots
Step 2: Check the conditions. The signs alternate, each term is smaller than the one before it, and the terms approach 0.
Step 3: Find the first term left out. P4(0.2)P_4(0.2) stops at the (0.2)4(0.2)^4 term, so the next term is the (0.2)6(0.2)^6 term:
∣R4(0.2)∣≤(0.2)66!=0.000064720≈8.9×10−8|R_4(0.2)| \leq \frac{(0.2)^6}{6!} = \frac{0.000064}{720} \approx 8.9 \times 10^{-8}
That’s much smaller than the Lagrange bound of 2.667×10−62.667 \times 10^{-6} from Example 1. Both bounds are correct. The cosine series has no x5x^5 term, so the first term left out is the x6x^6 term, which is tiny. Use whichever bound the question asks for.
When it doesn’t apply: for exe^x at x=1x = 1 (Example 2), every term of 1+1+12!+13!+⋯1 + 1 + \frac{1}{2!} + \frac{1}{3!} + \cdots is positive, so the series isn’t alternating. Use the Lagrange error bound there.

Summary Table

Component
Meaning
How to Find It
nn
Degree of the polynomial
Given in the problem
cc
Center
Given (Maclaurin means c=0c=0)
xx
Point of approximation
Given in the problem
f(n+1)(z)f^{(n+1)}(z)
The next derivative
Calculate the derivatives
MM
Maximum of ∥f(n+1)(z)∥\|f^{(n+1)}(z)\|
Evaluate on [c,x][c,x] and take the max
∥x−c∥n+1\|x-c\|^{n+1}
Distance to a power
Simple calculation
(n+1)!(n+1)!
Factorial
Calculate it, or use a calculator

Key Takeaways

  • Lagrange error bound: ∣Rn(x)∣≤M⋅∣x−c∣n+1(n+1)!|R_n(x)| \leq \frac{M \cdot |x-c|^{n+1}}{(n+1)!}
  • MM is the maximum of ∣f(n+1)(z)∣|f^{(n+1)}(z)| on the interval between cc and xx
  • zz is unknown, somewhere between the center and the approximation point
  • Sine and cosine shortcut: always use M=1M = 1 for sin⁡\sin or cos⁡\cos derivatives
  • The error bound is the maximum possible error. The actual error is usually smaller
  • Higher degree means smaller error. More terms give a better approximation
  • Closer to the center means smaller error, since the ∣x−c∣|x-c| term shrinks
  • Factorials grow fast. The (n+1)!(n+1)! in the denominator cuts the error down significantly
  • Use a calculator to test multiple nn values when you’re finding the minimum degree
  • Actual error ≤\leq error bound. The bound is typically an overestimate
  • The formula is not given on the AP exam. There’s no formula sheet for AP Calculus, so memorize it and focus on applying it
  • Common problem type: finding the minimum nn for a required accuracy

AP® is a registered trademark of the College Board, which is not affiliated with Dove's Library and was not involved in the production of, and does not endorse, this website.

Providing free, high-quality AP notes to help students succeed, earn college credit, and reach their educational goals, ensuring everyone has access to the resources they need.

© 2026 Standard Learning Group, Inc., which operates Dove's Library. All rights reserved.