[Math] Finding the degree of the Maclaurin polynomial approximation of cosine to approximate $\cos(1)$

approximationcalculusestimationpower seriestaylor expansion

I have a question where I am asked to find the amount of terms required in a Maclaurin polynomial to estimate $\cos(1)$ to be correct to two decimal places.

So far what I have done is used Taylor's Theorem to get the follow:

$$|R_n(x)| = (|f^{(n)}*x^n|)/n! < (x^n)/n! < 0.005$$

I think so far this is my best attempt but I am not really sure how to proceed from this point to calculate a value of $n$. I did write out a Maclaurin polynomial for $f(x) = \cos(x)$ and attempt to see if I plugged numbers into that to see what came out and compare that to $\cos(1)$ but was unable to make any sense of my answers there.

I am not sure if I am on the right track here and any feedback would be greatly appreciated,

Best Answer

So your goal is to compute $\cos(1)$ to within $0.005$. And you've recognized that the degree $n-1$ Taylor polynomial has error at most $\frac{x^n}{n!}$ at $x$. Since you are interested in the value when $x = 1$, the error is at most $\frac{1}{n!}$.

It remains to find $n$ such that $\frac{1}{n!} < 0.005$, or equivalently such that $n! > \frac{1}{0.005} = 200$.

It is easiest to try a few $n$ and see. $1! = 1, 2! = 2, 3!=6, 4!=24,5!=120,6!=720$. Aha! We see that $7! = 720 > 200$, and so $\frac{1}{7!} < 0.005$.

Thus we know that a degree $6$ Taylor approximation will be accurate enough. In total, we have that $$ \cos(1) = 1 - \frac{1^2}{2!} + \frac{1^4}{4!} - \frac{1^6}{6!} \pm 0.005.$$

In fact, $\cos(1) =0.5403\ldots$ and the approximation is $0.54027\ldots$ That's very close indeed!

Related Question