The differential of $\lVert D^{1-\lambda} U^* D^{2\lambda}\ UD^{1-\lambda} \rVert_F^2$ with respect to $\lambda$ Let a square matrix $A=WDV^*$ by the SVD where $D$ is diagonal with positive entries, $U=V^*W$ is unitary, and $0<\lambda<1$.  let
$$ f_{(\lambda)} = \lVert D^{1-\lambda} U^* D^{2\lambda}\  UD^{1-\lambda} \rVert_F^2 = \operatorname{tr}\Big(D^{2-2\lambda} U^* D^{2\lambda}\ U \ D^{2-2\lambda} U^* D^{2\lambda}\ U\Big) $$
Please help with the differential $\frac{\partial}{\partial\lambda} f_{(\lambda)}$. I'm thinking in the Frobenius product direction, but I'm not able to get it done.
Thanks in advance.

Post-edit:
Thanks to @greg for pointing my attention to $\operatorname{tr}(M^*M)\ne\operatorname{tr}(M^2)$ since $M=D^{2-2\lambda} U^* D^{2\lambda}\ U$ is not normal. Again, the Frobenius norm is a real-valued function. Therefore, to ensure real-valued trace, will the following be correct? (I implemented some test cases in MATLAB to check the equality).
$$ \begin{align} f_{(\lambda)} & \ne \operatorname{tr}\Big((D^{2-2\lambda} U^* D^{2\lambda}\ U)^2\Big) \\
&=\operatorname{tr}\Big((D^{2-2\lambda} U^* D^{2\lambda}\ U)\ (D^{2-2\lambda} U^* D^{2\lambda}\ U)^*\Big) \\
&=\operatorname{tr}\big(D^{4-4\lambda} U^* D^{4\lambda}\ U\big) \end{align} $$
If it's the right way to state it, please help with the differential $\frac{\partial}{\partial\lambda} f_{(\lambda)}$ with respect to this $f_{(\lambda)}$ version.
 A: First of all let's consider derivative of a trace:
$$
\frac{d}{d\lambda}\mathop{\mathrm{tr}} A(\lambda) = \frac{d}{d\lambda}\left(A_{11} + \ldots+A_{nn}\right) = \frac{dA_{11}}{d\lambda}+\ldots+\frac{dA_{nn}}{d\lambda} = 
\mathop{\mathrm{tr}}\frac{dA}{d\lambda}.
$$
Now consider derivative with matrix power:
$$
\frac{d}{d\lambda}A^\lambda=\frac{d}{d\lambda}e^{\lambda \ln A} = \frac{d}{d\lambda}\left(I+\lambda \ln A+\frac{1}{2!}\lambda^2 \ln^2 A+\frac{1}{3!}\lambda^3 \ln^3 A+\ldots\right)=\\
\left(0+\ln A+  \frac{1}{1!}\lambda\ln A+\frac{1}{2!}\lambda^2\ln^3 A+\ldots\right)=e^{\lambda \ln A}\ln A = A^\lambda \ln A
$$
Combining everything:
$$
\frac{d}{d\lambda}\mathop{\mathrm{tr}} (D^{2-2\lambda}U^*D^{2\lambda}U)^2 = 
-4\mathop{\mathrm{tr}}\left(D^{2-2\lambda}(\ln D)U^*D^{2\lambda}U\right)^2 + 4\mathop{\mathrm{tr}}\left(D^{2-2\lambda}U^*D^{2\lambda}(\ln D)U\right)^2.
$$
Here we also used the fact that  $\mathop{\mathrm{tr}}ABCD = \mathop{\mathrm{tr}}DABC$.
A: For typing convenience, define the diagonal (and symmetric) matrix
$$B=D^4 \quad\implies\; \log(B) = 4\,\log(D)$$
Since the matrix is diagonal, the differential is analogous to the scalar case.
$$dB^\alpha = B^\alpha\log(B)\;d\alpha$$
Write the function in terms of this new variable. Then find its differential and gradient.
$$\eqalign{
f &= {\rm Tr}\big(UB^{-\lambda}BU^*\;B^{\lambda}\big)
   = {\rm Tr}\big(BU^*B^{\lambda}U\;B^{-\lambda}\big)
\\
df
 &= \big(UB^{-\lambda}BU^*\big):dB^{\lambda}
  + \big(BU^*B^{\lambda}U\big):dB^{-\lambda}
\\
\frac{df}{d\lambda}
 &= \big(UB^{-\lambda}BU^*\big):B^{\lambda}\log(B)
  - \big(BU^*B^{\lambda}U\big):B^{-\lambda}\log(B) \\
 &= {\rm Tr}\Big(UB^{-\lambda}BU^*B^{\lambda}\log(B)
  - BU^*B^{\lambda}UB^{-\lambda}\log(B)\Big) \\
}$$
where a colon has been used in the intermediate steps to denote the trace/Frobenius product, i.e. 
$$\eqalign{A:B = {\rm Tr}\big(A^TB\big)}$$
