What's the general formula for taking the derivative of a matrix w.r.t to another matrix? For example, what's $\frac{\partial A}{X}$, $\frac{\partial A}{X^\top}$, $\frac{\partial A}{\tilde{X}}$, $\frac{\partial A}{\tilde{X}^\top}$ for $A = X\tilde{X}^\top$, $A = X\tilde{X}$, $A = X^\top\tilde{X}$, and $A = X^\top\tilde{X}^\top$.
Or how about $\frac{\partial A}{X}$, $\frac{\partial A}{X^\top}$ for $A = XX^\top$, $A = X^2$, $A = X^\top X$
I struggle to derive these generally, are there known formulas for these? How do I in general go about deriving these? There are also more complicated cases of $\frac{\partial X\tilde{X}}{X^\top \tilde{X}}$ and so on.