Cauchy product of two different Taylor series $e^x$ and $\cos x$

I have to do the following task that goes like this:

Calculate the first 5 terms of Taylor expansion of function $f(x) = e^x \cos x$ centered in point $x_0 = 0$ by:

a) forming Cauchy product of Taylor series from $e^x$ and $\cos x$ at point $0$,

b) by finding the derivatives of $f(x)$ and inserting them into the general formula for the Taylor series.

I will now write how I think the first part of the assignment should be done, please correct me if I'm wrong.

Taylor series formula:

$$\sum_{n=0}^{\infty}{\frac{f^{(n)}(x_0)}{n!} (x-x_0)^n}$$

First 5 terms when $x_0 = 0$: \begin{align} &f(x) = e^x\cos x = 1\\ &f'(x) = e^x(\cos x - \sin x) = 1\\ &f''(x) = e^x(-2\sin x) = 0\\ &f'''(x) = 2e^x(-\sin x - \cos x) = -2\\ &f''''(x) = 2e^x(-2\cos x) = -4 \end{align}

a) We can represent $e^x$ and $\cos x$ as Taylor series:

$$e^x = \sum_{n=0}^{\infty}{\frac{x^n}{n!}} \quad\text{and}\quad\cos x = \sum_{n=0}^{\infty}{(-1)^n \frac{x^{2n}}{(2n)!}}$$

Now, we also have formula for Cauchy product, which is: $$(\sum_{i=0}^{\infty}{a_i}) (\sum_{j=0}^{\infty}{b_j}) = \sum_{k=0}^{\infty}{c_k}$$, which gives us: $$c_k = \sum_{k=0}^{n}{a_kb_{n-k}}$$

Now I'm starting to be confused, since I couldn't find anywhere solution for the Cauchy product of these to series, so I just tried this (again, please correct me if it's wrong):

$$\sum_{k=0}^{n}{\frac{x^k}{k!}(-1)^{n-k}\frac{x^{2n-2k}}{(2n-2k)!}} = \sum_{k=0}^{n}{(-1)^{n-k}\frac{x^{2n-k}}{k!(2n-2k)!}}$$

If this is correct, is this the final solution? Also, why it was said "at point $0$", should I substitute something with $0$?

Lastly, we are asked to establish the principle (general formula?) of $n$-th derivative ($n \in \Bbb{N}$) of $f(x)$ and give the complete Taylor expansion of $f(x)$ in point $0$.

P.S. I was translating from German to English, which both aren't my mother languages, so maybe I have mistranslated something.

Sorry for the long post.

Hint for (a). Note that $a_n=1/n!$ and $b_{2n}=(-1)^n/(2n)!$ (and zero otherwise). Hence $$\frac{f^{(n)}(0)}{n!}=c_n = \sum_{k=0}^{n}{a_kb_{n-k}}=\sum_{k=0}^{n}a_{n-k}b_{k}=\sum_{k=0}^{\lfloor n/2\rfloor}a_{n-2k}b_{2k}=\sum_{k=0}^{\lfloor n/2\rfloor}\frac{1}{(n-2k)!}\cdot \frac{(-1)^k}{(2k)!}.$$

Hint for (b). By the general Leibniz rule we have that $$f^{(n)}(0)=\sum_{k=0}^n \binom{n}{k} D^{(n-k)}(e^x)_{x=0}\cdot D^{(k)}(\cos(x))_{x=0}\\=\sum_{k=0}^n \binom{n}{k} \cdot D^{(k)}(\cos(x))_{x=0} =\sum_{k=0}^n \binom{n}{2k} (-1)^k.$$ By the way note that $f(x)=\mbox{Re}(e^{x(1+i)})$ and therefore $$f^{(n)}(0)=\mbox{Re}( (1+i)^n).$$

• Thank you for quick answer, but what does it help me with Cauchy product, since it was explicitly said that we should solve it with Cauchy?
– user555912
Apr 25 '18 at 14:12
• @LukaVeljković See my revised answer and compare it with your work (especially for (a)). Apr 25 '18 at 14:24

Since at first all you're asked for are the first five terms you don't need the fancy formula for the Cauchy product. Just start multiplying and collecting everything up to degree four: $$e^x \cos x = \left( 1 + x + \frac{x^2}{2} + \cdots \right) \left( 1 - \frac{x^3}{6} + \cdots \right) .$$

Lastly, we are asked to establish the principle (general formula?) of $n$-th derivative of $f(x)$ and give the complete Taylor expansion of $f(x)$ in point $0$.
• I think that in your formula "which give us ..." the $c_k$ should be $c_n$. The $k$ on the right is a dummy summation variable and can't appear on the left. Perhaps that's your confusion. Apr 25 '18 at 14:42