Second order taylor series expansion of $\cos(x+2y)e^{2x}$ around $(2, -1)$ I'm asked to find the second order taylor series expansion of $\cos(x+2y)e^{2x}$ around $(2, -1)$. It's from an old exam of a professor who doesn't give solutions to them, so I don't know if my results are correct. So I woud like that you tell me if my results are correct, and if not, where I made a mistake. Thank you.

As first partial derivatives, I get $$f_x=-\sin(x+2y)e^{2x}+2\cos(x+2y)e^{2x}$$ $$f_y=-2\sin(x+2y)e^{2x}$$ As second partial derivatives, I get 
$$\begin{align}
f_{xx}&=-\cos(x+2y)e^{2x}-2\sin(x+2y)e^{2x}-2\sin(x+2y)e^{2x}+4\cos(x+2y)e^{2x}\\
&=3\cos(x+2y)e^{2x}-4\sin(x+2y)e^{2x}
\end{align}$$
$$f_{yy}=-4\cos(x+2y)e^{2x}$$ $$f_{xy}=f_{yx}=-2\cos(x+2y)e^{2x}-4\sin(x+2y)e^{2x}$$ 
So now, if I plug everything into the formula, I get 
$$e^{4}+2e^{4}(x-2)+\frac{1}{2!}(3e^{4}(x-2)^2-4e^{4}(x-2)(y+1)-4e^{4}(y+1)^2)=e^{4}(1+2(x-2)+\frac{1}{2!}(3(x-2)^2-4(x-2)(y+1)-4(y+1)^2))$$
Are my results correct ? I just proceeded as usual, using the common two-variables taylor series expansion. Thanks for your help !
 A: Yes, it is correct. An easy way to make sure is just to plot things: blue is the original function, red is your expansion

And this is the code to draw it
from mpl_toolkits.mplot3d import Axes3D
import matplotlib.pyplot as plt
from matplotlib import cm
from matplotlib.ticker import LinearLocator, FormatStrFormatter
import numpy as np

fig = plt.figure()
ax = fig.gca(projection = '3d')
ax.set_xlabel('x')
ax.set_ylabel('y')
ax.set_zlabel('z')

def f(X, Y):
    return np.cos(X + 2 * Y) * np.exp(2 * X)

def taylor(x, y):
    return np.exp(4) * (1 + 2 * (x - 2) + 0.5 * (3 * (x - 2)**2 - 4 * (x - 2) * (y + 1) - 4 * (y + 1)**2))

# Make data.
X = np.arange(1, 3, 0.25)
Y = np.arange(-2, 0, 0.25)
X, Y = np.meshgrid(X, Y)
Z = f(X, Y)
W = taylor(X, Y)

# Plot the surface.
surf = ax.plot_surface(X, Y, Z, cmap = cm.autumn, linewidth = 0, antialiased = False, alpha = 0.5)
sur1 = ax.plot_surface(X, Y, W, cmap = cm.winter, linewidth = 0, antialiased = False, alpha = 0.7)

# Add a color bar which maps values to colors.
ax.xaxis.set_major_locator(LinearLocator(4))
ax.yaxis.set_major_locator(LinearLocator(4))
ax.zaxis.set_major_locator(LinearLocator(4))

plt.show()

A: It is correct. You can also obtain the expansion by using the Taylor series of $\sin, \cos,\exp$:
\begin{align}
\cos(x+2y)e^{2x} &= \cos((x-2) + 2(y+1))e^{4+2(x-2)}\\
&= e^{4}\big[\cos(x-2)\cos(2(y+1)) - \sin(x-2)\sin(2(y+1))\big]e^{2(x+2)}\\
&= e^{4}\left[\left(\sum_{n=0}^\infty \frac{(-1)^n}{(2n)!}(x-2)^{2n}\right)\left(\sum_{n=0}^\infty \frac{(-1)^n}{(2n)!}2^{2n}(y+1)^{2n}\right)\right.\\
&- \left.\left(\sum_{n=0}^\infty \frac{(-1)^n}{(2n+1)!}(x-2)^{2n+1}\right)\left(\sum_{n=0}^\infty \frac{(-1)^n}{(2n+1)!}2^{2n+1}(y+1)^{2n+1}\right)\right]\left(\sum_{n=0}^\infty \frac{2^n}{n!}(x-2)^{n}\right)\\
&= e^{4}\left[1+2(x-2) + \left(\frac{(-1)^1}{2!} - \frac{(-1)^1}{1!}\frac{2^1}{1!}\right)(x-2)^2 - \frac{(-1)^0}{0!}2^1\cdot \frac{2}{2!}(x-2)(y+1) + \frac{(-1)^1}{2!}2^2(y+2)^2 + \cdots\right]\\
&= e^4\left[1+2(x-2)+\frac32 e^{4}(x-2)^2-2e^{4}(x-2)(y+1)-2e^{4}(y+1)^2 + \cdots\right]
\end{align}
