MES Math Tutorials

Free math tutorials by Math Easy Solutions.

Example 2: Approximating sin(x) with Taylor Polynomials and Calculating its Error

View on YouTube ↗

A section of Infinite Sequences and Series: Applications of Taylor Polynomials: the full video with all its notes is on that page.

Notes: Example 2: Approximating sin(x) with Taylor Polynomials and Calculating its Error

Written notes — from Infinite Sequences and Series: Applications of Taylor Polynomials.

Example 2

(a) What is the maximum error possible in using the approximation below?

image.png

Use this approximation to find sin 12° correct to six decimal places.

(b) For what values of x is this approximation accurate to within 0.00005?

Solution:

Recall the Maclaurin series for sin x listed in the earlier Table 1:

image.png

Note that this series is alternating for all nonzero values of x:

image.png

The successive terms decrease in size because |x| < 1 and their limit approaches 0, so we can use the Alternating Series Estimation Theorem.

The error in approximating sin x by the first three terms of its Maclaurin series is at most:

image.png

Calculation Check: 7! = 5,040

If -0.3 ≤ x ≤ 0.3, then |x| ≤ 0.3, so the error is smaller than:

image.png

Calculation Check:

https://duckduckgo.com/?q=0.3%5E7%2F5040&t=h_&ia=calculator Retrieved: 30 November 2020 Archive: https://archive.vn/wip/YU0NA

image.png

MES Note: Most calculators use the notation, for example, e-8 as being 10-8.

To find sin 12° we first convert to radians.

image.png Calculation Check:

  • Pi/15 - (pi/15)^3 * 1/3! + (pi/15)^5 * 1/5! = 0.207911694322979
  • Sin(12) = 0.207911690817759

Thus, correct to six decimal places, since our estimated error is within 8 decimal places, we have sin 12° ≈ 0.207912.

(b) The error will be smaller than 0.00005 if:

image.png

Calculation Check:

  • 0.252^(1/7) = 0.8213
  • 0.00005 * 5040 = 0.252

So the given approximation is accurate to within 0.00005 when |x| < 0.82.


What If We Use Taylor's Inequality to Solve Example 2?

Solving for the derivatives of sin x we get:

image.png

Since cosine and sine functions oscillate between -1 and 1, we can apply Taylor's Inequality accordingly:

image.png

This is the same as before, thus we get the same estimates as with the Alternating Series Estimation Theorem.


What About Graphical Methods?

We can graph the following Remainder function:

image.png

We can graph the Remainder and compare it to the maximum error determined in Example 2 (a).

https://www.desmos.com/calculator/yphi6wpizp Retrieved: 30 November 2020 Archive: https://archive.vn/uBfTI

image.png

We can see from it that |R6(x)| < 4.3 x 10-8 when |x| ≤ 0.3. This is the same estimate that we obtained in Example 2 (a).

For part (b) we want |R6(x)| < 0.00005, so we graph both y = |R6(x)| and y = 0.00005 in the figure below.

https://www.desmos.com/calculator/5uuyhdlp1y Retrieved: 20 November 2020 Archive: https://archive.vn/wip/HfFPF

image.png Plotting x = ± 0.82 we can find that the inequality is satisfied when |x| < 0.82.

Again this is the same estimate that we obtained in the solution to Example 2 (b).


If we had been asked to approximate sin 72° instead of sin 12° in Example 2, it would have been wise to use the Taylor polynomials at a = π/3 (instead of a = 0) because they are better approximations to sin x for values of x close to π/3.

Notice that 72° is close to 60° (or π/3 radians) and the derivatives of sin x are easy to compute at π/3.


We can graph the following Maclaurin polynomial approximations for sin x:

image.png

https://www.desmos.com/calculator/8pl3nc2zha Retrieved: 8 December 2020 Archive: https://archive.vn/lwL83

image.png You can see that as n increases, Tn(x) is a good approximation to sin x on a larger and larger interval.

One use of the type of calculation done in Examples 1 and 2 occurs in calculators and computers.

For instance, when you press the sin or ex keys on your calculator, or when a computer programmer uses a subroutine for a trigonometric or exponential or Bessel function, in many machines a polynomial approximation is calculated.

The polynomial is often a Taylor polynomial that has been modified so that the error is spread more evenly throughout an interval.


Example 2: Approximating sin(x) with Taylor Polynomials and Calculating its Error
Notes originally posted on the Hive blockchain →
Notes retrieved from the Hive blockchain (Infinite Sequences and Series: Applications of Taylor Polynomials, December 14, 2020).
Comments
Advertisement