Can anyone show me how to get the derivative of the squared Frobenius Norm for this second degree matrix $X$?
$$||XX^T||_F^2$$
Can anyone show me how to get the derivative of the squared Frobenius Norm for this second degree matrix $X$?
$$||XX^T||_F^2$$
Copyright © 2021 JogjaFile Inc.
Use a colon to denote the matrix inner product.
Write down the function and calculate its gradient as follows $$\eqalign{ \phi &= \big\|XX^T\big\|_F^2 \\ &= XX^T:XX^T \\ d\phi &= 2XX^T:d(XX^T) \\ &= 2XX^T:\Big(X\,dX^T+dX\,X^T\Big) \\ &= 2\Big(XX^T+(XX^T)^T\Big):dX\,X^T \\ &= 4XX^TX:dX \\ \frac{\partial \phi}{\partial X} &= 4XX^TX \\ }$$ This is analogous to the scalar $({\tt1}\times{\tt1})$ derivative result $$\frac{d X^4}{dX}=4X^3$$