Prove that $\det(A^p+B^p)=\det (A^p)+\det(B^p) +\operatorname{tr}\left(\left(A\operatorname{adj}(B)\right)^p\right)$ 
Let $A,B$ be $2\times 2$ matrices such that $AB=BA$. Prove that for every positive integer $p$:
  $$
\det(A^p+B^p)=\det (A^p)+\det(B^p)
+\operatorname{tr}\left(\left(A\operatorname{adj}(B)\right)^p\right)
$$
  where $\operatorname{adj}(B)$ is the classical adjoint of $B$.

I'm stuck with this problem. I tried with small $p$, but it is still difficult in those small cases. Maybe the Caley-Hamilton Theorem will have some help. 
Thanks a lot.
 A: Straightforward calculation shows that the statement is true for $p=1$, i.e. 
$$
\det(X+Y)=\det(X)+\det(Y)+\operatorname{tr}\left(X\operatorname{adj}(Y)\right)
$$
for any two $2\times2$ matrices $X$ and $Y$. This is true regardless of the ground field and regardless of whether $X$ and $Y$ commute. If you put $X=A^p$ and $Y=B^p$, you get
$$
\det(A^p+B^p)=\det (A^p)+\det(B^p)
+\operatorname{tr}\left(A^p\operatorname{adj}(B^p)\right).
$$
Now, if $A$ and $B$ commute, $A$ must also commute with $\operatorname{adj}(B)$ (why?). Therefore $A^p\operatorname{adj}(B^p)=A^p\operatorname{adj}(B)^p=\left(A\operatorname{adj}(B)\right)^p$. Hence the result.
A: Start by assuming that $A$ and $B$ are diagonal, so $$A=\begin{pmatrix} a & 0 \\ 0 & b \end{pmatrix}$$ and 
$$B=\begin{pmatrix} c & 0 \\ 0 & d \end{pmatrix}.$$ 
The left hand side of your equation is then $$(a^p+c^p)(b^p+d^p),$$ while the right hand side is $$a^pb^p+c^pd^p+(a^pd^p+b^pc^p),$$
the formula is correct. 
Diagonalizable matrices are dense in all matrices, and the determinant and trace are unchanged by conjugation. Finally, since $A$ and $B$ commute, if they are diagonalizable then they are simultaneously diagonalizable. Hence the equation is true on a dense subset of all pairs of commuting matrices, which means it holds for all of them, since all functions and operations involved are continuous.
When you don't understand a problem simplify it till you can work an example.
