# How To quickly do derivatives with respect to matrices

Whats a quick way to work the below (and problems similar) out?

For me to take this derivative it involves a lot of time and boring calculation, there has to be a better way.

This is taken from the solutions to Chris Bishop's Pattern Recognition and Machine learning:

-

$$\frac{\partial}{\partial A} (\mathbf{x} -\mathbf{A}\mathbf{s})^T\mathbf{W}(\mathbf{x} -\mathbf{A}\mathbf{s}) = -2\mathbf{W}(\mathbf{x}-\mathbf{A}\mathbf{s})\mathbf{s}^T$$
we see that this directly refers to your problem, if we assume $\Sigma^{-1}$ is a covariance matrix and therefore symmetric.
I made a couple of formatting changes - you might like to know that you can start and terminate a piece of Latex with $$...$$ if you want an equation to be centre-aligned. – Silverfish Feb 25 at 11:25