Chapter 1: Differential Calculus


Section 2.1: Ordinary Derivatives

I will assume that you understand how to operate with derivatives. For more information on the topic, I recommend visiting Paul's Notes. It's a wonderful resource on all college level calculus related topics.


Section 2.2: Gradient

Problem: How do we describe how quickly the value of a three variable function changes as we move in 3D space? We can define temperature in a room as \(T(x,y,z)\) where this function tells the temperature as the function of position.
This is more complicated, because we need to account for direction of motion. This can be resolved by taking a partial derivative in each direction of motion.

\(dT=(\frac{\partial{T}}{\partial{x}}dx) + (\frac{\partial{T}}{\partial{y}}dy) + (\frac{\partial{T}}{\partial{z}}dz) \Rightarrow \underbrace{(\frac{\partial{T}}{\partial{x}}\hat{x} + \frac{\partial{T}}{\partial{y}}\hat{y} + \frac{\partial{T}}{\partial{z}}\hat{z})}_{\nabla{T}(gradient\ of\ T)} \cdot \underbrace{(dx\hat{x}+dy\hat{y}+dz\hat{z})}_{d\overrightarrow{\boldsymbol{l}}} = \nabla{T} \cdot d\overrightarrow{\boldsymbol{l}} \\ dT = \nabla{T} \cdot d\overrightarrow{\boldsymbol{l}} = |\nabla{T}||d\overrightarrow{\boldsymbol{l}}|\cos{\theta}\)

Gradient \(\nabla{T}\) points in the direction of maximum increase of the function T.
The magnitude of \(|\nabla{T}|\) gives the slope (rate of increase) along this maximal direction.

Relevant problems:

1.11(C): Find gradient of \(f(x,y,z)=e^x\sin(y)\ln(z)\)

Take partial derivative with respect to each coordiante.

\(\nabla{f}=(\frac{\partial{f}}{\partial{x}}\hat{x} + \frac{\partial{f}}{\partial{y}}\hat{y} + \frac{\partial{f}}{\partial{z}}\hat{z})= e^x\sin(y)\ln(z)\hat{x} + e^x\cos(y)\ln(z)\hat{y} + e^x\sin(y)\frac{1}{z}\hat{z}\)

