Let $\Bbb S_n^{++}$ denote the set of $n \times n$ symmetric positive definite matrices over $\Bbb R$. Let scalar field $f : \Bbb S_n^{++} \to \Bbb R$ be defined by $$ f (X) := \frac1{\sqrt{\det(X)}} $$ Find the gradient $\nabla_X f$.

What I got was

$$\nabla_X f (X) = -\frac12\det(X)^{-\frac32} \operatorname{tr} \left( X^{-1} \right)$$

Is it correct? Full explanation, please.

  • $\begingroup$ Welcome to MSE. Your question is phrased as an isolated problem, without any further information or context. This does not match many users' quality standards, so it may attract downvotes, or be closed. To prevent that, please edit the question. This will help you recognize and resolve the issues. Concretely: please provide context, and include your work and thoughts on the problem. These changes can help in formulating more appropriate answers. $\endgroup$ Nov 23, 2022 at 11:58
  • $\begingroup$ Jacobi's formula $\endgroup$ Nov 23, 2022 at 12:11

1 Answer 1


The gradient of the determinent is well known $$\eqalign{ \def\qiq{\quad\implies\quad} \def\LR#1{\left(#1\right)} \def\p{\partial}\def\grad#1#2{\frac{\p #1}{\p #2}} \def\gradLR#1#2{\LR{\grad{#1}{#2}}} \def\fracLR#1#2{\LR{\frac{#1}{#2}}} h &= \det(X) \qiq\grad hX = hX^{-T} \qquad\qquad\quad \\ }$$ Using this result, the gradient of your function becomes $$\eqalign{ f &= h^{-1/2} \qiq \grad fX &= -\frac{1}2\:h^{-3/2}\gradLR hX \\ &&= -\frac 12\:h^{-1/2}X^{-T} \\ }$$ The result that you derived is incorrect because it is scalar-valued, whereas a scalar-by-matrix gradient must be matrix-valued.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .