Taylor Polynomials and the Remainder | Free Calculus 2 Lesson (4 College Credits) | UPI Study

UPI Study › Courses › Calculus 2 › Free lessons › Lesson 8.4 Free lesson

Taylor Polynomials and the Remainder

Calculus 2 · Chapter 8: Power Series & Taylor SeriesSection 8.4 · lesson 42 of 5411 min · free

← Taylor and Maclaurin SeriesNext lesson: Manipulating Taylor Series →

Earn 4 college credits for Calculus 2Recommended for credit by NCCRS · Math 265 · self-paced · one payment, lifetime access

In this lesson

How wrong is a truncated series?.

  • Truncate a Taylor series to degree n
  • Name the error and read the Lagrange form
  • Bound it with Taylor's Inequality, without knowing f
  • Solve backwards for the degree a tolerance demands

Transcript

Everything said in the video, section by section (1,667 words). Read along, or search it.

MAT-265 - Calculus 2 · Section 8.4

Taylor Polynomials and the Remainder

A Taylor series has infinitely many terms. But no machine can add infinitely many numbers. So in practice you keep finitely many, and accept an error. Which raises the question this entire section answers. How wrong is the answer you get? And more usefully — how many terms do you need to guarantee a given accuracy? That second question is the one engineers actually ask. And Taylor's Inequality answers it.

The Object

A Truncated Series Is a Polynomial

Keeping the terms up to degree n produces the degree-n Taylor polynomial. P sub n of x is the sum, from k equals zero to n, of the kth derivative of f at a, over k factorial, times x minus a to the k. It's just the Taylor series, truncated. And here's the defining property. P sub n matches f, and its first n derivatives, exactly at the center a. Which is why the agreement is best there, and degrades as you move away. Look at the picture. Cosine x, with its Maclaurin polynomials of degree two, four, six and eight. Every polynomial passes through the point zero comma one. And every one hugs the curve near the center. P two, the parabola, tracks cosine only near the origin before falling away. P four follows it further. P six further still. And P eight tracks the curve well past pi. So each increase in degree extends the region of close agreement outward. But notice — each one eventually peels away from the cosine, once absolute x grows large enough. Higher degree buys you more range. It doesn't buy you all of it.

The Remainder

Name the Error, Then Bound It

To control that degradation, we give the discrepancy a name, and treat it as an object in its own right. The remainder — or error term — of the degree-n Taylor polynomial is R sub n of x equals f of x, minus P sub n of x. So f of x equals P sub n of x, plus R sub n of x. Exactly. For every x. And the Taylor series converges to f of x precisely when R sub n of x goes to zero as n goes to infinity. That's the missing piece from the last section — the condition under which a Taylor series actually equals the function it came from. Now, as written, that definition is honest but completely useless for computation. Because finding R sub n requires knowing f of x. Which is the unknown. So we need something better. And here it is. Theorem eight point four. The Lagrange form of the remainder. If f has n plus one continuous derivatives on an interval containing a and x, then there exists a number c, strictly between a and x, such that R sub n of x equals the n plus first derivative of f at c, over n plus one factorial, times x minus a to the n plus one. Now, the theorem guarantees such a c exists. But it gives no way to locate it. And that limitation is precisely what the next result works around.

Figure 8.4.2

The Error Is a Vertical Gap

Before the workaround, look at what the remainder actually is, geometrically. Here's e to the x, with its degree-two Maclaurin polynomial, one plus x plus x squared over two. The remainder R two of x is simply the vertical distance between the two curves. At the center, x equals zero, the gap closes to zero. The polynomial and the function agree exactly there. And as x moves right, the gap widens. That widening matches the factor x minus a, to the n plus one, in the Lagrange form. The further you are from the center, the larger that factor — and the larger the error can be.

Taylor's Inequality

Neutralising the Unknown c

The unknown c in the Lagrange form can be neutralized. And the trick is simple. Since c lies somewhere in the interval between a and x, replace the absolute value of the derivative at c with the largest value that derivative attains anywhere on that interval. That yields a quantity certainly at least as large as the true error. So — Theorem eight point five. Taylor's Inequality. Suppose the absolute value of the n plus first derivative is at most M, for every point within distance d of the center. Then for every x within that distance, the absolute remainder is at most M, times absolute x minus a to the n plus one, over n plus one factorial. M is any valid ceiling on the size of that derivative over the interval of interest. A smaller M gives a sharper bound. But any correct M gives a valid guarantee. Three features make this inequality the workhorse of numerical approximation. First. It requires no knowledge of f of x itself. Only a ceiling on one derivative. Second. It holds uniformly for every x in the interval. Not just at sampled points. And third. The factorial in the denominator grows faster than any power in the numerator. Which is exactly why increasing n is so effective. The bound collapses rapidly.

