# Taylor series

 $\frac{d}{dx} \sin x=?\,$ This article/section deals with mathematical concepts appropriate for a student in late high school or early university.

The Taylor series of a function is useful for approximating a mathematical function near to some particular point. For a function f(x), the Taylor series about the point x0 is

$f(x)=f(x_0)+(x-x_0)\frac{df(x)}{dx}+\frac{(x-x_0)^2}{2!}\frac{d^2f(x)}{dx^2}+\ldots+\frac{(x-x_0)^N}{N!}\frac{d^Nf(x)}{dx^N}$

where each of the derivatives is to be evaluated at x = x0. If as $N\rightarrow\infty$ the series converges, then it is exact. Otherwise, it can be used as an approximation. Often, Taylor series are performed around x0 = 0, in which case they are sometimes also known as a Maclaurin series.

### Examples of common Taylor series

$e^x=\sum_{n=0}^{\infin} \frac{x^{n}}{n!}=1+x+\frac{x^2}{2!}+\frac{x^3}{3!}+\ldots$

$\sin x=\sum_{n=0}^{\infin} (-1)^n\frac{x^{2n+1}}{(2n+1)!}=x-\frac{x^3}{3!}+\frac{x^5}{5!}-\ldots$

$\cos x=\sum_{n=0}^{\infin} (-1)^n\frac{x^{2n}}{(2n)!}=1-\frac{x^2}{2!}+\frac{x^4}{4!}-\ldots$

#### Extensions of the Exponential Function

Consider the exponential of imaginary number yi,

$e^{yi}=1+yi+\frac{(yi)^2}{2!}+\frac{(yi)^3}{3!}+\frac{(yi)^4}{4!}+\frac{(yi)^5}{5!}+\ldots$

$=1+yi-\frac{y^2}{2!}-i\frac{y^{3}}{3!}+\frac{y^4}{4!}+i\frac{y^5}{5!}-\ldots$
$=(1-\frac{y^2}{2!}+\frac{y^4}{4!}-\ldots)+i(y-\frac{y^{3}}{3!}+\frac{y^5}{5!}-\ldots)$
= cosy + isiny

By the power laws then all complex numbers have an exponential,

ex + yi = ex(cosy + isiny).