# 009C Sample Final 2, Problem 5

Find the Taylor Polynomials of order 0, 1, 2, 3 generated by  ${\displaystyle f(x)=\cos(x)}$  at  ${\displaystyle x={\frac {\pi }{4}}.}$

Foundations:
The Taylor polynomial of   ${\displaystyle f(x)}$   at   ${\displaystyle a}$   is

${\displaystyle \sum _{n=0}^{\infty }c_{n}(x-a)^{n}}$ where ${\displaystyle c_{n}={\frac {f^{(n)}(a)}{n!}}.}$

Solution:

Step 1:
Let  ${\displaystyle a={\frac {\pi }{4}}.}$
First, we make a table to find the coefficients of the Taylor polynomial.
 ${\displaystyle n}$ ${\displaystyle f^{(n)}(x)}$ ${\displaystyle f^{(n)}(a)}$ ${\displaystyle {\frac {f^{(n)}(a)}{n!}}}$ ${\displaystyle 0}$ ${\displaystyle \cos x}$ ${\displaystyle {\frac {\sqrt {2}}{2}}}$ ${\displaystyle {\frac {\sqrt {2}}{2}}}$ ${\displaystyle 1}$ ${\displaystyle -\sin x}$ ${\displaystyle -{\frac {\sqrt {2}}{2}}}$ ${\displaystyle -{\frac {\sqrt {2}}{2}}}$ ${\displaystyle 2}$ ${\displaystyle -\cos x}$ ${\displaystyle -{\frac {\sqrt {2}}{2}}}$ ${\displaystyle -{\frac {\sqrt {2}}{4}}}$ ${\displaystyle 3}$ ${\displaystyle \sin x}$ ${\displaystyle {\frac {\sqrt {2}}{2}}}$ ${\displaystyle {\frac {\sqrt {2}}{12}}}$
Step 2:
Let  ${\displaystyle T_{n}}$  be the Taylor polynomial of order  ${\displaystyle n.}$
Since   ${\displaystyle c_{n}={\frac {f^{(n)}(a)}{n!}},}$  we have

${\displaystyle T_{0}={\frac {\sqrt {2}}{2}}}$
${\displaystyle T_{1}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}}$
${\displaystyle T_{2}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}-{\frac {\sqrt {2}}{4}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{2}}$
${\displaystyle T_{3}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}-{\frac {\sqrt {2}}{4}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{2}+{\frac {\sqrt {2}}{12}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{3}.}$

Let  ${\displaystyle T_{n}}$  be the Taylor polynomial of order  ${\displaystyle n.}$
${\displaystyle T_{0}={\frac {\sqrt {2}}{2}}}$
${\displaystyle T_{1}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}}$
${\displaystyle T_{2}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}-{\frac {\sqrt {2}}{4}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{2}}$
${\displaystyle T_{3}={\frac {\sqrt {2}}{2}}-{\frac {\sqrt {2}}{2}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}-{\frac {\sqrt {2}}{4}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{2}+{\frac {\sqrt {2}}{12}}{\bigg (}x-{\frac {\pi }{4}}{\bigg )}^{3}}$