1.13: If \(\overrightarrow{\boldsymbol{r}}_{sep}\) is a separation vector from \(x', y', z'\) to \(x, y, z\) and \(\overrightarrow{r_{sep}}\) its magnitude find:
(a) \(\nabla{((\overrightarrow{r_{sep}})^2)}=2\overrightarrow{\boldsymbol{r}}_{sep}\)
(b) \(\nabla{\frac{1}{\overrightarrow{r_{sep}}}}=-\frac{\hat{\boldsymbol{r}}_{sep}}{(\overrightarrow{r_{sep}})^2}\)
(c) What is general formula for \(\nabla{((\overrightarrow{r_{sep}})^n)}\)?

Take partial derivative with respect to each coordiante.

\( a)\nabla{((\overrightarrow{r_{sep}})^2)}=\nabla{(x-x')^2 + (y-y')^2 + (z-z')^2}=2(x-x')\hat{x} + 2(y-y')\hat{y} + 2(z-z')\hat{z}=2\overrightarrow{\boldsymbol{r}}_{sep}\)
\( b) \nabla{\frac{1}{\overrightarrow{r_{sep}}}}=\nabla{\frac{1}{\sqrt{(x-x')^2 + (y-y')^2 + (z-z')^2}}}=\frac{ -\frac{1}{2}*(\overrightarrow{r_{sep}})^{-1/2}*2(x-x')\hat{x} + -\frac{1}{2}*(\overrightarrow{r_{sep}})^{-1/2}*2(y-y')\hat{y} + -\frac{1}{2}*(\overrightarrow{r_{sep}})^{-1/2}*2(z-z')\hat{z}}{(x-x')^2 + (y-y')^2 + (z-z')^2} = \\ =\frac{ -(\overrightarrow{r_{sep}})^{-1/2}*(x-x')\hat{x} + -(\overrightarrow{r_{sep}})^{-1/2}*(y-y')\hat{y} + -(\overrightarrow{r_{sep}})^{-1/2}*(z-z')\hat{z}}{(x-x')^2 + (y-y')^2 + (z-z')^2}=\frac{ -(\overrightarrow{r_{sep}})^{-1/2}*[(x-x')\hat{x} + (y-y')\hat{y} + (z-z')\hat{z}]}{(x-x')^2 + (y-y')^2 + (z-z')^2} = \frac{ -(\overrightarrow{r_{sep}})^{-1/2}*\overrightarrow{\boldsymbol{r}}_{sep}}{(x-x')^2 + (y-y')^2 + (z-z')^2} = -\frac{\overrightarrow{\boldsymbol{r}}_{sep}}{((x-x')^2 + (y-y')^2 + (z-z')^2)^{3/2}}=-\frac{\hat{\boldsymbol{r}}_{sep}}{(\overrightarrow{r_{sep}})^2}\) c) Chain rule: Fox x => \( \frac{\partial}{\partial{x}}\overrightarrow{r_{sep}^n}=n*\overrightarrow{r_{sep}^{n-1}}*\underbrace{\frac{\partial{\overrightarrow{r_{sep}}}}{\partial{x}}}_{\hat{x}}=n*\overrightarrow{r_{sep}^{n-1}}*\hat{x}\)

1.14: Show that gradient of a function of two variables \( \nabla{f}=\frac{\partial}{\partial{y}}\hat{y} + \frac{\partial}{\partial{z}}\hat{z}\) transforms as a vector under rotation.

Chain Rule: \(\require{enclose} \frac{\partial{f(y,z)}}{\partial{\bar{y}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{{\frac{\partial{y}}{\partial{\bar{y}}}}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{y}}}}, \frac{\partial{f(y,z)}}{\partial{\bar{z}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{{\frac{\partial{y}}{\partial{\bar{z}}}}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{z}}}},\)
Given system of equations for transformation from y,z to \(\bar{y}, \bar{z}\) from Section 1.5
\( \left\{ \begin{array}{c} \bar{y}=y\cos{\phi}+z\sin{\phi} \\ \bar{z}=-y\sin{\phi}+z\cos{\phi} \end{array} \right. \)
Define y and z as functions of \(\bar{y},\bar{z}\) to compute derivatives in red. Once derivatives in red are computed, the partial derivatives can be expressed as a system of equations that will look just like the system of equations in Section 1.5.

Chain Rule: \(\require{enclose} \frac{\partial{f(y,z)}}{\partial{\bar{y}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{{\frac{\partial{y}}{\partial{\bar{y}}}}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{y}}}}, \frac{\partial{f(y,z)}}{\partial{\bar{z}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{{\frac{\partial{y}}{\partial{\bar{z}}}}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{z}}}},\)
Need to Define y and z as functions of \(\bar{y},\bar{z}\). Otherwise we cannot compute derivatives highlighted in red. \( \left\{ \begin{array}{c} \bar{y}=y\cos{\phi}+z\sin{\phi} \\ \bar{z}=-y\sin{\phi}+z\cos{\phi} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \frac{\bar{y}}{\cos{\phi}}=y+z\tan{\phi} \\ \frac{\bar{z}}{\cos{\phi}}=-y\tan{\phi}+z \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \bar{y}\sec{\phi}=y+z\tan{\phi} \\ \bar{z}\sec{\phi}=-y\tan{\phi}+z \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z = \bar{z}\sec{\phi} + y\tan{\phi} \end{array} \right. \)
Substitute in order to express y and z in terms of \(\bar{y}, \bar{z}\)
\( \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z = \bar{z}\sec{\phi} + \tan{\phi}(\bar{y}\sec{\phi} - z\tan{\phi}) \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z = \bar{z}\sec{\phi} + \bar{y}\tan{\phi}\sec{\phi} - z\tan^2{\phi} \end{array} \right. \Longrightarrow \ \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z(1 + \tan^2{\phi}) = \bar{z}\sec{\phi} + \bar{y}\tan{\phi}\sec{\phi} \end{array} \right. \Longrightarrow \\ \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z(\frac{\sin^2{\phi} + \cos^2{\phi}}{\cos^2{\phi}}) = \bar{z}\sec{\phi} + \bar{y}\frac{\sin{\phi}}{\cos^2{\phi}} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z(\frac{1}{\cos^2{\phi}}) = \bar{z}\sec{\phi} + \bar{y}\frac{\sin{\phi}}{\cos^2{\phi}} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - z\tan{\phi} \\ z = \bar{z}\cos{\phi} + \bar{y}\sin{\phi} \end{array} \right. \)
Substitute resulting z into function for y
\( \left\{ \begin{array}{c} y = \bar{y}\sec{\phi} - \tan{\phi}(\bar{z}\cos{\phi} + \bar{y}\sin{\phi}) \\ z = \bar{z}\cos{\phi} + \bar{y}\sin{\phi} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}(\sec{\phi} - \sin{\phi}\tan{\phi}) - \bar{z}\sin{\phi} \\ z = \bar{z}\cos{\phi} + \bar{y}\sin{\phi} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} y = \bar{y}\cos{\phi} - \bar{z}\sin{\phi} \\ z = \bar{z}\cos{\phi} + \bar{y}\sin{\phi} \end{array} \right. \)
Thus apply chain rule, calculating known partial derivatives. We can express the transformation in the same form as was shown in Section 1.5 of the book.
\( \left\{ \begin{array}{c} \frac{\partial{f(y,z)}}{\partial{\bar{y}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{\cos{\phi}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\sin{\phi}} \\ \frac{\partial{f(y,z)}}{\partial{\bar{z}}}=\frac{\partial{f}}{\partial{y}} \enclose{box}[mathcolor="red"]{-\sin{\phi}} +\frac{\partial{f}}{\partial{z}} \enclose{box}[mathcolor="red"]{\cos{\phi}} \end{array} \right. \Longrightarrow \begin{pmatrix} \frac{\partial{f(y,z)}}{\partial{\bar{y}}} \\ \frac{\partial{f(y,z)}}{\partial{\bar{z}}} \\ \end{pmatrix} = \begin{pmatrix} \cos\phi & \sin\phi \\ -\sin\phi & \cos\phi \\ \end{pmatrix} \begin{pmatrix} \frac{\partial{f(y,z)}}{\partial{y}} \\ \frac{\partial{f(y,z)}}{\partial{z}} \\ \end{pmatrix} \)


Section 2.3: Del Operator

Del is a vector operator that acts upon T.

\(\nabla = \hat{x}\frac{\partial{}}{\partial{x}} + \hat{y}\frac{\partial{}}{\partial{y}} +\hat{z}\frac{\partial{}}{\partial{z}}\)

Ordinary vector \(\boldsymbol{A}\) can multiply:

  1. Multiply a scalar a: \( \boldsymbol{A}a \)
  2. Multiply another vector \(\boldsymbol{B}\), via dot product: \(\boldsymbol{A} \cdot \boldsymbol{B}\)
  3. Multiply another vector \(\boldsymbol{B}\), via cross product: \(\boldsymbol{A} \times \boldsymbol{B}\)

Operator \(\nabla \) can act:

  1. On scalar function T: \(\nabla{T}\) (the gradient)
  2. On vector function \(\boldsymbol{v}\), via dot product: \(\nabla \cdot \boldsymbol{v}\) (the divergence)
  3. On vector function \(\boldsymbol{v}\), via cross product: \(\nabla \times \boldsymbol{v}\) (the curl)

Section 2.4: Divergence

Definition of divergence: \(\nabla \cdot \boldsymbol{v} = (\hat{x}\frac{\partial{}}{\partial{x}} + \hat{y}\frac{\partial{}}{\partial{y}} +\hat{z}\frac{\partial{}}{\partial{z}}) \cdot (v_x\hat{x} + v_y\hat{y} + v_z\hat{z}) = \frac{\partial{v_x}}{\partial{x}} + \frac{\partial{v_y}}{\partial{y}} + \frac{\partial{v_z}}{\partial{z}}\) (scalar)

Geometric definition: How much vector sperads out from the point in question. \(V\) is not a constant vector, it is a vector function, and thus value of divergence will also be a function, whose value can differ for each point in space.

Relevant problems:
1.16: Compute divergence: \(v = \frac{\hat{r}}{r^2}\). Sketch the function

Expand \(\hat{r}\) and \(r^2\) in terms of x, y and z. Then find divergence of the resulting function.

  1. \( \nabla{\frac{\hat{r}}{r^2}} = \nabla{ \frac{ \frac{x\hat{x} + y\hat{y} + z\hat{z}}{\sqrt{ x^2 + y^2 + z^2 }} }{x^2 + y^2 + z^2}} = \nabla{\frac{x\hat{x} + y\hat{y} + z\hat{z}}{[x^2 + y^2 + z^2]^\frac{3}{2}}}\)
  2. To take a derivative I use: \( \frac{d}{dx}(\frac{hi}{lo}) = \frac{lo * dhi - hi * dlo}{lo^2}\)
  3. Take a derivative with respect to x: \(\nabla_x = \frac{ [x^2 + y^2 + z^2]^\frac{3}{2} * 1 - x\hat{x} * \frac{3}{2} *2x * [x^2 + y^2 + z^2]^\frac{1}{2} }{[x^2 + y^2 + z^2]^3} = \frac{ [x^2 + y^2 + z^2]^\frac{3}{2} - 3x^2 * [x^2 + y^2 + z^2]^\frac{1}{2} }{[x^2 + y^2 + z^2]^3} \)
  4. Apply to y and z
  5. Combine and replace \([x^2 + y^2 + z^2]\) with \(r^2\)
  6. \( \nabla{\frac{\hat{r}}{r^2}} = \frac{ [r^2]^\frac{3}{2} - 3x^2 * [r^2]^\frac{1}{2} + [r^2]^\frac{3}{2} - 3y^2 * [r^2]^\frac{1}{2} + [r^2]^\frac{3}{2} - 3z^2 * [r^2]^\frac{1}{2}}{[r^2]^3} = \frac{ r^3 - 3x^2 * r + r^3 - 3y^2 * r + r^3 - 3z^2 * r}{r^6} = \frac{ r^3 - 3r * (x^2 + y^2 + z^2)}{r^6} = \frac{ 3r^3 - 3r * r}{r^6} = 3r^{-3} - 3r^{-3} =0\)
    Diverges from the origin. Divergence at origin is \(\infty \), 0 everywhere else
1.17: Compute divergence: \(v = \frac{\hat{r}}{r^2}\). Sketch the function

Analogous to problem 1.14, by transformation of coordinates. Refer to Section 1.5.
We have a vector function \(v(y, z)\) transformed into \( \begin{pmatrix} \bar{v_y} \\ \bar{v_z} \\ \end{pmatrix} = \begin{pmatrix} \cos\phi & \sin\phi \\ -\sin\phi & \cos\phi \\ \end{pmatrix} \begin{pmatrix} v_y \\ v_z \\ \end{pmatrix} \).Find partial derivatives with respect to \(\bar{y}\) and \(\bar{z}\).
You will use chain rule in a similar fashion as in problem 1.14. To find the necessary partial derivatives you will first need to rearrange the system of equations analogous to 1.14.
In short, you mush show that \(\frac{\partial{\bar{v_y}}}{\partial{\bar{y}}} + \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}} = \frac{\partial{v_y}}{\partial{y}} + \frac{\partial{v_z}}{\partial{z}} \)

Given a transformed function we can rearrange the same way as in problem 1.14 \( \left\{ \begin{array}{c} \bar{v_y}=v_y\cos{\phi}+v_z\sin{\phi} \\ \bar{v_z}=-v_y\sin{\phi}+v_z\cos{\phi} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \bar{v_y}=\bar{v_y}\cos{\phi}-\bar{v_z}\sin{\phi} \\ \bar{v_z}=\bar{v_y}\sin{\phi}+\bar{v_z}\cos{\phi} \end{array} \right. \)
Apply chain rule as in problem 1.14
\( \left\{ \begin{array}{c} \frac{\partial{\bar{v_y}}}{\partial{\bar{y}}}=\frac{\partial{\bar{v_y}}}{\partial{y}} \enclose{box}[mathcolor="red"]{\frac{\partial{y}}{\partial{\bar{y}}}} +\frac{\partial{\bar{v_y}}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{y}}}} \\ \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}}=\frac{\partial{\bar{v_z}}}{\partial{y}} \enclose{box}[mathcolor="red"]{\frac{\partial{y}}{\partial{\bar{z}}}} +\frac{\partial{\bar{v_z}}}{\partial{z}} \enclose{box}[mathcolor="red"]{\frac{\partial{z}}{\partial{\bar{z}}}} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \frac{\partial{\bar{v_y}}}{\partial{\bar{y}}}=\frac{\partial{\bar{v_y}}}{\partial{y}} \enclose{box}[mathcolor="red"]{\cos{\phi}} +\frac{\partial{\bar{v_y}}}{\partial{z}} \enclose{box}[mathcolor="red"]{\sin{\phi}} \\ \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}}=\frac{\partial{\bar{v_z}}}{\partial{y}} \enclose{box}[mathcolor="red"]{-\sin{\phi}} +\frac{\partial{\bar{v_z}}}{\partial{z}} \enclose{box}[mathcolor="red"]{\cos{\phi}} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \frac{\partial{\bar{v_y}}}{\partial{\bar{y}}}=\frac{\partial{v_y}}{\partial{y}}(\cos{\phi}) \enclose{box}[mathcolor="red"]{\cos{\phi}} +\frac{\partial{v_z}}{\partial{z}}(\sin{\phi}) \enclose{box}[mathcolor="red"]{\sin{\phi}} \\ \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}}=\frac{\partial{v_z}}{\partial{y}}(-\sin{\phi}) \enclose{box}[mathcolor="red"]{-\sin{\phi}} +\frac{\partial{v_z}}{\partial{z}}(\cos{\phi}) \enclose{box}[mathcolor="red"]{\cos{\phi}} \end{array} \right. \Longrightarrow \left\{ \begin{array}{c} \frac{\partial{\bar{v_y}}}{\partial{\bar{y}}}=\frac{\partial{v_y}}{\partial{y}} \cos^2{\phi} +\frac{\partial{v_z}}{\partial{z}} \sin^2{\phi} \\ \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}}=\frac{\partial{v_y}}{\partial{y}} \sin^2{\phi} +\frac{\partial{v_z}}{\partial{z}} \cos^2{\phi} \end{array} \right. \Longrightarrow \)
Divergence in old coordinates: \(\nabla \cdot v_{x,y} = \frac{\partial{v_y}}{\partial{y}} + \frac{\partial{v_z}}{\partial{z}}\)
Divergence in new coordinates: \(\nabla \cdot \bar{v_{x,y}} = \frac{\partial{\bar{v_y}}}{\partial{\bar{y}}} + \frac{\partial{\bar{v_z}}}{\partial{\bar{z}}} = \frac{\partial{v_y}}{\partial{y}} \cos^2{\phi} +\frac{\partial{v_z}}{\partial{z}} \sin^2{\phi} + \frac{\partial{v_y}}{\partial{y}} \sin^2{\phi} +\frac{\partial{v_z}}{\partial{z}} \cos^2{\phi} = \frac{\partial{v_y}}{\partial{y}} (\cos^2{\phi} + \sin^2{\phi}) + \frac{\partial{v_z}}{\partial{z}} (\cos^2{\phi} + \sin^2{\phi}) = \frac{\partial{v_y}}{\partial{y}} + \frac{\partial{v_z}}{\partial{z}} = \nabla \cdot v_{x,y}\)

