Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

How to calculate the gradient with respect to $X$ of: $$ \log \mathrm{det}\, X^{-1} $$ here $X$ is a positive definite matrix, and det is the determinant of a matrix.

How to calculate this? Or what's the result? Thanks!

share|improve this question
1  
Note that $\log\det\mathbf X^{-1}=\log\frac1{\det\mathbf X}=-\log\det\mathbf X$... –  J. M. May 12 '11 at 14:48
3  
And note that $\log \det X =\text{tr} \log X$... –  Fabian May 12 '11 at 14:50
    
Somehow I wonder if what you actually need is the Gâteaux or the Fréchet derivative... where did you encounter this, and what are you actually doing? –  J. M. May 12 '11 at 15:00
    
I encounter this when deriving a lower bound of D-optimal experimental design using dual theory (an exercise of Convex Optimization). I want to find the optimal of a function which involves $\log\mathrm{det}\,(X^{-1})$. –  pluskid May 12 '11 at 15:25

2 Answers 2

up vote 10 down vote accepted

I assume that you are asking for the derivative with respect to the elements of the matrix. In this cases first notice that

$$\log \det X^{-1} = \log (\det X)^{-1} = -\log \det X$$

and thus

$$\frac{\partial}{\partial X_{ij}} \log \det X^{-1} = -\frac{\partial}{\partial X_{ij}} \log \det X = - \frac{1}{\det X} \frac{\partial \det X}{\partial X_{ij}} = - \frac{1}{\det X} \mathrm{adj}(X)_{ji} = - (X^{-1})_{ji}$$

since $\mathrm{adj}(X) = \det(X) X^{-1}$ for invertible matrices (where $\mathrm{adj}(X)$ is the adjugate of $X$, see http://en.wikipedia.org/wiki/Adjugate).

share|improve this answer
    
Thank you very much! This solved my problem! –  pluskid May 12 '11 at 15:26

Or you can check section A.4.1 of the book (link: http://www.stanford.edu/~boyd/cvxbook/bv_cvxbook.pdf) for an alternative solution, where they compute the gradient without using the adjugate.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.