Worked Example 2

Bounding the Error for cos(0.3)

Let's use it. Estimate cosine of zero point three using the degree-four polynomial, and bound the error. Step one. Evaluate the polynomial. With x equal to zero point three, compute the powers first. x squared is zero point zero nine. x to the fourth is zero point zero zero eight one. So P four is one, minus zero point zero nine over two, plus zero point zero zero eight one over twenty-four. That's one minus zero point zero four five, plus zero point zero zero zero three three seven five. Which is zero point nine five five three three seven five. Step two. Identify M. The fifth derivative of cosine is minus sine x. And every derivative of sine or cosine is bounded in absolute value by one. So M equals one is valid on any interval whatsoever. That's a gift specific to trig functions. Step three. Apply the inequality with n equals four, a equals zero, and distance zero point three. You get zero point three to the fifth, over five factorial. Which is about two point zero two five times ten to the minus five. Step four — and this is the clever part. Sharpen it, for free. P four and P five are the same polynomial. Because the degree-five term of the cosine series is zero. So the same numerical estimate is simultaneously a degree-five approximation. Which means the inequality may be applied with n equals five instead. That gives zero point three to the sixth, over six factorial. About one point zero one two five times ten to the minus six. Roughly twenty times tighter. Obtained with no additional computation at all. And the true value of cosine zero point three is zero point nine five five three three six four eight nine. So the actual error is about one point zero one one times ten to the minus six. Just beneath the refined ceiling. Confirming that the bound is both valid, and nearly attained.

Reading It Backwards

Choosing the Degree for a Target Accuracy

Taylor's Inequality is most useful read backwards. Rather than fixing n and computing the error, an engineer fixes a tolerance and solves for the smallest n that satisfies it. And because the factorial makes the bound resistant to algebraic inversion, the standard method is to tabulate the bound for successive n, and read off the first value that clears the target. Let's do it. Determine the smallest degree n such that the Maclaurin polynomial for e to the x approximates e to the zero point five, with error below ten to the minus six. Step one. Identify M. Every derivative of e to the x is e to the x, which is increasing. On the interval from zero to zero point five, its largest value is e to the zero point five. About one point six four eight seven. Rather than carry that decimal, take the convenient overestimate M equals two. That's legitimate, because any valid ceiling produces a valid bound. It just makes the bound slightly less sharp. Step two. Write the bound. Two, times zero point five to the n plus one, over n plus one factorial. Step three. Tabulate. At degree three, the bound is about five times ten to the minus three. Not below target. Degree four: five times ten to the minus four. No. Degree five: four point three times ten to the minus five. No. Degree six: three point one times ten to the minus six. Still no — just above the target. Degree seven: one point nine four times ten to the minus seven. Yes. So degree seven is the smallest that guarantees the tolerance. Now here's the important subtlety. Notice the actual error column. At n equals six the actual error is one point six five times ten to the minus six — which is below the target. So n equals six would in fact have sufficed. But the bound at n equals six does not prove it. And a guarantee must rest on the bound. Not on an error you can only compute by already knowing the answer. Choosing n equals seven buys certainty, at the cost of one extra term.

Key Takeaways

What to Carry Forward

Five takeaways. The degree-n Taylor polynomial matches f and its first n derivatives at the center. So agreement is best there, and degrades outward. The remainder is f of x minus P n of x. And the series converges to f exactly when that remainder goes to zero. The Lagrange form expresses the remainder using an unknown c between a and x. Existence is guaranteed. Location is not. Taylor's Inequality neutralizes that unknown, by replacing the derivative with a ceiling M. And it requires no knowledge of f itself — only a bound on one derivative. And read the inequality backwards to choose a degree. Tabulate the bound, and take the first n that clears the tolerance. A guarantee must rest on the bound. Never on the actual error. Next up is section eight point five — Manipulating Taylor Series. Combining and transforming the standard five.

About Calculus 2 at UPI Study

Calculus 2 (Math 265) is a self-paced online course of 54 video lessons in 10 chapters, from integration techniques to series, parametric curves and vectors. It carries a NCCRS credit recommendation for 4 semester credits.

Every lesson video and transcript is free on pages like this one. Enrolling adds a practice quiz after each lesson, the graded work and final exam that earn the credit, lifetime access, and an official transcript on completion. UPI Study has helped over 130,000 students with college credits. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Why take it here

