Artificial intelligent assistant

Prove that $\exp(A+B)=\exp(A)\exp(B)$ iff $[A,B] = 0$ I have searched throughout the forum and online as well, and I got that with condition of $[A,B]=0$, $e^{(A+B)t}=e^{At}e^{Bt}$. Now the question is, to show for any matrices $A$ and $B$, it is true that $e^{(A+B)t}=e^{At}e^{Bt}$ for all t if and only if $[A,B]=0$ Well, I asked my professor and he told me to show what if $AB \neq BA$, and I really have no idea how to condense those massive equations.... The reason why is that $[A,B]=0$ is not a condition given in this question and I'm confused.

To show $e^{(A+B)t} = e^{At}e^{Bt}$ for all $t$ $\implies [A,B] = 0$ compare the coefficient of $t^2$ in the power-series expansion of both sides of the equation. We have $$e^{(A+B)t} = 1+ (A+B)t + \color{red}{\frac{(A+B)^2}{2!} t^2} + \ldots$$

and

$$e^{At}e^{Bt} = \left(1+At + \frac{A^2}{2!}t^2+\ldots\right)\left(1+Bt + \frac{B^2}{2!}t^2+\ldots\right) \\\= 1 + (A+B)t + \color{red}{\frac{A^2 + 2AB + B^2}{2!}t^2} + \ldots$$

Comparing the two expressions above gives us $$(A+B)^2 = A^2 + 2AB + B^2 \implies AB = BA$$

* * *

Comparing the general $t^n$-term in the power-series expansion gives us the equation $(A+B)^n = \sum_{k=0}^n{n\choose k}A^kB^{n-k}$ which is just the binomial theorem which holds for matrices given that $[A,B] = 0$. This gives a proof of the other direction: $[A,B] = 0 \implies e^{(A+B)t} = e^{At}e^{Bt}$.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy de6f3dd0d25610fe8789fd5736404646