# Partial derivative of inner product in Einstein Notation

Tags:
1. Feb 3, 2017

### Loberg

1. The problem statement, all variables and given/known data
Can someone please check my working, as I am new to Einstein notation:
Calculate $$\partial^\mu x^2.$$
2. Relevant equations
3. The attempt at a solution

\begin{align*}
\partial^\mu x^2 &= \partial^\mu(x_\nu x^\nu) \\
&= x^a\partial^\mu x_a + x_b\partial^\mu x^b \ \ \text{(by product rule and relabelling indices)} \\
&=x^a\delta_\mu^a + x_b\delta_\mu^b \\
&=2x_\mu.
\end{align*}
I'm not sure is the expression in the second term of the second line is correct, as the partial is with respect to the covariant vector but the argument is a contravariant vector.

2. Feb 4, 2017

### Fightfish

A useful tip to keep in mind is that indices keep their position (upper or lower) unless they are raised or lowered by a metric. So the equality that you wrote,
$$x^a\partial^\mu x_a + x_b\partial^\mu x^b =x^a\delta_\mu^a + x_b\delta_\mu^b,$$ is clearly not correct.

Firstly, $\partial^{\mu} x_{a} = \delta_{a}^{\mu}$ (notice that $\mu$ stays upper and $a$ stays lower).

Next, you cannot simply perform the derivative $\partial^{\mu} x^{b}$ directly because the derivative is with respect to the contravariant component. So the correct way to go about doing it is to rewrite $x^{b} = g^{cb} x_{c}$, so that $\partial^{\mu} x^{b} = g^{cb} \partial^{\mu} x_{c} +x_{c} \partial^{\mu}g^{cb}$. In a cartesian coordinate system, the metric is just identity and so we get the same result as you do.