Why students take Calculus 2 with UPI Study

Open the door to higher mathCalculus 2 is the gateway to Calculus 3, differential equations, statistics and most engineering, physics, economics and computer-science degrees. Completing it now lets you qualify for those courses at your university.
Credit at a fraction of the priceThe same 4 credits can cost $750 or more at a US college. Here it is one payment, self-paced, with lifetime access.
Finish your degree soonerTransfer credits reduce the courses you still owe, so you can graduate earlier or lighten a heavy semester.
Strengthen an applicationA completed college-level course on an official transcript shows admissions and scholarship committees you can do the work.
Study on your own scheduleNo start dates, no deadlines. Watch the lessons, practice, and take the final when you are ready.
130,000+students helped with college creditsACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Where the credit goes

Universities that work with NCCRS

Calculus 2 carries a NCCRS credit recommendation. These universities work with NCCRS; some are UPI Study's signed partners. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.

Find my college → Not listed? Ask Athena in the corner of this page, or book a 15-minute call.

FAQ

Questions students ask us

About Taylor Polynomials and the Remainder

What is the remainder of a Taylor polynomial, and what is the Lagrange form?
The remainder R_n(x) = f(x) - P_n(x) is the exact error made when a Taylor series is truncated to its degree-n polynomial. The Lagrange form says that if f has n+1 continuous derivatives on an interval containing a and x, then R_n(x) = \frac{f^{(n+1)}(c)}{(n+1)!}(x-a)^{n+1} for some c strictly between a and x. The theorem guarantees that c exists but gives no way to locate it.
How do you use Taylor's Inequality to bound the error of an approximation?
Find a ceiling M with |f^{(n+1)}| \le M on the interval, then use |R_n(x)| \le \frac{M|x-a|^{n+1}}{(n+1)!}. For \cos(0.3) using P_4, take M=1, since no derivative of cosine exceeds 1 in absolute value. The cosine series has no degree-five term, so P_4 = P_5 and you may use n=5. That gives an error of at most 0.3^6/6! \approx 1.01 \times 10^{-6}.
How do you find the degree of Taylor polynomial needed for a given accuracy?
Fix the tolerance, write the Taylor's Inequality bound as a function of n, and tabulate it until the first n falls below the target. For e^{0.5} with error under 10^{-6}, take M=2 as an easy overestimate of e^{0.5} \approx 1.6487. The bound \frac{2(0.5)^{n+1}}{(n+1)!} is about 3.1 \times 10^{-6} at n=6 and 1.94 \times 10^{-7} at n=7. So degree 7 is the smallest degree the bound guarantees.
Is it wrong to use a larger value of M than necessary in Taylor's Inequality?
No, any M that truly bounds |f^{(n+1)}| on the whole interval gives a valid guarantee. A larger M only makes the bound less sharp. The real mistake is choosing an M that fails somewhere on the interval, such as evaluating the derivative only at the center a. The bound must hold for every point within distance d of a, because the unknown c could be anywhere between a and x.

About the Calculus 2 course

How many college credits is Calculus 2?
Calculus 2 (Math 265) carries a NCCRS credit recommendation for 4 semester credits. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities.
How much does Calculus 2 cost and what is included?
$250, paid once, with lifetime access: all 54 video lessons, a practice quiz after each, the graded work and final exam, and an official transcript when you finish. Students who want several courses choose UPI Study PRO instead.
Which universities accept UPI Study credits?
UPI Study has signed partner agreements with universities such as Thomas Edison State University, University of the People and Charter Oak State College, and works with universities such as Penn State, SNHU and SUNY. ACE and NCCRS have over 2,100 cooperating colleges that will consider accepting credits; the final decision is with the universities. Use "Find my college" on this page to check yours.
How long does Calculus 2 take?
It is self-paced with no deadlines. The 54 lessons total about 9 hours of video; most students add reading and practice time and finish in a few weeks to a few months, on their own schedule.
How are the exams done?
Quizzes and assignments are online in the course. The final exam is taken online with proctoring; a person on the UPI Study team checks assignments, usually within two days.
How do my credits reach my college?
When the course shows 100% complete, request the official transcript from your dashboard. It is sent to the college you name, and you can send it to more than one. Check your college first with "Find my college" on this page, or ask Athena.

Ready for the full course? Earn 4 credits in Calculus 2.

54 video lessons, a quiz after each one, and the graded work that earns the credit. Recommended for credit by NCCRS.

Calculus 2
4 credits · NCCRS
Enroll →