I sort of asked a version of this question before and it was unclear; try I will now to make an honest attempt to state everything clerly.

I am trying to evaluate the following, namely $\nabla w = \nabla |\vec{a} \times \vec{r}|^n$, where $\vec{a}$ is a constant vector and $\vec{r}$ is the vector $<x_1,x_2,\ldots x_n>$. Now say that I use the chain rule, first say by setting $\vec{u}$ to be equal to the cross product of $\vec{a}$ and $\vec{r}$.

Now here's the part that I'm confused. How do we extend the chain rule over when dealing with the gradient? Do I take $\nabla |\vec{a} \times \vec{r}|^n$ to be equal to $\nabla |\vec{u}|^n$ $\times$ $\nabla (\vec{a} \times \vec{r})$, where $\times$ denotes the cross product?

The first bit $\nabla |\vec{u}|^n$ is easy, it just evaluates to $n|\vec{a} \times \vec{r}|^{n-2} (\vec{a} \times \vec {r})$, remembering that $\vec{u} = \vec{a} \times \vec{r}$.

I am guessing that $\nabla |\vec{a} \times \vec{r}|^n$ $\neq$ $\nabla |\vec{u}|^n$ $\times$ $\nabla (\vec{a} \times \vec{r})$, as to even speak about $\nabla (\vec{a} \times \vec{r})$, i.e. the gradient of a vector we would have to talk about either the cross product or dot product of the gradient and $\nabla (\vec{a} \times \vec{r})$

By the way, I am told the answer given is $\nabla |\vec{a} \times \vec{r}|^n$ = $n|\vec{a} \times \vec{r}|^{n-2} \Big(\vec{a} \times (\vec{r} \times \vec{a})\Big)$.

So let's say that I try a component wise approach, i.e. we look first at $\frac{\partial w}{\partial x_1}$. Then is it true (I could be wrong) that:

$\frac{\partial w}{\partial x_1} = n|\vec{a} \times \vec{r}|^{n-2} \quad \vec{u_1} \times \frac{\partial}{\partial x_1} \Big(\vec{a} \times \vec{r}\Big) = n|\vec{a} \times \vec{r}|^{n-2} \quad \vec{u_1} \times \Big(\vec{a} \times \frac{\partial\vec{r}}{\partial x_1}\Big)$, as $\vec{a}$ is a constant vector? Here $\vec{u_1}$ denotes the first component of the vector $\vec{a} \times \vec{r}$.

I would really aprreciate an interpretation of this, it is just that I am confused about what to take and the meanings of these operations.


Let $f(r)=|a \times r|$. (I'll be lazy and omit the vector arrows.)

Then, to begin with, $\nabla(f(r)^n) = n f(r)^{n-1} \nabla f(r)$ by the chain rule. So it only remains to compute $\nabla f(r)$, and if you can't think of any clever way, then you just do it by brute force in terms of coordinates: take $a=(a_1, a_2, a_3)$ and $r=(x_1,x_2,x_3)$ (the cross products only exists in three dimensions, so your $x_n$ doesn't make sense), compute the components of $u=a \times r=(u_1,u_2,u_3)$, then compute the length $f(r)=\sqrt{u_1^2 + u_2^2 + u_3^2}$, and compute the derivatives of that with respect to $x_1$, $x_2$ and $x_3$. Done!

  • 3
    $\begingroup$ The clever way being to use $|a \times r|^2 = |a|^2 |r|^2 - (a . r)^2$ $\endgroup$ – Robert Israel Apr 11 '11 at 16:44
  • $\begingroup$ @RobertIsrael @HansLundmark Hi guys thanks for your replies. My comment is too long so I've put it as an answer, please have a look at it. $\endgroup$ – user38268 Apr 11 '11 at 22:44

Say I differentiate $|\mathbf{a} \times \mathbf{r}|^2$. Then for the second term it agrees with $\mathbf{a} \times (\mathbf{r} \times \mathbf{a})$, but for the first term there is some confusion. Say I look at the first term of $\nabla |\mathbf{a}|^2|\mathbf{r}|^2$, namely $|\mathbf{a}|^2|\mathbf{r}|^2_{x_1} \mathbf{e_1}$ = $|\mathbf{a}|^2|\mathbf{r}|\mathbf{r}_{x_1} $ $\bullet$ $\mathbf{e_1}$? If it is indeed the dot product then I'm done! Oh by the way $\mathbf{r}_{x_1}$ means the partial derivative of $\mathbf{r}$ with respect to $x_1$.


  • $\begingroup$ If you're not sure how to do it the clever way, you should fall back to the brute force method. ;) Anyway, your formula is not correct. The term you're asking about is $$\frac{\partial}{\partial x_1}(|a|^2 |r|^2) e_1 = 2 |a|^2 x_1 e_1 = 2 |a|^2 (r \cdot e_1) e_1.$$ And if you don't know why $\frac{\partial}{\partial x_1}(|r|^2) = 2 x_1$, then write it out in coordinates, $|r|^2=\sqrt{\dots}^2$, so that you can see what's going on. $\endgroup$ – Hans Lundmark Apr 12 '11 at 6:00
  • $\begingroup$ @HansLundmark sorry my bad I went a step too quick. $|r|$^2 is just like you said $x_1^2 + x_2^2 \ldots x_n^2$ which when differentiated w.r.t. $x_1$ gives $2x_1$, thanks so much for your help. $\endgroup$ – user38268 Apr 12 '11 at 6:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy