Gradient, Divergence, Curl, and Laplacian in Curvilinear Coordinates
Explanation
In physics, the four operations involving the del operator $\nabla$, Gradient, Divergence, Curl, Laplacian, are very important. Therefore, one must know the operations in three coordinate systems. Of course, this does not mean that you have to memorize them. Since physics study is not about memorizing formulas, they will naturally be memorized as you study, so do not try to memorize them intentionally but instead keep a printout of the formulas with you, or bookmark this page and pull it up when needed.
Formulas
Let $f$ be a scalar function, vector function$\mathbf A$ be $\mathbf A= A_{1}\mathbf{\hat e_{1}}+A_2\mathbf{\hat e_2}+A_{3}\mathbf{\hat e_{3}}$.
$$ \begin{align*} \nabla f &= \mathbf{\hat e_{1}}\frac{1}{h_{1}}\frac{\partial f}{\partial e_{1}}+ \mathbf{\hat e_2}\frac{1}{h_2}\frac{\partial f}{\partial e_2}+\mathbf{\hat e_{3}}\frac{1}{h_{3}}\frac{\partial f}{\partial e_{3}} \\ &= \sum \limits_{i=1}^3 \mathbf{\hat e_{i}}\frac{1}{h_{i}}\frac{\partial f}{\partial e_{i}} \end{align*} $$
$$ \nabla \cdot \mathbf A=\frac{1}{h_{1}h_2h_{3}} \left[ \frac{\partial}{\partial e_{1}} (h_2h_{3}A_{1}) + \frac{\partial}{\partial e_2} (h_{1}h_{3}A_2) + \frac{\partial}{\partial e_{3}} (h_{1}h_2A_{3}) \right] $$
$$ \nabla \times \mathbf A =\frac{1}{h_{1}h_2h_{3}} \begin{vmatrix} h_{1} \mathbf{\hat e_{1}} & h_2 \mathbf{\hat e_2} & h_{3} \mathbf{\hat e_{3}} \\[0.5em] \dfrac{\partial}{\partial e_{1}} & \dfrac{\partial }{\partial e_2} & \dfrac{\partial}{\partial e_{3}} \\[1em] h_{1}A_{1} & h_2A_2 & h_{3}A_{3} \end{vmatrix} $$
$$ \begin{align*} & \nabla \cdot (\nabla f) \\ =&\ \nabla ^2 f \\ =&\ \frac{1}{h_{1}h_2h_{3}} \left[ \frac{\partial }{\partial e_{1}} \left( \frac{h_2h_{3}}{h_{1}} \frac{\partial f}{\partial e_{1}} \right) +\frac{\partial }{\partial e_2} \left( \frac{h_{1}h_{3}}{h_2} \frac{\partial f}{\partial e_2} \right) + \frac{\partial }{\partial e_{3}} \left( \frac{h_{1}h_2}{h_{3}} \frac{\partial f}{\partial e_{3}} \right) \right] \end{align*} $$
The unit vectors and scale factors for each coordinate system are as follows.
Cartesian Coordinates:
$$ \mathbf{\hat{e_{1}}}=\mathbf{\hat{\mathbf{x}}},\quad\mathbf{\hat{e_{2}}}=\mathbf{\hat{\mathbf{y}}},\quad\mathbf{\hat{e_{3}}}=\mathbf{\hat{\mathbf{z}}},\quad h_{1}=1,\quad h_{2}=1,\quad h_{3}=1 $$
Cylindrical Coordinates:
$$ \mathbf{\hat{e_{1}}}=\boldsymbol{\hat \rho},\quad\mathbf{\hat{e_{2}}}=\boldsymbol{\hat \phi},\quad\mathbf{\hat{e_{3}}}=\mathbf{\hat{\mathbf{z}}},\quad h_{1}=1,\quad h_{2}=\rho,\quad h_{3}=1 $$
Spherical Coordinates
$$ \mathbf{\hat{e_{1}}}=\mathbf{\hat r},\quad\mathbf{\hat{e_{2}}}=\boldsymbol{\hat \theta},\quad\mathbf{\hat{e_{3}}}=\boldsymbol{\hat \phi},\quad h_{1}=1,\quad h_{2}=r,\quad h_{3}=r\sin\theta $$
Cartesian Coordinates
- Gradient
$$ \nabla f = \frac{\partial f}{\partial x}\mathbf{\hat{\mathbf{x}} }+ \frac{\partial f}{\partial y}\mathbf{\hat{\mathbf{y}}} + \frac{\partial f}{\partial z}\mathbf{\hat{\mathbf{z}}} $$
- Divergence
$$ \nabla \cdot \mathbf A=\frac{\partial A_{x}}{\partial x}+\frac{\partial A_{y}}{\partial y}+\frac{\partial A_{z}}{\partial z} $$
- Curl
$$ \begin{align*} \nabla \times \mathbf A&=\left(\frac{\partial A_{z}}{\partial y}-\frac{\partial A_{y}}{\partial z} \right) \mathbf{\hat{\mathbf{x}}}+\left(\frac{\partial A_{x}}{\partial z}-\frac{\partial A_{z}}{\partial x} \right) \mathbf{\hat{\mathbf{y}}}+\left(\frac{\partial A_{y}}{\partial x}-\frac{\partial A_{x}}{\partial y} \right) \mathbf{\hat{\mathbf{z}}} \\ &= \begin{vmatrix} \mathbf{\hat{\mathbf{x}}} & \mathbf{\hat{\mathbf{y}}} & \mathbf{\hat{\mathbf{z}}} \\ \dfrac{\partial}{\partial x} & \dfrac{\partial }{\partial y} & \dfrac{\partial}{\partial z} \\ A_{x} & A_{y} & A_{z} \end{vmatrix} \end{align*} $$
- Laplacian
$$ \begin{align*} \nabla \cdot (\nabla f) = \nabla ^2 f &= \left( \frac{\partial}{\partial x}\mathbf{\hat{\mathbf{x}}}+\frac{\partial}{\partial y}\mathbf{\hat{\mathbf{y}}}+\frac{\partial}{\partial z}\mathbf{\hat{\mathbf{z}}} \right) \cdot \left( \frac{\partial f}{\partial x}\mathbf{\hat{\mathbf{x}}}+\frac{\partial f}{\partial y}\mathbf{\hat{\mathbf{y}}}+\frac{\partial f}{\partial z}\mathbf{\hat{\mathbf{z}}} \right) \\ &= \frac{\partial^2 f}{\partial x^2}+\frac{\partial^2 f}{\partial y^2}+\frac{\partial^2 f}{\partial z^2} \end{align*} $$
Cylindrical Coordinates
- Gradient
$$ \nabla f = \frac{\partial f}{\partial \rho}\boldsymbol{\hat \rho} + \frac{1}{\rho}\frac{\partial f}{\partial \phi}\boldsymbol{\hat \phi} + \frac{\partial f}{\partial z}\mathbf{\hat{\mathbf{z}}} $$
- Divergence
$$ \nabla \cdot \mathbf A=\frac{1}{\rho}\frac{\partial (\rho A_\rho)}{\partial \rho}+\frac{1}{\rho}\frac{\partial A_\phi}{\partial \phi}+\frac{\partial A_{z}}{\partial z} $$
- Curl
$$ \begin{align*} \nabla \times \mathbf A&=\left[\frac{1}{\rho}\frac{\partial A_{z}}{\partial \phi}-\frac{\partial A_\phi}{\partial z} \right] \boldsymbol{\hat \rho}+\left[\frac{\partial A_\rho}{\partial z}-\frac{\partial A_{z}}{\partial \rho} \right] \boldsymbol{\hat \phi}+\frac{1}{\rho}\left[\frac{\partial (\rho A_\phi)}{\partial \rho}-\frac{\partial A_\rho}{\partial \phi} \right] \mathrm{\hat{\mathbf{z}}} \\ &= \frac{1}{\rho}\begin{vmatrix} \boldsymbol{\hat \rho} & \rho\boldsymbol{ \hat \phi} & \mathbf{\hat{\mathbf{z}}} \\ \dfrac{\partial}{\partial \rho} & \dfrac{\partial }{\partial \phi} & \dfrac{\partial}{\partial z} \\ A_\rho & \rho A_\phi & A_{z} \end{vmatrix} \end{align*} $$
- Laplacian
$$ \nabla \cdot (\nabla f) = \nabla ^2 f = \frac{1}{\rho}\frac{\partial}{\partial \rho}\left( \rho \frac{\partial f}{\partial \rho} \right) + \frac{1}{\rho^2}\frac{\partial^2 f}{\partial \phi^2} + \frac{\partial^2 f}{\partial z^2} $$
Spherical Coordinates
- Gradient
$$ \nabla f = \frac{\partial f}{\partial r} \mathbf{\hat{\mathbf{r}}} + \frac{1}{r}\frac{\partial f}{\partial \theta} \boldsymbol{\hat{\boldsymbol{\theta}}} + \frac{1}{r\sin\theta}\frac{\partial f}{\partial \phi}\boldsymbol{\hat \phi} $$
- Divergence
$$ \nabla \cdot \mathbf A=\frac{1}{r^2}\frac{\partial (r^2 A_{r})}{\partial r}+\frac{1}{r\sin\theta}\frac{\partial (\sin\theta A_\theta)}{\partial \theta}+\frac{1}{r\sin\theta}\frac{\partial A_\phi}{\partial \phi} $$
- Curl
$$ \begin{align*} \nabla \times \mathbf A &=\frac{1}{r\sin\theta} \left[\frac{\partial (\sin\theta A_\phi)}{\partial \theta}-\frac{\partial A_\theta}{\partial \phi} \right]\mathbf{\hat{\mathbf{r}}}+\frac{1}{r}\left[\frac{1}{\sin\theta} \frac{\partial A_{r}}{\partial \phi}-\frac{\partial (rA_\phi)}{\partial r} \right] \boldsymbol{\hat{\boldsymbol{\theta}}} \\ & \quad+ \frac{1}{r} \left[\frac{\partial (rA_\theta)}{\partial r}-\frac{\partial A_{r}}{\partial \theta} \right]\boldsymbol{\hat \phi} \\ &= \frac{1}{r^2\sin\theta}\begin{vmatrix} \mathbf{\hat{\mathbf{r}}} & r\boldsymbol{\hat{\boldsymbol{\theta}}} & r\sin\theta\boldsymbol{\hat \phi} \\ \dfrac{\partial}{\partial r} & \dfrac{\partial }{\partial \theta} & \dfrac{\partial}{\partial \phi} \\ A_{r} & r A_\theta & r\sin\theta A_\phi \end{vmatrix} \end{align*} $$
- Laplacian
$$ \nabla \cdot (\nabla f) = \nabla ^2 f = \frac{1}{r^2}\frac{\partial}{\partial r} \left( r^2\frac{\partial f}{\partial r} \right) + \frac{1}{r^2\sin\theta}\frac{\partial}{\partial\theta}\left( \sin\theta \frac{\partial f}{\partial \theta} \right) + \frac{1}{r^2\sin^2\theta}\frac{\partial^2 f}{\partial^2 \phi} $$