How to expand cos(x+h) in powers of x and h?

Oct 3, 2016

cos(x+h) = sum_(n=0)^oo(1/(n!) sum_(k=0)^n((n),(k))cos((n+k)pi/2)x^(n-k)h^k)

Explanation:

The general expression of the Taylor expansion for functions with two variables is

f(x,h)=sum_(n=0)^oo(1/(n!) sum_(k=0)^n((n),(k))((partial^nf)/(partialx^(n-k)partialh^k))_({x_0,h_0})(x-x_0)^(n-k)(h-h_0)^k)

In this case, considering ${x}_{0} = 0 , {h}_{0} = 0$

${\left(\frac{{\partial}^{n} f}{\partial {x}^{n - k} \partial {h}^{k}}\right)}_{x = 0 , h = 0} = \cos \left(\left(n + k\right) \frac{\pi}{2}\right)$

so

cos(x+h) = sum_(n=0)^oo(1/(n!) sum_(k=0)^n((n),(k))cos((n+k)pi/2)x^(n-k)h^k)

but

$\cos \left(\left(n + k\right) \frac{\pi}{2}\right) = {i}^{n + k} \left(\frac{1 + {\left(- 1\right)}^{n + k}}{2}\right)$ and

((n),(k)) = (n!)/((n-k)!k!)

so

cos(x+h) = sum_(n=0)^oosum_(k=0)^n ( i^(n+k)((1+(-1)^(n+k))/2))/((n-k)!k!)x^(n-k)h^k

with $i = \sqrt{- 1}$

Another way to do that is knowing that from

cosx = sum_(k=0)^oo (-1)^k(x^(2k))/(2k!) follows

cos(x+h) = sum_(k=0)^oo(-1)^k((x+h)^(2k))/(2k!) but here the variables $x + h$ appear added.

Multivariate series handling is very cumbersome because the required notation effort needed.