Section 2.5: Curl

Definition of curl: \(\nabla \times \boldsymbol{v} = \begin{vmatrix} \hat{\boldsymbol{\imath}} & \hat{\boldsymbol{\jmath}} & \hat{\boldsymbol{k}} \\ \frac{\partial{}}{\partial{x}} & \frac{\partial{}}{\partial{y}} & \frac{\partial{}}{\partial{z}} \\ v_x & v_y & v_z \end{vmatrix} = \boldsymbol{\hat{x}}(\frac{\partial{v_z}}{\partial{y}} - \frac{\partial{v_y}}{\partial{z}}) - \boldsymbol{\hat{y}}(\frac{\partial{v_z}}{\partial{x}} - \frac{\partial{v_x}}{\partial{z}}) + \boldsymbol{\hat{z}}(\frac{\partial{v_y}}{\partial{x}} - \frac{\partial{v_x}}{\partial{y}}) \)
If you are uncomfortable with the notion of curl, I highly recommend heading over to Paul's Notes for more information.

Geometric definition: How much vector swirls around a given point. If we were to model a hurricane, the eye of a hurricane would be the point of maximum curl.


Section 2.6: Product Rules

Simple rules for gradients, divergence and curl:

  1. \(\nabla{f+g} = \nabla{f} +\nabla{g}\)
  2. \(\nabla \cdot (\boldsymbol{A} + \boldsymbol{B})=\nabla \cdot \boldsymbol{A} + \nabla \cdot \boldsymbol{B}\)
  3. \(\nabla \times (\boldsymbol{A} + \boldsymbol{B})= \nabla \times \boldsymbol{A} +\nabla \times \boldsymbol{B}\)
  4. \(\nabla{kf}=k \nabla{f}\)
  5. \(\nabla \cdot (k\boldsymbol{A}) = k(\nabla \cdot \boldsymbol{A})\)
  6. \(\nabla \times (k\boldsymbol{A}) = k(\nabla \times \boldsymbol{A}\)

Product rules:

  1. \(\nabla{fg} = f(\nabla{g}) + g(\nabla{f})\)
  2. \(\nabla(\boldsymbol{A} \cdot \boldsymbol{B})=\boldsymbol{A} \times (\nabla \times \boldsymbol{B}) + \boldsymbol{B} \times (\nabla \times \boldsymbol{B}) + (\boldsymbol{A} \cdot \nabla)\boldsymbol{B} + (\boldsymbol{B} \cdot \nabla)\boldsymbol{A}\)
  3. \(\nabla \cdot (f\boldsymbol{A}) = f(\nabla \cdot \boldsymbol{A}) + \boldsymbol{A} \cdot (\nabla{f})\)
  4. \(\nabla \cdot (\boldsymbol{A} \times \boldsymbol{B})= \boldsymbol{B} \cdot (\nabla \times \boldsymbol{A}) - \boldsymbol{A} \cdot (\nabla \times \boldsymbol{B})\)
  5. \(\nabla \times (f\boldsymbol{A}) = f(\nabla \times \boldsymbol{A}) - \boldsymbol{A} \times (\nabla{f})\)
  6. \(\nabla \times (\boldsymbol{A} \times \boldsymbol{B})= (\boldsymbol{B} \cdot \nabla)\boldsymbol{A} - (\boldsymbol{A} \cdot \nabla)\boldsymbol{B} + \boldsymbol{A}(\nabla \cdot \boldsymbol{B}) - \boldsymbol{B}(\nabla \cdot \boldsymbol{A})\)

1.21: Compute divergence: \(v = \frac{\hat{r}}{r^2}\). Sketch the function

Find \((\boldsymbol{A} \cdot \boldsymbol{\nabla})\boldsymbol{B}\)
Find \((\boldsymbol{\hat{r}} \cdot \boldsymbol{\nabla})\boldsymbol{\hat{r}}\)

  1. \((\boldsymbol{A} \cdot \boldsymbol{\nabla}) = (A_x \hat{x} + A_y \hat{y} + A_z \hat{z}) \cdot (\hat{x}\frac{\partial{}}{\partial{x}} + \hat{y}\frac{\partial{}}{\partial{y}} +\hat{z}\frac{\partial{}}{\partial{z}}) = (A_x\frac{\partial{}}{\partial{x}} + A_y\frac{\partial{}}{\partial{y}} + A_z\frac{\partial{}}{\partial{z}}) \\ (\boldsymbol{A} \cdot \boldsymbol{\nabla})\boldsymbol{B} = \underbrace{(A_x\frac{\partial{}}{\partial{x}} + A_y\frac{\partial{}}{\partial{y}} + A_z\frac{\partial{}}{\partial{z}})}_{\text{Treat as a scalar}}\boldsymbol{B} = (A_x\frac{\partial{B_x}}{\partial{x}} + A_y\frac{\partial{B_x}}{\partial{y}} + A_z\frac{\partial{B_x}}{\partial{z}})\hat{x} + (A_x\frac{\partial{B_y}}{\partial{x}} + A_y\frac{\partial{B_y}}{\partial{y}} + A_z\frac{\partial{B_y}}{\partial{z}})\hat{x} + (A_x\frac{\partial{B_z}}{\partial{x}} + A_y\frac{\partial{B_z}}{\partial{y}} + A_z\frac{\partial{B_z}}{\partial{z}})\hat{x}\)
  2. \((\boldsymbol{\hat{r}} \cdot \boldsymbol{\nabla})\boldsymbol{\hat{r}} \Longrightarrow (\boldsymbol{\hat{r_x}}\frac{\partial{r_x}}{\partial{x}} + \boldsymbol{\hat{r_y}}\frac{\partial{r_x}}{\partial{y}} + \boldsymbol{\hat{r_z}}\frac{\partial{r_x}}{\partial{z}}) \)
    Just for x component \( \Longrightarrow \frac{x}{r} \frac{r - x^2 * r^{-1}}{r^2} + \frac{y}{r} \frac{- xy * r^{-1}}{r^2} + \frac{z}{r} \frac{- xz * r^{-1}}{r^2} = \frac{xr - x^3 * r^{-1}}{r^3} + \frac{- xy^2 * r^{-1}}{r^3} + \frac{- xz^2 * r^{-1}}{r^3} = \frac{x}{r^2} - \frac{x^3 * r^{-1}}{r^3} - \frac{- xy^2 * r^{-1}}{r^3} - \frac{- xz^2 * r^{-1}}{r^3} = \)
    \( \frac{1}{r}[ \frac{x}{r} - \frac{x^3}{r^3} - \frac{xy^2}{r^3} - \frac{xz^2}{r^3} ]= \frac{1}{r}[ \frac{x}{r} - x(\frac{x^2 + y^2 + z^2}{r^3}) ]= \frac{1}{r}[ \frac{x}{r} - x(\frac{r^2}{r^3}) ]= \frac{1}{r}[ \frac{x}{r} - x(\frac{r^2}{r^3}) ]= \frac{1}{r}[ \frac{x}{r} - \frac{x}{r}) ]= 0 \)
    Similar result can be found for y and z components

