Educerie

Educerie · AP · Calculus AB and BC

Unit 10 Infinite Sequences and Series · 10.11 Finding Taylor Polynomial Approximations of Functions

BC only. This topic is on the AP Calculus BC exam and not on AB.

Big ideas: LIM (Limits). Near a point, a smooth function can be matched by a polynomial whose derivatives at that point are the function's own. More terms give a better match.

The question this unit answers: When does an endless sum settle on a number, and how do we tell, and how do we use it to approximate?

Where it is examined: Section I multiple choice: write the Taylor polynomial of a given degree for a function, find a coefficient or a derivative value from a polynomial, or evaluate the polynomial to approximate a value. Section II free response (series question 6, and part of question 5): "find the third-degree Taylor polynomial for ff about x=1x = 1", usually from derivative values in a table or computed from a formula, followed by an approximation and an error bound (10.12).


AP Calculus AB and BC 10.11

Finding Taylor Polynomial Approximations of Functions

When does an endless sum settle on a number, and how do we tell, and how do we use it to approximate?

What you will learn

  • Understand how matching derivatives at a point builds a Taylor polynomial.
  • Know the coefficient f^(k)(a) ÷ k! and why the factorial appears.
  • Understand that a polynomial fits best near its center.

You must be able to

  1. Write a Taylor polynomial from a formula or a table of derivatives.
  2. Use a polynomial to approximate a value.
  3. Read derivatives back from the coefficients.
  4. Handle a center other than 0.
  5. Avoid the missing-factorial slip.

1The formula

The Taylor polynomial of degree nn for ff centered at x=ax = a is

Pn(x)=f(a)+f′(a)(x−a)+f′′(a)2!(x−a)2+f′′′(a)3!(x−a)3+⋯+f(n)(a)n!(x−a)n. P_n(x) = f(a) + f'(a)(x-a) + \frac{f''(a)}{2!}(x-a)^2 + \frac{f'''(a)}{3!}(x-a)^3 + \cdots + \frac{f^{(n)}(a)}{n!}(x-a)^n.

The coefficient of (x−a)k(x-a)^k is f(k)(a)k!\dfrac{f^{(k)}(a)}{k!}. If a=0a = 0, the polynomial is called a Maclaurin polynomial.

Why the factorial? Differentiate ck(x−a)kc_k (x-a)^k kk times and you get k! ckk!\,c_k at x=ax = a. To make that equal f(k)(a)f^{(k)}(a), the coefficient must be f(k)(a)k!\dfrac{f^{(k)}(a)}{k!}.

The CED expects you to know this formula, because the exam gives no formula sheet.

2Building a Taylor polynomial from a formula

Example: f(x)=exf(x) = e^x about a=0a = 0, degree 3.

Every derivative of exe^x is exe^x, and e0=1e^0 = 1. So f(0)=f′(0)=f′′(0)=f′′′(0)=1f(0) = f'(0) = f''(0) = f'''(0) = 1 and

P3(x)=1+x+x22+x36. P_3(x) = 1 + x + \frac{x^2}{2} + \frac{x^3}{6}.

Use it: P3(0.5)=1+0.5+0.125+0.02083‾≈1.6458P_3(0.5) = 1 + 0.5 + 0.125 + 0.0208\overline{3} \approx 1.6458, and e0.5≈1.6487e^{0.5} \approx 1.6487. The polynomial is within 0.003. Figure 1 shows how the polynomials of degree 1, 2 and 3 climb towards exe^x near x=0x = 0.

Graph of e to the x for x from minus 2 to 2 with its Taylor polynomials of degree 1, 2 and 3 about x equals 0. All pass through the point (0, 1) and the higher degrees stay closer to the curve −1 1 2 2 4 6 8 y x eˣ degree 3 degree 2 degree 1
Figure 1 · The function e to the x and its Taylor polynomials of degree 1, 2 and 3 about x = 0

Notice what the figure shows. All three polynomials touch exe^x at x=0x = 0. Near 0 the higher-degree polynomials are closer. Far from 0 they all drift away, and the drift is larger for lower degree. At x=2x = 2, P3(2)≈6.33P_3(2) \approx 6.33 against e2≈7.39e^2 \approx 7.39.

3A center other than 0

Example: f(x)=ln⁡xf(x) = \ln x about a=1a = 1, degree 3.

f(x)=ln⁡x,f′(x)=1x,f′′(x)=−1x2,f′′′(x)=2x3. f(x) = \ln x,\quad f'(x) = \frac1x,\quad f''(x) = -\frac{1}{x^2},\quad f'''(x) = \frac{2}{x^3}.

At x=1x = 1: f(1)=0f(1) = 0, f′(1)=1f'(1) = 1, f′′(1)=−1f''(1) = -1, f′′′(1)=2f'''(1) = 2. So

P3(x)=(x−1)−(x−1)22+23!(x−1)3=(x−1)−(x−1)22+(x−1)33. P_3(x) = (x-1) - \frac{(x-1)^2}{2} + \frac{2}{3!}(x-1)^3 = (x-1) - \frac{(x-1)^2}{2} + \frac{(x-1)^3}{3}.

