In a scientific paper, I’ve seen the following

δK−1δp=−K−1δKδpK−1

where K is a n×n matrix that depends on p. In my calculations I would have done the following

δK−1δp=−K−2δKδp=−K−TK−1δKδp

Is my calculation wrong?

Note: I think K is symmetric.

**Answer**

The major trouble in matrix calculus is that the things are no longer commuting, but one tends to use formulae from the scalar function calculus like (x(t)−1)′=−x(t)−2x′(t) replacing x with the matrix K. **One has to be more careful here and pay attention to the order**. The easiest way to get the derivative of the inverse is to derivate the identity I=KK−1 *respecting the order*

(I)′⏟=0=(KK−1)′=K′K−1+K(K−1)′.

Solving this equation with respect to (K−1)′ (again paying attention to the order (!)) will give

K(K−1)′=−K′K−1⇒(K−1)′=−K−1K′K−1.

**Attribution***Source : Link , Question Author : Sara , Answer Author : A.Γ.*