## - Taylor's Series

Here are the conditions needed for Taylor’s Series

• The function $$f(x)$$ has to be infinitely differentiable
• The function $$f(x)$$ has to be defined in a region near the value $$x=a$$.
Maclaurin’s Series is:
$$\displaystyle g(x)=g(0)+xg'(0)+{x^2\over2!} g''(0)+{x^3\over3!}g'''(0)+⋯+{x^n\over n!} g^n(0)+⋯$$
For Taylor’s Series, we let $$f(x+a)=g(x)$$
$$\displaystyle f(x+a)=f(a)+f'(a)x+{f''(a)\over2!} x^2+{f'''(a)\over3!} x^3+⋯+{f^n (a)\over n!} x^n+⋯$$
Furthermore, replacing $$x$$ with $$x-a$$ we get
$$\displaystyle f(x)=f(a)+f'(a)(x-a)+{f''(a)\over2!} (x-a)^2+{f'''(a)\over3!} (x-a)^3+⋯+{f^n (a)\over n!} (x-a)^n+⋯$$
$$\displaystyle f(x)=\sum_{k=0}^\infty {f^k (a)\over k!} (x-a)^k$$

LESSON 1
Find the first four non – zero terms for the Taylor expansion of $$\displaystyle {1\over x+3}$$ with centre $$a=1$$.
SOLUTION
Let $$\displaystyle f(x)={1\over x+3}=(x+3)^{-1}$$
• Determine needed values
$$\displaystyle f(x)={1\over x+3} \to f(1)={1\over4}$$
$$\displaystyle f'(x)=-{1\over (x+3)^2} \to f'(1)=-{1\over16}$$
$$\displaystyle f''(x)={2\over (x+3)^3} \to f''(1)={1\over32}$$
$$\displaystyle f'''(x)=-{6\over(x+3)^4} \to f'''(1)=-{3\over128}$$
• Substitute values into formula
$$\displaystyle f(x+a)=f(a)+f'(a)(x-a)+{f''(a)\over2!} (x-a)^2+{f'''(a)\over3!} (x-a)^3+⋯+{f^n (a)\over n!}(x-a)^n+⋯$$
$$\displaystyle {1\over x+3}={1\over4}-{1\over16} (x-1)+{1\over32} \left({1\over2!}\right) (x-1)^2-{3\over128} \left({1\over3!}\right) (x-1)^3$$
$$\displaystyle ={1\over4}-{1\over16} (x-1)+{1\over64} (x-1)^2-{3\over256} (x-1)^3$$

LESSON 2
(i) Obtain the first four non – zero terms of the Taylor Series expansion of sin⁡x in ascending powers of $$\displaystyle \left(x-{\pi\over4}\right)$$.
(ii) Hence, calculate an approximation to $$\displaystyle \sin\left({π\over16}\right)$$.
SOLUTION
• Determine the value of $$a$$
Let $$f(x)=\sin⁡ x⟹f(x-a)=\sin⁡(x-a)$$
$$\displaystyle ⟹f\left(x-{\pi\over4}\right)=\sin⁡(x-a)$$
$$\displaystyle ⟹a={π\over4}$$
• Determine the derivatives
$$\displaystyle f(x)=\sin⁡x\to f\left({\pi\over4}\right)=\sin\left({\pi\over4}\right)={\sqrt{2}\over2}$$
$$\displaystyle f'(x)=\cos ⁡x \to f'\left({π\over4}\right)=\cos\left({π\over4}\right)={\sqrt{2}\over2}$$
$$\displaystyle f''(x)=-\sin⁡ x \to f''\left({π\over4}\right)=-\sin\left({π\over4}\right)=-{\sqrt{2}\over2}$$
$$\displaystyle f''(x)=-\cos ⁡x \to f'''(x)=-\cos\left({π\over4}\right)=-{\sqrt{2}\over2}$$
$$\displaystyle f(x)=f(a)+f'(a)(x-a)+{f''(a)\over 2!} (x-a)^2+{f'''(a)\over3!} (x-a)^3+⋯+{f^n (a)\over n!} (x-a)^n$$
$$\displaystyle \sin⁡ x={\sqrt{2}\over2}+{\sqrt{2}\over2} \left(x-{π\over4}\right)-{\sqrt{2}\over2} \left({1\over2!}\right) \left(x-{π\over4}\right)^2-{\sqrt{2}\over2} \left({1\over3!}\right) \left(x-{π\over4}\right)^3$$
$$\displaystyle ={\sqrt{2}\over2}+{\sqrt{2}\over2} \left(x-{π\over4}\right)-{\sqrt{2}\over4} \left(x-{π\over4}\right)^2-{\sqrt{2}\over12} \left(x-{π\over4}\right)^3$$

(ii) $$\displaystyle \sin\left({π\over16}\right)⟹x={π\over16}$$
Now,
$$\displaystyle \left(x-{π\over4}\right)=\left({π\over16}-{π\over4}\right)$$
$$\displaystyle ⟹\left(x-{π\over4}\right)=-{3π\over16}$$
• Replace $$\displaystyle \left(x-{π\over4}\right)$$ with $$\displaystyle -{3π\over16}$$
$$\displaystyle \sin\left({π\over16}\right)={\sqrt{2}\over2}+{\sqrt{2}\over2} \left(-{3π\over16}\right)-{\sqrt{2}\over4} \left(-{3π\over16}\right)^2-{\sqrt{2}\over12} \left(-{3π\over16}\right)^3$$
$$=0.1920$$