# $(\textbf{r}\times\nabla)^{2}$ in spherical coordinates

In polar coordinates, $$\nabla = \partial_{r} \hat{\textbf{r}} +\frac{1}{r} \partial_{\theta} \hat{\boldsymbol{\theta}} +\frac{1}{r\sin(\theta)} \partial_{\phi} \hat{\boldsymbol{\phi}}$$ such that $$\textbf{r} = r \hat{\textbf{r}}$$. Therefore, $$\textbf{r} \times \nabla = \partial_{\theta} \hat{\boldsymbol{\phi}} -\frac{1}{\sin(\theta)} \partial_{\phi} \hat{\boldsymbol{\theta}}.$$ When I try to evaluate $$(\textbf{r} \times \nabla) \cdot (\textbf{r} \times \nabla)$$, I treat it as a column vector in the polar basis to obtain $$(\textbf{r} \times \nabla) \cdot (\textbf{r} \times \nabla) = \partial^{2}_{\theta} +\frac{1}{\sin^{2}(\theta)} \partial^{2}_{\phi}.$$ However, I know this isn’t correct, and that I should get $$(\textbf{r} \times \nabla) \cdot (\textbf{r} \times \nabla) = \partial^{2}_{\theta} +\frac{1}{\tan(\theta)} \partial_{\theta} +\frac{1}{\sin^{2}(\theta)} \partial^{2}_{\phi}.$$ But I can’t see where my approach is going wrong. I think it has something to do with the fact that, in cartesian coordinates, the spherical basis vectors are given by $$\hat{\textbf{r}} = \begin{pmatrix} \sin(\theta) \cos(\phi) \\ \sin(\theta) \sin(\phi) \\ \cos(\theta) \end{pmatrix}, \quad \hat{\boldsymbol{\theta}} = \begin{pmatrix} \cos(\theta) \cos(\phi) \\ \cos(\theta) \sin(\phi) \\ -\sin(\theta) \end{pmatrix}, \quad \hat{\boldsymbol{\phi}} = \begin{pmatrix} -\sin(\phi) \\ \cos(\phi) \\ 0 \end{pmatrix}$$ such that $$\partial_{\phi} \hat{\boldsymbol{\theta}} = \cos(\theta) \hat{\boldsymbol{\phi}}$$ but still can’t get the correct result. So, my question is, why is my approach wrong?

$$\renewcommand\vec\mathbf \newcommand\vecg\boldsymbol$$
Consider the expression $$(\vec r\times\nabla)\cdot(\vec r\times\nabla)f$$ for some function $$f$$. The intent of such an expression is usually to compute $$g = (\vec r\times\nabla)f$$, then compute $$h = (\vec r\times\nabla)\cdot g$$. But $$g$$ contains coordinate dependence that does not come from $$f$$, and instead comes from $$\vec r$$ as well as the coordinate expression for $$\nabla$$. What you did is equivalent to ignoring all that extra coordinate dependence and only differentiating the coordinate dependence of $$f$$. What we should write is \begin{aligned} &(\vec r\times\nabla)\cdot(\vec r\times\nabla)f \\ &\quad= \begin{aligned}[t] &\left(\hat{\vecg\phi}\dot\partial_\theta - \frac{\hat{\vecg\theta}}{\sin\theta}\dot\partial_\phi\right)\cdot\left(\dot{\hat{\vecg\phi}}\check\partial_\theta - \frac{\dot{\hat{\vecg\theta}}}{\sin\dot\theta}\check\partial_\phi\right)\check f \\ &+ \left(\hat{\vecg\phi}\dot\partial_\theta - \frac{\hat{\vecg\theta}}{\sin\theta}\dot\partial_\phi\right)\cdot\left(\hat{\vecg\phi}\check\partial_\theta - \frac{\hat{\vecg\theta}}{\sin\dot\theta}\check\partial_\phi\right)\dot{\check f} \end{aligned}\end{aligned} The dots $$\dot\partial$$ and checks $$\check\partial$$ specify exactly what the derivatives are diffentiating; the above expression stems from a kind of generalized product rule. The second term is the one you've already derived: \begin{aligned} &\left(\hat{\vecg\phi}\dot\partial_\theta - \frac{\hat{\vecg\theta}}{\sin\theta}\dot\partial_\phi\right)\cdot\left(\hat{\vecg\phi}\check\partial_\theta - \frac{\hat{\vecg\theta}}{\sin\dot\theta}\check\partial_\phi\right)\dot{\check f} \\ &\quad = \partial_\theta^2f + \frac1{\sin^2\theta}\partial_\phi^2f \end{aligned} The first term expands to $$\hat{\vecg\phi}\cdot(\partial_\theta\hat{\vecg\phi})\partial_\theta f - \frac{\hat{\vecg\theta}}{\sin\theta}\cdot(\partial_\phi\hat{\vecg\phi})\partial_\theta f - \hat{\vecg\phi}\cdot\left[\partial_\theta\frac{\hat{\vecg\theta}}{\sin\theta}\right]\partial_\phi f + \frac{\hat{\vecg\theta}}{\sin\theta}\cdot\left[\partial_\phi\frac{\hat{\vecg\theta}}{\sin\theta}\right]\partial_\phi f.$$ Exploiting facts about the orthogonality of derivatives of $$\hat{\vecg\phi}$$ and $$\hat{\vecg\theta}$$ leaves only the second term, which expands to $$-\frac{\hat{\vecg\theta}}{\sin\theta}\cdot(\partial_\phi\hat{\vecg\phi})\partial_\theta f = \frac1{\tan\theta}\partial_\theta f$$ as desired.
Rather than using the "generalized product rule" like I did above, you could also just compute $$g = (\vec r\times\nabla)f$$ and then $$(\vec r\times\nabla)\cdot g$$ in sequence.
One final note. There is another direction we could take. There is a vector identity $$(a\times b)\cdot(c\times d) = (a\cdot c)(b\cdot d) - (b\cdot c)(a\cdot d).$$ Properly keeping track of what we're differentiating, we can exploit this to get \begin{aligned} &(\vec r\times\nabla)\cdot(\vec r\times\nabla)f \\ &\quad= (\vec r\times\dot\nabla)\cdot(\dot{\vec r}\times\check\nabla)\check f + (\vec r\times\dot\nabla)\cdot(\vec r\times\check\nabla)\dot{\check f} \\ &\quad=\begin{aligned}[t] &(\vec r\cdot\dot{\vec r})(\dot\nabla\cdot\check\nabla)\check f - (\dot\nabla\cdot\dot{\vec r})(\vec r\cdot\check\nabla)\check f \\ &+ (\vec r\cdot\vec r)(\dot\nabla\cdot\check\nabla)\dot{\check f} - (\dot\nabla\cdot\vec r)(\vec r\cdot\check\nabla)\dot{\check f} \end{aligned} \\ &\quad= \vec r\cdot\nabla f - 3\vec r\cdot\nabla f + r^2\nabla^2 f - (\vec r\cdot\dot\nabla)^2\dot f \\ &\quad= -2\vec r\cdot\nabla f + r^2\nabla^2 f - (\vec r\cdot\dot\nabla)^2\dot f. \end{aligned} In any coordinate system where $$r$$ is orthogonal to the other coordinates, we can write $$(\vec r\times\nabla)^2f = r^2\nabla^2f - r^2\partial _r^2f - 2r\partial_rf.$$ Expanding this expression using the well-known form of the Laplacian would also give the desired result.