Section 2.7: Second Derivatives

Second derivatives available:

  1. Divergence of the gradient: \(\nabla \cdot (\nabla{T})\)
  2. Curl of the gradient: \(\nabla \times (\nabla{T})\)
  3. Gradient of the divergence: \(\nabla(\nabla \cdot \boldsymbol{v})\)
  4. Divergence of the curl: \(\nabla \cdot (\nabla \times \boldsymbol{v})\)
  5. Curl of the curl: \(\nabla \times (\nabla \times \boldsymbol{v})\)
  1. \(\nabla \cdot (\nabla{T}) = \frac{\partial^2{}}{\partial{x^2}} + \frac{\partial^2{}}{\partial{y^2}} + \frac{\partial^2{}}{\partial{z^2}} = \nabla^2{T}\) (Laplacian)
    Laplacian of a scalar is a scalar.
    Occasionally Laplacian of a vector \(\nabla^2{\boldsymbol{v}} = \nabla^2{v_x}\hat{x} + \nabla^2{v_y}\hat{y} + \nabla^2{v_z}\hat{z}\)
  2. Curl of a gradient is always 0: \(\enclose{box}[mathcolor="black"]{\nabla \times (\nabla{T}) = 0}\)
    \(\nabla \times (\nabla{T}) = \hat{x}(\frac{\partial^2{T}}{\partial{y}\partial{z}} - \frac{\partial^2{T}}{\partial{z}\partial{y}}) + \hat{y}(\frac{\partial^2{T}}{\partial{x}\partial{z}} - \frac{\partial^2{T}}{\partial{z}\partial{x}}) + \hat{z}(\frac{\partial^2{T}}{\partial{x}\partial{y}} - \frac{\partial^2{T}}{\partial{y}\partial{x}}) = 0\)
    A more intuitive explaination can be given with integral calculus later.
  3. Gradient of the divergence has no special name. Seldom occurs and not the same as Laplacian.
    \( \nabla^2{\boldsymbol{v}} = (\nabla \cdot \nabla)\boldsymbol{v} \neq \nabla(\nabla \cdot \boldsymbol{v})\)
  4. Divergence of the curl always 0: \(\enclose{box}[mathcolor="black"]{\nabla \cdot (\nabla \times \boldsymbol{v}) = 0}\)
    \( \nabla \cdot (\boldsymbol{\hat{x}}(\frac{\partial{v_z}}{\partial{y}} - \frac{\partial{v_y}}{\partial{z}}) - \boldsymbol{\hat{y}}(\frac{\partial{v_z}}{\partial{x}} - \frac{\partial{v_x}}{\partial{z}}) + \boldsymbol{\hat{z}}(\frac{\partial{v_y}}{\partial{x}} - \frac{\partial{v_x}}{\partial{y}})) = \frac{\partial^2{v_z}}{\partial{x}\partial{y}} - \frac{\partial^2{v_y}}{\partial{x}\partial{z}} + \frac{\partial^2{v_x}}{\partial{y}\partial{z}} - \frac{\partial^2{v_z}}{\partial{y}\partial{z}} + \frac{\partial^2{v_y}}{\partial{z}\partial{x}} - \frac{\partial^2{v_x}}{\partial{z}\partial{y}} = 0\)
  5. Curl of a curl: \(\nabla \times (\nabla \times \boldsymbol{v}) = \nabla(\nabla \cdot \boldsymbol{v}) - \nabla^2{\boldsymbol{v}}\)
    Gradient of divergence minus laplacian.

Only two kinds of special second derivatives: the Laplacian and gradient of divergence.