# Gradient of a function and inverse of metric

Having some knowledge in differential geometry on $\mathbb{R}^n$, I'm reading a book on Information geometry by Amari. Let $S=\{p_{\theta}\}$, $\theta=(\theta_1,\dots,\theta_n)$ be an $n$-dimensional manifold parameterized by $\theta$. At some point the author writes, for a (differentiable) funtion $f:S\to \mathbb{R}$, $$(\text{grad}~f)_p=\sum_{i,j}\left(\frac{\partial f}{\partial \theta_i}\right)_pg^{i,j}\left(\frac{\partial}{\partial \theta_i}\right)_p,$$ where $[g^{i,j}]$ is the inverse of the Riemannian metric $[g_{i,j}]=[\langle \frac{\partial}{\partial \theta_i},\frac{\partial}{\partial \theta_j}\rangle]$. Can someone explain how does one arrive at this expression? Thank you.

• Are you sure of your formula? The gradient is a vector, so you should specify a component on the l.h.s. and do not sum over 2 indices on the r.h.s. (Amari's book is great) – Avitus Dec 11 '13 at 10:42
• @Avitus Yes, this is how it is given in the book. I too had the same doubt. In the next line he writes $\|(df)_p\|_p^2=\|(\text{grad}~f)_p\|_p^2=(\partial_if)_p(\partial_jf)_pg^{i,j}(p)$. I don't understand this as well. – Ashok Dec 11 '13 at 10:46
• I see...that object is not the gradient of $f$ at $p$, understood as the vector $\nabla(f)^k:=\sum_i g^{ki}\frac{\partial f}{\partial \theta^i}$. It is $\operatorname{grad}(f):=\sum_k \nabla(f)^k\frac{\partial}{\partial\theta_k}$, instead (i.e. an element of $T_pM$ with components given by the gradient of $f$ at $p$ components)... – Avitus Dec 11 '13 at 10:52
• ...the identity involving the norms comes from $\|v\|^2:=\langle v,v\rangle$, where the inner product is defined using the Riemannian metric as you stated in the question. – Avitus Dec 11 '13 at 10:55
• @Avitus: I don't understand. How does the inverse of the metric come into picture? Can you explain in detail in the answer? – Ashok Dec 11 '13 at 10:58

As you mentioned, the gradient of a function $f$ is defined as its dual vector of $df$, we can immediately write $$(\mathrm{grad} f(p))^i=g^{ij}(df(p))_j$$
Proof: $$g_{ij}X^j=\left<\partial_i,\partial_j\right>X^j=\left<\partial_i,X^j\partial_j\right>=\left<\partial_i,X\right>=X_i$$
And we know $df(p)_j=\partial_j f(p)$, so it follows $$\mathrm{grad} f(p)=(\mathrm{grad} f(p))^i\partial_i=g^{ij}\partial_jf(p)\partial_i$$
• Can you elaborate bit on how you get $(\mathrm{grad} f(p))^i=g^{ij}(df(p))_j$? It should be simple, I presume. So give me only a hint! – Ashok Dec 11 '13 at 12:09
• Sorry, still I'm not getting the appearence of the inverse $g^{i,j}$. – Ashok Dec 11 '13 at 12:32
• @Ashok $g^{ij}$ is the inverse of $g_{ij}$ – Shuchang Dec 11 '13 at 12:33
• Yes, I know. But, will this equation $g_{ij}X^j=\langle\partial_i,\partial_j\rangle X^j=\langle\partial_i,X^j\partial_j\rangle=\langle\partial_i,X\rangle=X_i$ be true even if we replace $g_{i,j}$ by its inverse $g^{i,j}$? I'm confused. – Ashok Dec 11 '13 at 12:44