Recall that
T 2 n ( x ) = ∑ k = 0 2 n f ( k ) ( π 4 ) k ! ( x − π 4 ) k T_{2n}(x)=\sum_{k=0}^{2n} \frac{f^{(k)}\left(\frac{\pi}{4}\right)}{k!}\left(x-\frac{\pi}{4}\right)^k T 2 n ( x ) = k = 0 ∑ 2 n k ! f ( k ) ( 4 π ) ( x − 4 π ) k
Let's start by taking some derivatives. Of course, since we're differentiating sine, the derivatives will repeat every four iterations.
f ( x ) = sin x f ( π 4 ) = 1 2 f ′ ( x ) = cos x f ′ ( π 4 ) = 1 2 f ′ ′ ( x ) = − sin x f ′ ′ ( π 4 ) = − 1 2 f ′ ′ ′ ( x ) = − cos x f ′ ′ ′ ( π 4 ) = − 1 2 \begin{aligned}
f(x)&=\sin x & f\left(\frac{\pi}{4}\right)&=\frac{1}{\sqrt 2}\\
f'(x)&=\cos x & f'\left(\frac{\pi}{4}\right)&=\frac{1}{\sqrt{2}}\\
f''(x)&=-\sin x & f''\left(\frac{\pi}{4}\right)&=-\frac{1}{\sqrt 2}\\
f'''(x)&=-\cos x & f'''\left(\frac{\pi}{4}\right)&=-\frac{1}{\sqrt{2}}\\
\end{aligned} f ( x ) f ′ ( x ) f ′′ ( x ) f ′′′ ( x ) = sin x = cos x = − sin x = − cos x f ( 4 π ) f ′ ( 4 π ) f ′′ ( 4 π ) f ′′′ ( 4 π ) = 2 1 = 2 1 = − 2 1 = − 2 1
So, the pattern of derivatives is 1 2 \dfrac{1}{\sqrt{2}} 2 1 , 1 2 \dfrac{1}{\sqrt{2}} 2 1 , − 1 2 -\dfrac{1}{\sqrt{2}} − 2 1 , − 1 2 -\dfrac{1}{\sqrt{2}} − 2 1 , 1 2 \dfrac{1}{\sqrt{2}} 2 1 , 1 2 \dfrac{1}{\sqrt{2}} 2 1 , − 1 2 -\dfrac{1}{\sqrt{2}} − 2 1 , − 1 2 -\dfrac{1}{\sqrt{2}} − 2 1 , etc. This is a little tricky to write in sigma notation. We can deal with the “doubles" by separating the even and odd powers. The first few terms of T 2 n T_{2n} T 2 n that contain even powers of ( x − π 4 ) \left(x-\frac{\pi}{4}\right) ( x − 4 π ) are
1 2 ⏟ k = 0 − 1 2 ! 2 ( x − π 4 ) 2 ⏟ k = 2 + 1 4 ! 2 ( x − π 4 ) 4 ⏟ k = 4 \begin{aligned}
\underbrace{\frac{1}{\sqrt{2}}}_{k=0}
-\underbrace{\frac{1}{2!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2}}_{k=2}
+\underbrace{\frac{1}{4!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{4}}_{k=4}
\end{aligned} k = 0 2 1 − k = 2 2 ! 2 1 ( x − 4 π ) 2 + k = 4 4 ! 2 1 ( x − 4 π ) 4
Observe that the signs alternate between successive terms. So if we rename k k k to 2 ℓ 2\ell 2 ℓ these terms are
1 2 ⏟ ℓ = 0 − 1 2 ! 2 ( x − π 4 ) 2 ⏟ ℓ = 1 + 1 4 ! 2 ( x − π 4 ) 4 ⏟ ℓ = 2 \begin{aligned}
\underbrace{\frac{1}{\sqrt{2}}}_{\ell=0}
-\underbrace{\frac{1}{2!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2}}_{\ell=1}
+\underbrace{\frac{1}{4!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{4}}_{\ell=2}
\end{aligned} ℓ = 0 2 1 − ℓ = 1 2 ! 2 1 ( x − 4 π ) 2 + ℓ = 2 4 ! 2 1 ( x − 4 π ) 4
and the ℓ t h \ell^{\rm th} ℓ th term here is
( − 1 ) ℓ ( 2 ℓ ) ! 2 ( x − π 4 ) 2 ℓ \frac{(-1)^\ell}{(2\ell)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell} ( 2 ℓ )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ . To verify that this really is the ℓ t h \ell^{\rm th} ℓ th term, evaluate this for ℓ = 0 , 1 , 2 \ell=0,1,2 ℓ = 0 , 1 , 2 explicitly. When k = 2 n k=2n k = 2 n , ℓ = n \ell=n ℓ = n so that
∑ 0 ≤ k ≤ 2 n k e v e n f ( k ) ( π 4 ) k ! ( x − π 4 ) k = ∑ ℓ = 0 n ( − 1 ) ℓ ( 2 ℓ ) ! 2 ( x − π 4 ) 2 ℓ \begin{aligned}
\sum_{\genfrac{}{}{0in}{}{0\le k\le 2n}{k{\rm\ even}}} \frac{f^{(k)}\left(\frac{\pi}{4}\right)}{k!}\left(x-\frac{\pi}{4}\right)^k
=\sum_{\ell=0}^{n}\frac{(-1)^\ell}{(2\ell)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell}
\end{aligned} k even 0 ≤ k ≤ 2 n ∑ k ! f ( k ) ( 4 π ) ( x − 4 π ) k = ℓ = 0 ∑ n ( 2 ℓ )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ
Now for the odd powers. The first few terms of T 2 n T_{2n} T 2 n that contain odd powers of ( x − π 4 ) \left(x-\frac{\pi}{4}\right) ( x − 4 π ) are
1 2 ( x − π 4 ) ⏟ k = 1 − 1 3 ! 2 ( x − π 4 ) 3 ⏟ k = 3 + 1 5 ! 2 ( x − π 4 ) 5 ⏟ k = 5 \begin{aligned}
\underbrace{\frac{1}{\sqrt{2}}\left(x-\frac{\pi}{4}\right)}_{k=1}
-\underbrace{\frac{1}{3!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{3}}_{k=3}
+\underbrace{\frac{1}{5!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{5}}_{k=5}
\end{aligned} k = 1 2 1 ( x − 4 π ) − k = 3 3 ! 2 1 ( x − 4 π ) 3 + k = 5 5 ! 2 1 ( x − 4 π ) 5
Observe that the signs again alternate between successive terms. So if we rename k k k to 2 ℓ + 1 2\ell+1 2 ℓ + 1 these terms are
1 2 ( x − π 4 ) ⏟ ℓ = 0 − 1 3 ! 2 ( x − π 4 ) 3 ⏟ ℓ = 1 + 1 5 ! 2 ( x − π 4 ) 5 ⏟ ℓ = 2 \begin{aligned}
\underbrace{\frac{1}{\sqrt{2}}\left(x-\frac{\pi}{4}\right)}_{\ell=0}
-\underbrace{\frac{1}{3!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{3}}_{\ell=1}
+\underbrace{\frac{1}{5!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{5}}_{\ell=2}
\end{aligned} ℓ = 0 2 1 ( x − 4 π ) − ℓ = 1 3 ! 2 1 ( x − 4 π ) 3 + ℓ = 2 5 ! 2 1 ( x − 4 π ) 5
and the ℓ t h \ell^{\rm th} ℓ th term here is
( − 1 ) ℓ ( 2 ℓ + 1 ) ! 2 ( x − π 4 ) 2 ℓ + 1 \frac{(-1)^\ell}{(2\ell+1)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell+1} ( 2 ℓ + 1 )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ + 1 .
To verify that this really is the ℓ t h \ell^{\rm th} ℓ th term, evaluate this for ℓ = 0 , 1 , 2 \ell=0,1,2 ℓ = 0 , 1 , 2 explicitly.
The largest odd integer that is smaller than 2 n 2n 2 n is 2 n − 1 2n-1 2 n − 1 and when k = 2 n − 1 = 2 ℓ + 1 k=2n-1=2\ell+1 k = 2 n − 1 = 2 ℓ + 1 ,
ℓ = n − 1 \ell=n-1 ℓ = n − 1 so that
∑ 0 ≤ k ≤ 2 n k o d d f ( k ) ( π 4 ) k ! ( x − π 4 ) k = ∑ ℓ = 0 n − 1 ( − 1 ) ℓ ( 2 ℓ + 1 ) ! 2 ( x − π 4 ) 2 ℓ + 1 \begin{aligned}
\sum_{\genfrac{}{}{0in}{}{0\le k\le 2n}{k{\rm\ odd}}} \frac{f^{(k)}\left(\frac{\pi}{4}\right)}{k!}\left(x-\frac{\pi}{4}\right)^k
=\sum_{\ell=0}^{n-1}\frac{(-1)^\ell}{(2\ell+1)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell+1}
\end{aligned} k odd 0 ≤ k ≤ 2 n ∑ k ! f ( k ) ( 4 π ) ( x − 4 π ) k = ℓ = 0 ∑ n − 1 ( 2 ℓ + 1 )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ + 1
Putting the even and odd powers together
T 2 n ( x ) = ∑ ℓ = 0 n ( − 1 ) ℓ ( 2 ℓ ) ! 2 ( x − π 4 ) 2 ℓ + ∑ ℓ = 0 n − 1 ( − 1 ) ℓ ( 2 ℓ + 1 ) ! 2 ( x − π 4 ) 2 ℓ + 1 \begin{aligned}
T_{2n}(x)&=\sum_{\ell=0}^{n}\frac{(-1)^\ell}{(2\ell)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell}
+\sum_{\ell=0}^{n-1}\frac{(-1)^\ell}{(2\ell+1)!\sqrt{2}}\left(x-\frac{\pi}{4}\right)^{2\ell+1}
\end{aligned} T 2 n ( x ) = ℓ = 0 ∑ n ( 2 ℓ )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ + ℓ = 0 ∑ n − 1 ( 2 ℓ + 1 )! 2 ( − 1 ) ℓ ( x − 4 π ) 2 ℓ + 1