Use it: P3(1.2)=0.2−0.02+0.006‾≈0.18267P_3(1.2) = 0.2 - 0.02 + 0.00\overline{6} \approx 0.18267, and ln⁡1.2≈0.18232\ln 1.2 \approx 0.18232. The error is about 0.0003.

The terms use (x−1)(x-1), not xx. A polynomial written in powers of xx would be a polynomial about 0, which for ln⁡x\ln x does not exist because ln⁡0\ln 0 is undefined.

Example: f(x)=xf(x) = \sqrt x about a=4a = 4, degree 2.

The derivatives are f′=12xf' = \dfrac{1}{2\sqrt x} and f′′=−14x3/2f'' = -\dfrac{1}{4x^{3/2}}. At 4: f(4)=2f(4) = 2, f′(4)=14f'(4) = \tfrac14, f′′(4)=−132f''(4) = -\tfrac{1}{32}. So

P2(x)=2+x−44−(x−4)264. P_2(x) = 2 + \frac{x-4}{4} - \frac{(x-4)^2}{64}.

Use it: P2(4.4)=2+0.1−0.0025=2.0975P_2(4.4) = 2 + 0.1 - 0.0025 = 2.0975, and 4.4≈2.09762\sqrt{4.4} \approx 2.09762.

4Derivative values given in a table or in words

The exam often gives the derivative values and no formula.

Example (invented): f(2)=5f(2) = 5, f′(2)=−3f'(2) = -3, f′′(2)=4f''(2) = 4, f′′′(2)=12f'''(2) = 12. The third-degree Taylor polynomial about x=2x = 2 is

P3(x)=5−3(x−2)+42!(x−2)2+123!(x−2)3=5−3(x−2)+2(x−2)2+2(x−2)3. P_3(x) = 5 - 3(x-2) + \frac{4}{2!}(x-2)^2 + \frac{12}{3!}(x-2)^3 = 5 - 3(x-2) + 2(x-2)^2 + 2(x-2)^3.

Use it: f(2.1)≈P3(2.1)=5−0.3+0.02+0.002=4.722f(2.1) \approx P_3(2.1) = 5 - 0.3 + 0.02 + 0.002 = 4.722.

The most frequent slip is forgetting to divide by the factorial: writing 4(x−2)24(x-2)^2 instead of 2(x−2)22(x-2)^2, or 12(x−2)312(x-2)^3 instead of 2(x−2)32(x-2)^3.

5Working backwards

If you are given a polynomial, its coefficients give the derivatives at the center.

Example (invented): P3(x)=7+2(x−1)−5(x−1)2+4(x−1)3P_3(x) = 7 + 2(x-1) - 5(x-1)^2 + 4(x-1)^3 is the third-degree Taylor polynomial of ff about x=1x = 1.

  • f(1)=7f(1) = 7.
  • f′(1)=2f'(1) = 2, the coefficient of (x−1)(x-1).
  • f′′(1)=2! (−5)=−10f''(1) = 2!\,(-5) = -10.
  • f′′′(1)=3! (4)=24f'''(1) = 3!\,(4) = 24.

The rule: f(k)(a)=k!×(coefficient of (x−a)k)f^{(k)}(a) = k!\times(\text{coefficient of }(x-a)^k). A coefficient is not a derivative, and a derivative is not a coefficient.

6Maclaurin polynomials to know

Some Maclaurin polynomials are used so often that they should be on hand.

cos⁡x≈1−x22+x424,sin⁡x≈x−x36+x5120,ex≈1+x+x22+x36. \cos x \approx 1 - \frac{x^2}{2} + \frac{x^4}{24}, \qquad \sin x \approx x - \frac{x^3}{6} + \frac{x^5}{120}, \qquad e^x \approx 1 + x + \frac{x^2}{2} + \frac{x^3}{6}.

Why do cos⁡x\cos x and sin⁡x\sin x skip powers? cos⁡x\cos x is even, so only even powers appear, and sin⁡x\sin x is odd, so only odd powers. The derivatives at 0 cycle through 1,0,−1,01, 0, -1, 0 for cosine and 0,1,0,−10, 1, 0, -1 for sine.

Example: P4P_4 for cos⁡x\cos x. Derivatives at 0: f(0)=1f(0) = 1, f′=−sin⁡0=0f' = -\sin 0 = 0, f′′=−cos⁡0=−1f'' = -\cos 0 = -1, f′′′=sin⁡0=0f''' = \sin 0 = 0, f(4)=cos⁡0=1f^{(4)} = \cos 0 = 1. So P4(x)=1−x22!+x44!=1−x22+x424P_4(x) = 1 - \dfrac{x^2}{2!} + \dfrac{x^4}{4!} = 1 - \dfrac{x^2}{2} + \dfrac{x^4}{24}. The odd terms are missing because their coefficients are 0.

These are built from the general formula in 10.14, where the full infinite series are written.

7How good is the approximation?

The CED says that in many cases, as the degree rises, the polynomial approaches the function over some interval. That interval depends on the function.

  • The approximation is always exact at x=ax = a.
  • It is usually best near aa, and gets worse as you move away.
  • A higher degree usually fits better on an interval around aa.

How good is it at a given point? Section 10.12 gives a bound on the error. For now, check by comparing with a known value, as the examples above do.

Practice questions

30 questions on this note, from easy to hard. Each one you get right lights a star of this topic's constellation.