Condition on moment generating functions implies independence 
Let X, Y be random variables so that $M_X(a) = E[e^{aX}]$ and $M_Y(b) = E[e^{bY}]$ are finite for all $|a|, |b| < \delta$ for some $\delta > 0$, and $E[e^{aX + bY}] = E[e^{aX}]E[e^{bY}]$ for all $|a|, |b| < \delta$. Prove that X and Y are independent.

I know that the condition on the moment generating functions implies that $E[X^m]$ and $E[Y^n]$ exist for any nonnegative integers m, n, and I have shown for an earlier problem that if those exist and $E[X^m Y^n] = E[X^m] E[Y^n]$ for all nonnegative integers m, n, then X and Y are independent, but it's not clear how, or whether, it's possible to get $E[X^m Y^n] = E[X^m] E[Y^n]$ out of $E[e^{aX + bY}] = E[e^{aX}]E[e^{bY}]$. 
The best I can figure out how to do is to take a = b with $|a| < \delta$, and get that $M_{X+Y}(a) = E[e^{a(X + Y)}] = E[e^{aX}]E[e^{aY}] = M_X(a) M_Y(a) < \infty$ for all $|a| < \delta$, which I think (and suspect I'm wrong) implies that $E[(X+Y)^n] = E[X^n]E[Y^n]$ for each nonnegative integer n. Even if that is true, I don't have any idea how to get to either independence or $E[X^m Y^n] = E[X^m] E[Y^n]$ from there.
 A: Take $m$ times derivatives with respect to $a$, and $n$ times derivatives with respect to $b$, then take $a=b=0$, you get what you want.
The existence of $\delta >0$ satisfying your given condition enables to exchange differentiation and expectation.
A: First of all, note that it follows from the existence of the exponential moments that
$$\mathbb{E}(|X|^m \cdot |Y|^n e^{aX+Yb}) < \infty \tag{1}$$
for $|a|,|b|$ sufficiently small. Define
$$F(a,b) := \mathbb{E}(e^{aX+bY}).$$
Since the derivatives are suitable integrable, see $(1)$, we may interchange differentiation and integration:
$$\frac{\partial^m}{\partial^m a} F(a,b) = \mathbb{E}\left( \frac{\partial^m}{\partial^m a} e^{aX+bY} \right) = \mathbb{E}(X^m e^{aX+bY}).$$
Using the same argumentation yields
$$\frac{\partial^n}{\partial^n b} \frac{\partial^m}{\partial^m a} F(a,b) = \mathbb{E}(X^n Y^m e^{aX+bY}).$$
On the other hand, it follows from the assumption that $$ F(a,b) = \mathbb{E}(e^{aX}) \mathbb{E}(e^{bY}).$$ Interchanging again integration and differentation, it is not difficult to see that
$$\frac{\partial^n}{\partial^n b} \frac{\partial^m}{\partial^m a} F(a,b) = \mathbb{E}(X^m e^{aX}) \mathbb{E}(Y^m e^{bY}).$$
Combining both equalities and setting $a=b=0$ yields
$$\mathbb{E}(X^m Y^n) = \mathbb{E}(X^m) \mathbb{E}(Y^n).$$
Now the claim follows from the earlier problem you solved.
