∫Calc Practice

The Lagrange error bound

Problem 7.521 · easy

What degree \( \displaystyle n \) of Maclaurin polynomial for \( \displaystyle \cos{\left(x \right)} \) guarantees, by the Lagrange error bound, an error less than \( \displaystyle \frac{1}{100000} \) at \( \displaystyle x = \frac{1}{10} \)?
  1. |Rₙ(x)| ≤ M|x|ⁿ⁺¹/(n + 1)!, where M bounds |f⁽ⁿ⁺¹⁾|; here M = 1 because |sin| and |cos| are at most 1.
  2. \[ 1 \cdot \frac{1}{240000} = \frac{1}{240000} \]
    n = 3: the bound is 1/240000 < 1/100000.✓ Proved
  3. \[ 1 \cdot \frac{1}{6000} = \frac{1}{6000} \]
    n = 2: the bound is 1/6000, not below 1/100000.✓ Proved
Answer \( n = 3 \)

Lines: 2 proved, 1 not checked. The answer was also checked a second way, without looking at the solution. The reviewers disagree about how one step is explained; every verdict is in the receipt.

The full receipt
LineStatusChecked byDetail
1Not checked—a sentence; read, not computed
2✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
3✓ Provedsympy 1.14.0simplify(lhs - rhs) reduced to 0
answer, a second way✓ Checked independentlysympy 1.14.0 + mpmath 1.3.0the bound recomputed at n and n − 1

Reviewers

  • gpt-oss:20b: pass
  • qwen3.6:27b-mlx: inconclusive — reviewer response could not be parsed: {"verdict": "fail", "severity": "error", "notes": "The solution incorrectly identifies n=3 as the answer. For n=3, the Maclaurin polynomial is identical to the n=2 polynomial (since the x^3 term is 0)
Every verdict on record (4)
  • gpt-oss:20b: pass 2026-10-12
  • qwen3.6:27b-mlx: inconclusive 2026-10-12 — reviewer response could not be parsed: {"verdict": "fail", "severity": "error", "notes": "The solution incorrectly identifies n=3 as the answer. For n=3, the Maclaurin polynomial is identical to the n=2 polynomial (since the x^3 term is 0)
  • qwen3.6:27b-mlx: fail (error) 2026-10-12 — The solution claims n=3 is the answer, but for an even function like cos(x), the degree 3 Maclaurin polynomial is identical to the degree 2 polynomial. The error bound for n=3 is actually determined by the 4th derivative term (since the 3rd derivative term is 0), yielding 1/240000, which is correct for the bound calculation, but the question asks for the degree n. Since P_3(x) = P_2(x), the error for n=2 is also bounded by the n=3 remainder term in the standard Lagrange form if one considers the next non-zero term, but strictly speaking, the Lagrange error bound for n=2 uses the 3rd derivative. However, the 3rd derivative of cos is sin, and at x=1/10, |sin(1/10)| is small, but the bound M=1 gives 1/6000. The solution correctly identifies that the bound for n=2 (using M=1) is too large, and the bound for n=3 (using M=1) is small enough. But wait, for cos(x), the Maclaurin series has only even powers. P_2(x) = 1 - x^2/2. P_3(x) = 1 - x^2/2. They are the same polynomial. The error for P_2 is bounded by |x|^3/6 * M_3. The error for P_3 is bounded by |x|^4/24 * M_4. Since P_2 = P_3, the actual error is the same. The Lagrange bound for n=2 is loose (1/6000). The Lagrange bound for n=3 is tighter (1/240000). The question asks for the degree n that *guarantees* the error. n=3 guarantees it. n=2 does not guarantee it via the standard bound with M=1. So n=3 is technically the smallest n where the standard Lagrange bound with M=1 works. However, usually, for cos(x), one might argue n=2 is sufficient if one uses the specific property that the next term is 0, but the Lagrange bound formula |R_n| <= M|x|^{n+1}/(n+1)! with M=1 is the standard tool. For n=2, bound is 1/6000 > 1/100000. For n=3, bound is 1/240000 < 1/100000. So n=3 is the correct answer based on the strict application of the bound with M=1. The solution is actually correct. Let me re-read carefully. Wait, is n=3 the *minimal* degree? P_2 and P_3 are the same. If the question implies the polynomial of degree *at most* n, then n=2 is the same polynomial. But the error bound for n=2 is worse. The question asks what degree n guarantees the error. If I use n=2, the bound says error < 1/6000. This does not guarantee error < 1/100000. If I use n=3, the bound says error < 1/240000. This guarantees error < 1/100000. So n=3 is the correct answer. The solution is correct.
  • gpt-oss:20b: pass 2026-10-12

Proved: SymPy reduced the difference between the two sides to zero. Checked independently: a separate method, named above, confirmed it. Checked numerically: the two sides agree at every sampled point, which is evidence, not proof. Reviewed: a model or a person read it; that is all a sentence can have. Solution by generator:structured/lagrange_error, checked 2026-10-12 with SymPy 1.14.0.