align fix; theorem style; condition number

This commit is contained in:
jverzani
2024-10-31 14:22:21 -04:00
parent 3e7e3a9727
commit 18aae2aa93
61 changed files with 1705 additions and 819 deletions

View File

@@ -105,7 +105,7 @@ annotate!([
(.5, -.1, "Δy"),
(1+.75dx, .1, "Δx"),
(1+dx+.1, .75, "Δz"),
(.5,.15,L"(x,y,z)"),
(.5,.15,"(x,y,z)"),
(.45,.6, "î"),
(1+.8dx, .7, "ĵ"),
(.8, 1+dy+.1, "k̂")
@@ -204,20 +204,20 @@ arrow!([1/2, 1-dx], .01 *[-1,0], linewidth=3, color=:blue)
arrow!([1-dx, 1/2], .01 *[0, 1], linewidth=3, color=:blue)
annotate!([
(0,-1/16,L"(x,y)"),
(1, -1/16, L"(x+\Delta{x},y)"),
(0, 1+1/16, L"(x,y+\Delta{y})"),
(1/2, 4dx, L"\hat{i}"),
(1/2, 1-4dx, L"-\hat{i}"),
(3dx, 1/2, L"-\hat{j}"),
(1-3dx, 1/2, L"\hat{j}")
(0,-1/16,"(x,y)"),
(1, -1/16, "(x+Δx,y)"),
(0, 1+1/16, "(x,y+Δy)"),
(1/2, 4dx, "î}"),
(1/2, 1-4dx, "-"),
(3dx, 1/2, "-"),
(1-3dx, 1/2, "ĵ")
])
```
Let $F=\langle F_x, F_y\rangle$. For small enough values of $\Delta{x}$ and $\Delta{y}$ the line integral, $\oint_C F\cdot d\vec{r}$ can be *approximated* by $4$ terms:
$$
\begin{align*}
\left(F(x,y) \cdot \hat{i}\right)\Delta{x} &+
\left(F(x+\Delta{x},y) \cdot \hat{j}\right)\Delta{y} +
@@ -230,6 +230,7 @@ F_x(x, y+\Delta{y}) (-\Delta{x}) + F_y(x,y) (-\Delta{y})\\
(F_y(x + \Delta{x}, y) - F_y(x, y))\Delta{y} -
(F_x(x, y+\Delta{y})-F_x(x,y))\Delta{x}.
\end{align*}
$$
The Riemann approximation allows a choice of evaluation point for Riemann integrable functions, and the choice here lends itself to further analysis. Were the above divided by $\Delta{x}\Delta{y}$, the area of the box, and a limit taken, partial derivatives appear to suggest this formula:
@@ -275,7 +276,7 @@ annotate!([
(.5, -.1, "Δy"),
(1+.75dx, .1, "Δx"),
(1+dx+.1, .75, "Δz"),
(.5,.15,L"(x,y,z)"),
(.5,.15,"(x,y,z)"),
(.45,.6, "î"),
(1+.8dx, .667, "ĵ"),
(.8, 1+dy+.067, "k̂"),
@@ -309,10 +310,10 @@ annotate!([
(.9, 1+dx, "C₁"),
(2*dx, 1/2, L"\hat{T}=\hat{i}"),
(1+2*dx,1/2, L"\hat{T}=-\hat{i}"),
(1/2,-3/2*dx, L"\hat{T}=\hat{j}"),
(1/2, 1+(3/2)*dx, L"\hat{T}=-\hat{j}"),
(2*dx, 1/2, "T̂=î"),
(1+2*dx,1/2, "T̂=-î"),
(1/2,-3/2*dx, "T̂= ĵ"),
(1/2, 1+(3/2)*dx, "T̂=-ĵ"),
(3dx,1-2dx, "(x,y,z+Δz)"),
(4dx,2dx, "(x+Δx,y,z+Δz)"),
@@ -326,18 +327,19 @@ p
Now we compute the *line integral*. Consider the top face, $S_1$, connecting $(x,y,z+\Delta z), (x + \Delta x, y, z + \Delta z), (x + \Delta x, y + \Delta y, z + \Delta z), (x, y + \Delta y, z + \Delta z)$, Using the *right hand rule*, parameterize the boundary curve, $C_1$, in a counter clockwise direction so the right hand rule yields the outward pointing normal ($\hat{k}$). Then the integral $\oint_{C_1} F\cdot \hat{T} ds$ is *approximated* by the following Riemann sum of $4$ terms:
$$
\begin{align*}
F(x,y, z+\Delta{z}) \cdot \hat{i}\Delta{x} &+ F(x+\Delta x, y, z+\Delta{z}) \cdot \hat{j} \Delta y \\
&+ F(x, y+\Delta y, z+\Delta{z}) \cdot (-\hat{i}) \Delta{x} \\
&+ F(x, y, z+\Delta{z}) \cdot (-\hat{j}) \Delta{y}.
\end{align*}
$$
(The points $c_i$ are chosen from the endpoints of the line segments.)
$$
\begin{align*}
\oint_{C_1} F\cdot \hat{T} ds
&\approx (F_y(x+\Delta x, y, z+\Delta{z}) \\
@@ -345,17 +347,19 @@ F(x,y, z+\Delta{z}) \cdot \hat{i}\Delta{x} &+ F(x+\Delta x, y, z+\Delta{z}) \cd
&- (F_x(x,y + \Delta{y}, z+\Delta{z}) \\
&- F_x(x, y, z+\Delta{z})) \Delta{x}
\end{align*}
$$
As before, were this divided by the *area* of the surface, we have after rearranging and cancellation:
$$
\begin{align*}
\frac{1}{\Delta{S_1}} \oint_{C_1} F \cdot \hat{T} ds &\approx
\frac{F_y(x+\Delta x, y, z+\Delta{z}) - F_y(x, y, z+\Delta{z})}{\Delta{x}}\\
&- \frac{F_x(x, y+\Delta y, z+\Delta{z}) - F_x(x, y, z+\Delta{z})}{\Delta{y}}.
\end{align*}
$$
In the limit, as $\Delta{S} \rightarrow 0$, this will converge to $\partial{F_y}/\partial{x}-\partial{F_x}/\partial{y}$.
@@ -367,7 +371,7 @@ Had the bottom of the box been used, a similar result would be found, up to a mi
Unlike the two dimensional case, there are other directions to consider and here the other sides will yield different answers. Consider now the face connecting $(x,y,z), (x+\Delta{x}, y, z), (x+\Delta{x}, y, z + \Delta{z})$, and $(x,y,z +\Delta{z})$ with outward pointing normal $-\hat{j}$. Let $S_2$ denote this face and $C_2$ describe its boundary. Orient this curve so that the right hand rule points in the $-\hat{j}$ direction (the outward pointing normal). Then, as before, we can approximate:
$$
\begin{align*}
\oint_{C_2} F \cdot \hat{T} ds
&\approx
@@ -378,6 +382,7 @@ F(x,y,z) \cdot \hat{i} \Delta{x} \\
&= (F_z(x+\Delta{x},y,z) - F_z(x, y, z))\Delta{z} -
(F_x(x,y,z+\Delta{z}) - F(x,y,z)) \Delta{x}.
\end{align*}
$$
Dividing by $\Delta{S}=\Delta{x}\Delta{z}$ and taking a limit will give:
@@ -401,16 +406,18 @@ $$
In short, depending on the face chosen, a different answer is given, but all have the same type.
::: {.callout-note icon=false}
## The curl
> Define the *curl* of a $3$-dimensional vector field $F=\langle F_x,F_y,F_z\rangle$ by:
>
> $$
> \text{curl}(F) =
> \langle \frac{\partial{F_z}}{\partial{y}} - \frac{\partial{F_y}}{\partial{z}},
> \frac{\partial{F_x}}{\partial{z}} - \frac{\partial{F_z}}{\partial{x}},
> \frac{\partial{F_y}}{\partial{x}} - \frac{\partial{F_x}}{\partial{y}} \rangle.
> $$
Define the *curl* of a $3$-dimensional vector field $F=\langle F_x,F_y,F_z\rangle$ by:
$$
\text{curl}(F) =
\langle \frac{\partial{F_z}}{\partial{y}} - \frac{\partial{F_y}}{\partial{z}},
\frac{\partial{F_x}}{\partial{z}} - \frac{\partial{F_z}}{\partial{x}},
\frac{\partial{F_y}}{\partial{x}} - \frac{\partial{F_x}}{\partial{y}} \rangle.
$$
:::
If $S$ is some surface with closed boundary $C$ oriented so that the unit normal, $\hat{N}$, of $S$ is given by the right hand rule about $C$, then
@@ -474,7 +481,7 @@ The divergence, gradient, and curl all involve partial derivatives. There is a n
This is a *vector differential operator* that acts on functions and vector fields through the typical notation to yield the three operations:
$$
\begin{align*}
\nabla{f} &= \langle
\frac{\partial{f}}{\partial{x}},
@@ -512,6 +519,7 @@ F_x & F_y & F_z
\end{bmatrix}
,\quad\text{the curl}.
\end{align*}
$$
:::{.callout-note}
@@ -842,12 +850,13 @@ Let $f$ and $g$ denote scalar functions, $R^3 \rightarrow R$ and $F$ and $G$ be
As with the sum rule of univariate derivatives, these operations satisfy:
$$
\begin{align*}
\nabla(f + g) &= \nabla{f} + \nabla{g}\\
\nabla\cdot(F+G) &= \nabla\cdot{F} + \nabla\cdot{G}\\
\nabla\times(F+G) &= \nabla\times{F} + \nabla\times{G}.
\end{align*}
$$
### Product rule
@@ -856,12 +865,13 @@ As with the sum rule of univariate derivatives, these operations satisfy:
The product rule $(uv)' = u'v + uv'$ has related formulas:
$$
\begin{align*}
\nabla{(fg)} &= (\nabla{f}) g + f\nabla{g} = g\nabla{f} + f\nabla{g}\\
\nabla\cdot{fF} &= (\nabla{f})\cdot{F} + f(\nabla\cdot{F})\\
\nabla\times{fF} &= (\nabla{f})\times{F} + f(\nabla\times{F}).
\end{align*}
$$
### Rules over cross products
@@ -870,12 +880,13 @@ The product rule $(uv)' = u'v + uv'$ has related formulas:
The cross product of two vector fields is a vector field for which the divergence and curl may be taken. There are formulas to relate to the individual terms:
$$
\begin{align*}
\nabla\cdot(F \times G) &= (\nabla\times{F})\cdot G - F \cdot (\nabla\times{G})\\
\nabla\times(F \times G) &= F(\nabla\cdot{G}) - G(\nabla\cdot{F}) + (G\cdot\nabla)F-(F\cdot\nabla)G\\
&= \nabla\cdot(BA^t - AB^t).
\end{align*}
$$
The curl formula is more involved.
@@ -921,7 +932,7 @@ Second,
This is not as clear, but can be seen algebraically as terms cancel. First:
$$
\begin{align*}
\nabla\cdot(\nabla\times{F}) &=
\langle
@@ -938,6 +949,7 @@ This is not as clear, but can be seen algebraically as terms cancel. First:
\left(\frac{\partial^2{F_x}}{\partial{z}\partial{y}} - \frac{\partial^2{F_z}}{\partial{x}\partial{y}}\right) +
\left(\frac{\partial^2{F_y}}{\partial{x}\partial{z}} - \frac{\partial^2{F_x}}{\partial{y}\partial{z}}\right)
\end{align*}
$$
Focusing on one component function, $F_z$ say, we see this contribution:
@@ -974,10 +986,10 @@ apoly!(ps, linewidth=3, color=:red)
ps = [[1,0],[1+dx, dy],[1+dx, 1+dy],[1,1]]
apoly!(ps, linewidth=3, color=:green)
annotate!(dx+.02, dy-0.05, L"P_1")
annotate!(0+0.05, 0 - 0.02, L"P_2")
annotate!(1+0.05, 0 - 0.02, L"P_3")
annotate!(1+dx+.02, dy-0.05, L"P_4")
annotate!(dx+.02, dy-0.05, "P")
annotate!(0+0.05, 0 - 0.02, "P")
annotate!(1+0.05, 0 - 0.02, "P")
annotate!(1+dx+.02, dy-0.05, "P")
p
```
@@ -1014,7 +1026,7 @@ This is because of how the line integrals are oriented so that the right-hand ru
The [invariance of charge](https://en.wikipedia.org/wiki/Maxwell%27s_equations#Charge_conservation) can be derived as a corollary of Maxwell's equation. The divergence of the curl of the magnetic field is $0$, leading to:
$$
\begin{align*}
0 &= \nabla\cdot(\nabla\times{B}) \\
&=
@@ -1024,6 +1036,7 @@ The [invariance of charge](https://en.wikipedia.org/wiki/Maxwell%27s_equations#C
&=
\mu_0(\nabla\cdot{J} + \frac{\partial{\rho}}{\partial{t}}).
\end{align*}
$$
That is $\nabla\cdot{J} = -\partial{\rho}/\partial{t}$. This says any change in the charge density in time ($\partial{\rho}/\partial{t}$) is balanced off by a divergence in the electric current density ($\nabla\cdot{J}$). That is, charge can't be created or destroyed in an isolated system.
@@ -1048,7 +1061,7 @@ $$
Without explaining why, these values can be computed using volume and surface integrals:
$$
\begin{align*}
\phi(\vec{r}') &=
\frac{1}{4\pi} \int_V \frac{\nabla \cdot F(\vec{r})}{\|\vec{r}'-\vec{r} \|} dV -
@@ -1056,16 +1069,18 @@ Without explaining why, these values can be computed using volume and surface in
A(\vec{r}') &= \frac{1}{4\pi} \int_V \frac{\nabla \times F(\vec{r})}{\|\vec{r}'-\vec{r} \|} dV +
\frac{1}{4\pi} \oint_S \frac{F(\vec{r})}{\|\vec{r}'-\vec{r} \|} \times \hat{N} dS.
\end{align*}
$$
If $V = R^3$, an unbounded domain, *but* $F$ *vanishes* faster than $1/r$, then the theorem still holds with just the volume integrals:
$$
\begin{align*}
\phi(\vec{r}') &=\frac{1}{4\pi} \int_V \frac{\nabla \cdot F(\vec{r})}{\|\vec{r}'-\vec{r} \|} dV\\
A(\vec{r}') &= \frac{1}{4\pi} \int_V \frac{\nabla \times F(\vec{r})}{\|\vec{r}'-\vec{r}\|} dV.
\end{align*}
$$
## Change of variable
@@ -1080,7 +1095,7 @@ Some details are [here](https://en.wikipedia.org/wiki/Curvilinear_coordinates),
We restrict to $n=3$ and use $(x,y,z)$ for Cartesian coordinates and $(u,v,w)$ for an *orthogonal* curvilinear coordinate system, such as spherical or cylindrical. If $\vec{r} = \langle x,y,z\rangle$, then
$$
\begin{align*}
d\vec{r} &= \langle dx,dy,dz \rangle = J \langle du,dv,dw\rangle\\
&=
@@ -1091,6 +1106,7 @@ d\vec{r} &= \langle dx,dy,dz \rangle = J \langle du,dv,dw\rangle\\
\frac{\partial{\vec{r}}}{\partial{v}} dv +
\frac{\partial{\vec{r}}}{\partial{w}} dw.
\end{align*}
$$
The term ${\partial{\vec{r}}}/{\partial{u}}$ is tangent to the curve formed by *assuming* $v$ and $w$ are constant and letting $u$ vary. Similarly for the other partial derivatives. Orthogonality assumes that at every point, these tangent vectors are orthogonal.
@@ -1138,7 +1154,7 @@ This uses orthogonality, so $\hat{e}_v \times \hat{e}_w$ is parallel to $\hat{e}
The volume element is found by *projecting* $d\vec{r}$ onto the $\hat{e}_u$, $\hat{e}_v$, $\hat{e}_w$ coordinate system through $(d\vec{r} \cdot\hat{e}_u) \hat{e}_u$, $(d\vec{r} \cdot\hat{e}_v) \hat{e}_v$, and $(d\vec{r} \cdot\hat{e}_w) \hat{e}_w$. Then forming the triple scalar product to compute the volume of the parallelepiped:
$$
\begin{align*}
\left[(d\vec{r} \cdot\hat{e}_u) \hat{e}_u\right] \cdot
\left(
@@ -1149,6 +1165,7 @@ The volume element is found by *projecting* $d\vec{r}$ onto the $\hat{e}_u$, $\h
&=
h_u h_v h_w du dv dw,
\end{align*}
$$
as the unit vectors are orthonormal, their triple scalar product is $1$ and $d\vec{r}\cdot\hat{e}_u = h_u du$, etc.
@@ -1214,7 +1231,7 @@ p
The tangent vectors found from the partial derivatives of $\vec{r}$:
$$
\begin{align*}
\frac{\partial{\vec{r}}}{\partial{r}} &=
\langle \cos(\theta) \cdot \sin(\phi), \sin(\theta) \cdot \sin(\phi), \cos(\phi)\rangle,\\
@@ -1223,12 +1240,13 @@ The tangent vectors found from the partial derivatives of $\vec{r}$:
\frac{\partial{\vec{r}}}{\partial{\phi}} &=
\langle r\cdot\cos(\theta)\cdot\cos(\phi), r\cdot\sin(\theta)\cdot\cos(\phi), -r\cdot\sin(\phi) \rangle.
\end{align*}
$$
With this, we have $h_r=1$, $h_\theta=r\sin(\phi)$, and $h_\phi = r$. So that
$$
\begin{align*}
dl &= \sqrt{dr^2 + (r\sin(\phi)d\theta)^2 + (rd\phi)^2},\\
dS_r &= r^2\sin(\phi)d\theta d\phi,\\
@@ -1236,6 +1254,7 @@ dS_\theta &= rdr d\phi,\\
dS_\phi &= r\sin(\phi)dr d\theta, \quad\text{and}\\
dV &= r^2\sin(\phi) drd\theta d\phi.
\end{align*}
$$
The following visualizes the volume and the surface elements.
@@ -1292,7 +1311,7 @@ p
If $f$ is a scalar function then $df = \nabla{f} \cdot d\vec{r}$ by the chain rule. Using the curvilinear coordinates:
$$
\begin{align*}
df &=
\frac{\partial{f}}{\partial{u}} du +
@@ -1303,6 +1322,7 @@ df &=
\frac{1}{h_v}\frac{\partial{f}}{\partial{v}} h_vdv +
\frac{1}{h_w}\frac{\partial{f}}{\partial{w}} h_wdw.
\end{align*}
$$
But, as was used above, $d\vec{r} \cdot \hat{e}_u = h_u du$, etc. so $df$ can be re-expressed as:

View File

@@ -391,17 +391,19 @@ By "iterated" we mean performing two different definite integrals. For example,
The question then: under what conditions will the three integrals be equal?
::: {.callout-note icon=false}
## [Fubini](https://math.okstate.edu/people/lebl/osu4153-s16/chapter10-ver1.pdf)
> [Fubini](https://math.okstate.edu/people/lebl/osu4153-s16/chapter10-ver1.pdf). Let $R \times S$ be a closed rectangular region in $R^n \times R^m$. Suppose $f$ is bounded. Define $f_x(y) = f(x,y)$ and $f^y(x) = f(x,y)$ where $x$ is in $R^n$ and $y$ in $R^m$. *If* $f_x$ and $f^y$ are integrable then
>
> $$
> \iint_{R\times S}fdV = \iint_R \left(\iint_S f_x(y) dy\right) dx
> = \iint_S \left(\iint_R f^y(x) dx\right) dy.
> $$
Let $R \times S$ be a closed rectangular region in $R^n \times R^m$. Suppose $f$ is bounded. Define $f_x(y) = f(x,y)$ and $f^y(x) = f(x,y)$ where $x$ is in $R^n$ and $y$ in $R^m$. *If* $f_x$ and $f^y$ are integrable then
$$
\iint_{R\times S}fdV = \iint_R \left(\iint_S f_x(y) dy\right) dx
= \iint_S \left(\iint_R f^y(x) dx\right) dy.
$$
Similarly, if $f^y$ is integrable for all $y$, then $\iint_{R\times S}fdV =\iint_S \iint_R f(x,y) dx dy$.
:::
An immediate corollary is that the above holds for continuous functions when $R$ and $S$ are bounded, the case described here.
@@ -939,11 +941,12 @@ In [Katz](http://www.jstor.org/stable/2689856) a review of the history of "chang
We view $R$ in two coordinate systems $(x,y)$ and $(u,v)$. We have that
$$
\begin{align*}
dx &= A du + B dv\\
dy &= C du + D dv,
\end{align*}
$$
where $A = \partial{x}/\partial{u}$, $B = \partial{x}/\partial{v}$, $C= \partial{y}/\partial{u}$, and $D = \partial{y}/\partial{v}$. Lagrange, following Euler, first sets $x$ to be constant (as is done in iterated integration). Hence, $dx = 0$ and so $du = -(B/A) dv$ and, after substitution, $dy = (D-C(B/A))dv$. Then Lagrange set $y$ to be a constant, so $dy = 0$ and hence $dv=0$ so $dx = Adu$. The area "element" $dx dy = A du \cdot (D - C(B/A)) dv = (AD - BC) du dv$. Since areas and volumes are non-negative, the absolute value is used. With this, we have "$dxdy = |AD-BC|du dv$" as the analog of $dx = g'(u) du$.
@@ -952,11 +955,12 @@ where $A = \partial{x}/\partial{u}$, $B = \partial{x}/\partial{v}$, $C= \partial
The expression $AD - BC$ was also derived by Euler, by related means. Lagrange extended the analysis to 3 dimensions. Before doing so, it is helpful to understand the problem from a geometric perspective. Euler was attempting to understand the effects of the following change of variable:
$$
\begin{align*}
x &= a + mt + \sqrt{1-m^2} v\\
y & = b + \sqrt{1-m^2}t -mv
\end{align*}
$$
Euler knew this to be a clockwise *rotation* by an angle $\theta$ with $\cos(\theta) = m$, a *reflection* through the $x$ axis, and a translation by $\langle a, b\rangle$. All these *should* preserve the area represented by $dx dy$, so he was *expecting* $dx dy = dt dv$.
@@ -1090,13 +1094,15 @@ Using the fact that the two vectors involved are columns in the Jacobian of the
The absolute value of the determinant of the Jacobian is the multiplying factor that is seen in the change of variable formula for all dimensions:
::: {.callout-note icon=false}
## [Change of variable](https://en.wikipedia.org/wiki/Integration_by_substitution#Substitution_for_multiple_variables)
> [Change of variable](https://en.wikipedia.org/wiki/Integration_by_substitution#Substitution_for_multiple_variables) Let $U$ be an open set in $R^n$, $G:U \rightarrow R^n$ be an *injective* differentiable function with *continuous* partial derivatives. If $f$ is continuous and compactly supported, then
>
> $$
> \iint_{G(S)} f(\vec{x}) dV = \iint_S (f \circ G)(\vec{u}) |\det(J_G)(\vec{u})| dU.
> $$
Let $U$ be an open set in $R^n$, $G:U \rightarrow R^n$ be an *injective* differentiable function with *continuous* partial derivatives. If $f$ is continuous and compactly supported, then
$$
\iint_{G(S)} f(\vec{x}) dV = \iint_S (f \circ G)(\vec{u}) |\det(J_G)(\vec{u})| dU.
$$
:::
For the one-dimensional case, there is no absolute value, but there the interval is reversed, producing "negative" area. This is not the case here, where $S$ is parameterized to give positive volume.
@@ -1308,12 +1314,13 @@ What about other triangles, say the triangle bounded by $x=0$, $y=0$ and $y-x=1$
This can be seen as a reflection through the line $x=1/2$ of the triangle above. If $G_1$ represents the mapping from $U [0,1]\times[0,1]$ into the triangle of the last problem, and $G_2$ represents the reflection through the line $x=1/2$, then the transformation $G_2 \circ G_1$ will map the box $U$ into the desired region. By the chain rule, we have:
$$
\begin{align*}
\int_{(G_2\circ G_1)(U)} f dx &= \int_U (f\circ G_2 \circ G_1) |\det(J_{G_2 \circ G_1})| du \\
&=
\int_U (f\circ G_2 \circ G_1) |\det(J_{G_2}(G_1(u)))||\det(J_{G_1}(u))| du.
\end{align*}
$$
(In [Katz](http://www.jstor.org/stable/2689856) it is mentioned that Jacobi showed this in 1841.)

View File

@@ -166,13 +166,14 @@ However, it proves more interesting to define an integral incorporating how prop
The canonical example is [work](https://en.wikipedia.org/wiki/Work_(physics)), which is a measure of a force times a distance. For an object following a path, the work done is still a force times a distance, but only that force in the direction of the motion is considered. (The *constraint force* keeping the object on the path does no work.) Mathematically, $\hat{T}$ describes the direction of motion along a path, so the work done in moving an object over a small segment of the path is $(F\cdot\hat{T}) \Delta{s}$. Adding up incremental amounts of work leads to a Riemann sum for a line integral involving a vector field.
::: {.callout-note icon=false}
## Work
> The *work* done in moving an object along a path $C$ by a force field, $F$, is given by the integral
>
> $$
> \int_C (F \cdot \hat{T}) ds = \int_C F\cdot d\vec{r} = \int_a^b ((F\circ\vec{r}) \cdot \frac{d\vec{r}}{dt})(t) dt.
> $$
The *work* done in moving an object along a path $C$ by a force field, $F$, is given by the integral
$$
\int_C (F \cdot \hat{T}) ds = \int_C F\cdot d\vec{r} = \int_a^b ((F\circ\vec{r}) \cdot \frac{d\vec{r}}{dt})(t) dt.
$$
:::
---
@@ -180,13 +181,15 @@ The canonical example is [work](https://en.wikipedia.org/wiki/Work_(physics)), w
In the $n=2$ case, there is another useful interpretation of the line integral. In this dimension the normal vector, $\hat{N}$, is well defined in terms of the tangent vector, $\hat{T}$, through a rotation: $\langle a,b\rangle^t = \langle b,-a\rangle$. (The negative, $\langle -b,a\rangle$ is also a candidate, the difference in this choice would lead to a sign difference in the answer.) This allows the definition of a different line integral, called a flow integral, as detailed later:
::: {.callout-note icon=false}
## Flow
> The *flow* across a curve $C$ is given by
>
> $$
> \int_C (F\cdot\hat{N}) ds = \int_a^b (F \circ \vec{r})(t) \cdot (\vec{r}'(t))^t dt.
> $$
The *flow* across a curve $C$ is given by
$$
\int_C (F\cdot\hat{N}) ds = \int_a^b (F \circ \vec{r})(t) \cdot (\vec{r}'(t))^t dt.
$$
:::
### Examples
@@ -296,9 +299,11 @@ using the Fundamental Theorem of Calculus.
The main point above is that *if* the vector field is the gradient of a scalar field, then the work done depends *only* on the endpoints of the path and not the path itself.
::: {.callout-note icon=false}
## Conservative vector field
> **Conservative vector field**: If $F$ is a vector field defined in an *open* region $R$; $A$ and $B$ are points in $R$ and *if* for *any* curve $C$ in $R$ connecting $A$ to $B$, the line integral of $F \cdot \vec{T}$ over $C$ depends *only* on the endpoint $A$ and $B$ and not the path, then the line integral is called *path indenpendent* and the field is called a *conservative field*.
If $F$ is a vector field defined in an *open* region $R$; $A$ and $B$ are points in $R$ and *if* for *any* curve $C$ in $R$ connecting $A$ to $B$, the line integral of $F \cdot \vec{T}$ over $C$ depends *only* on the endpoint $A$ and $B$ and not the path, then the line integral is called *path indenpendent* and the field is called a *conservative field*.
:::
The force of gravity is the gradient of a scalar field. As such, the two integrals above which yield $0$ could have been computed more directly. The particular scalar field is $f = -GMm/\|\vec{r}\|$, which goes by the name the gravitational *potential* function. As seen, $f$ depends only on magnitude, and as the endpoints of the path in the example have the same distance to the origin, the work integral, $(f\circ\vec{r})(b) - (f\circ\vec{r})(a)$ will be $0$.
@@ -345,17 +350,19 @@ There are technical assumptions about curves and regions that are necessary for
### The fundamental theorem of line integrals
The fact that work in a potential field is path independent is a consequence of the Fundamental Theorem of Line [Integrals](https://en.wikipedia.org/wiki/Gradient_theorem):
The fact that work in a potential field is path independent is a consequence of
::: {.callout-note icon=false}
## The Fundamental Theorem of Line [Integrals](https://en.wikipedia.org/wiki/Gradient_theorem):
> Let $U$ be an open subset of $R^n$, $f: U \rightarrow R$ a *differentiable* function and $\vec{r}: R \rightarrow R^n$ a differentiable function such that the the path $C = \vec{r}(t)$, $a\leq t\leq b$ is contained in $U$. Then
>
> $$
> \int_C \nabla{f} \cdot d\vec{r} =
> \int_a^b \nabla{f}(\vec{r}(t)) \cdot \vec{r}'(t) dt =
> f(\vec{r}(b)) - f(\vec{r}(a)).
> $$
Let $U$ be an open subset of $R^n$, $f: U \rightarrow R$ a *differentiable* function and $\vec{r}: R \rightarrow R^n$ a differentiable function such that the the path $C = \vec{r}(t)$, $a\leq t\leq b$ is contained in $U$. Then
$$
\int_C \nabla{f} \cdot d\vec{r} =
\int_a^b \nabla{f}(\vec{r}(t)) \cdot \vec{r}'(t) dt =
f(\vec{r}(b)) - f(\vec{r}(a)).
$$
:::
That is, a line integral through a gradient field can be evaluated by evaluating the original scalar field at the endpoints of the curve. In other words, line integrals through gradient fields are conservative.

View File

@@ -99,12 +99,13 @@ In dimension $m=3$, the **binormal** vector, $\hat{B}$, is the unit vector $\hat
The [Frenet-Serret]() formulas define the **curvature**, $\kappa$, and the **torsion**, $\tau$, by
$$
\begin{align*}
\frac{d\hat{T}}{ds} &= & \kappa \hat{N} &\\
\frac{d\hat{N}}{ds} &= -\kappa\hat{T} & & + \tau\hat{B}\\
\frac{d\hat{B}}{ds} &= & -\tau\hat{N}&
\end{align*}
$$
These formulas apply in dimension $m=2$ with $\hat{B}=\vec{0}$.
@@ -122,13 +123,14 @@ The chain rule says $(\vec{r}(g(t))' = \vec{r}'(g(t)) g'(t)$.
A scalar function, $f:R^n\rightarrow R$, $n > 1$ has a **partial derivative** defined. For $n=2$, these are:
$$
\begin{align*}
\frac{\partial{f}}{\partial{x}}(x,y) &=
\lim_{h\rightarrow 0} \frac{f(x+h,y)-f(x,y)}{h}\\
\frac{\partial{f}}{\partial{y}}(x,y) &=
\lim_{h\rightarrow 0} \frac{f(x,y+h)-f(x,y)}{h}.
\end{align*}
$$
The generalization to $n>2$ is clear - the partial derivative in $x_i$ is the derivative of $f$ when the *other* $x_j$ are held constant.
@@ -356,7 +358,7 @@ $$
In two dimensions, we have the following interpretations:
$$
\begin{align*}
\iint_R dA &= \text{area of } R\\
\iint_R \rho dA &= \text{mass with constant density }\rho\\
@@ -364,12 +366,13 @@ In two dimensions, we have the following interpretations:
\frac{1}{\text{area}}\iint_R x \rho(x,y)dA &= \text{centroid of region in } x \text{ direction}\\
\frac{1}{\text{area}}\iint_R y \rho(x,y)dA &= \text{centroid of region in } y \text{ direction}
\end{align*}
$$
In three dimensions, we have the following interpretations:
$$
\begin{align*}
\iint_VdV &= \text{volume of } V\\
\iint_V \rho dV &= \text{mass with constant density }\rho\\
@@ -378,6 +381,7 @@ In three dimensions, we have the following interpretations:
\frac{1}{\text{volume}}\iint_V y \rho(x,y)dV &= \text{centroid of volume in } y \text{ direction}\\
\frac{1}{\text{volume}}\iint_V z \rho(x,y)dV &= \text{centroid of volume in } z \text{ direction}
\end{align*}
$$
To compute integrals over non-box-like regions, Fubini's theorem may be utilized. Alternatively, a **transformation** of variables

View File

@@ -109,7 +109,7 @@ p = plot(legend=false, xticks=nothing, yticks=nothing, border=:none, ylim=(-1/2,
for m in ms
drawf!(p, f, m, 0.9*dx/2)
end
annotate!([(ms[6]-dx/2,-0.3, L"x_{i-1}"), (ms[6]+dx/2,-0.3, L"x_{i}")])
annotate!([(ms[6]-dx/2,-0.3, "xᵢ₋₁}"), (ms[6]+dx/2,-0.3, "x")])
p
```
@@ -214,18 +214,20 @@ However, the microscopic boundary integrals have cancellations that lead to a ma
This all suggests that the flow integral around the surface of the larger region (the blue square) is equivalent to the integral of the curl component over the region. This is [Green](https://en.wikipedia.org/wiki/Green%27s_theorem)'s theorem, as stated by Wikipedia:
::: {.callout-note icon=false}
## Green's theorem
> **Green's theorem**: Let $C$ be a positively oriented, piecewise smooth, simple closed curve in the plane, and let $D$ be the region bounded by $C$. If $F=\langle F_x, F_y\rangle$, is a vector field on an open region containing $D$ having continuous partial derivatives then:
>
> $$
> \oint_C F\cdot\hat{T}ds =
> \iint_D \left(
> \frac{\partial{F_y}}{\partial{x}} - \frac{\partial{F_x}}{\partial{y}}
> \right) dA=
> \iint_D \text{curl}(F)dA.
> $$
Let $C$ be a positively oriented, piecewise smooth, simple closed curve in the plane, and let $D$ be the region bounded by $C$. If $F=\langle F_x, F_y\rangle$, is a vector field on an open region containing $D$ having continuous partial derivatives then:
$$
\oint_C F\cdot\hat{T}ds =
\iint_D \left(
\frac{\partial{F_y}}{\partial{x}} - \frac{\partial{F_x}}{\partial{y}}
\right) dA=
\iint_D \text{curl}(F)dA.
$$
:::
The statement of the theorem applies only to regions whose boundaries are simple closed curves. Not all simple regions have such boundaries. An annulus for example. This is a restriction that will be generalized.
@@ -271,11 +273,12 @@ r(t) = [a*cos(t),b*sin(t)]
To compute the area of the triangle with vertices $(0,0)$, $(a,0)$ and $(0,b)$ we can orient the boundary counter clockwise. Let $A$ be the line segment from $(0,b)$ to $(0,0)$, $B$ be the line segment from $(0,0)$ to $(a,0)$, and $C$ be the other. Then
$$
\begin{align*}
\frac{1}{2} \int_A F\cdot\hat{T} ds &=\frac{1}{2} \int_A -ydx = 0\\
\frac{1}{2} \int_B F\cdot\hat{T} ds &=\frac{1}{2} \int_B xdy = 0,
\end{align*}
$$
as on $A$, $y=0$ and $dy=0$ and on $B$, $x=0$ and $dx=0$.
@@ -311,7 +314,7 @@ For the two dimensional case the curl is a scalar. *If* $F = \langle F_x, F_y\ra
Now assume $\partial{F_y}/\partial{x} - \partial{F_x}/\partial{y} = 0$. Let $P$ and $Q$ be two points in the plane. Take any path, $C_1$ from $P$ to $Q$ and any return path, $C_2$, from $Q$ to $P$ that do not cross and such that $C$, the concatenation of the two paths, satisfies Green's theorem. Then, as $F$ is continuous on an open interval containing $D$, we have:
$$
\begin{align*}
0 &= \iint_D 0 dA \\
&=
@@ -321,6 +324,7 @@ Now assume $\partial{F_y}/\partial{x} - \partial{F_x}/\partial{y} = 0$. Let $P$
&=
\int_{C_1} F \cdot \hat{T} ds + \int_{C_2}F \cdot \hat{T} ds.
\end{align*}
$$
Reversing $C_2$ to go from $P$ to $Q$, we see the two work integrals are identical, that is the field is conservative.
@@ -339,13 +343,14 @@ For example, let $F(x,y) = \langle \sin(xy), \cos(xy) \rangle$. Is this a conser
We can check by taking partial derivatives. Those of interest are:
$$
\begin{align*}
\frac{\partial{F_y}}{\partial{x}} &= \frac{\partial{(\cos(xy))}}{\partial{x}} =
-\sin(xy) y,\\
\frac{\partial{F_x}}{\partial{y}} &= \frac{\partial{(\sin(xy))}}{\partial{y}} =
\cos(xy)x.
\end{align*}
$$
It is not the case that $\partial{F_y}/\partial{x} - \partial{F_x}/\partial{y}=0$, so this vector field is *not* conservative.
@@ -417,24 +422,26 @@ p
Let $A$ label the red line, $B$ the green curve, $C$ the blue line, and $D$ the black line. Then the area is given from Green's theorem by considering half of the the line integral of $F(x,y) = \langle -y, x\rangle$ or $\oint_C (xdy - ydx)$. To that matter we have:
$$
\begin{align*}
\int_A (xdy - ydx) &= a(-f(a))\\
\int_C (xdy - ydx) &= b f(b)\\
\int_D (xdy - ydx) &= 0\\
\end{align*}
$$
Finally the integral over $B$, using integration by parts:
$$
\begin{align*}
\int_B F(\vec{r}(t))\cdot \frac{d\vec{r}(t)}{dt} dt &=
\int_b^a \langle -f(t),t \rangle\cdot\langle 1, f'(t)\rangle dt\\
&= \int_a^b f(t)dt - \int_a^b tf'(t)dt\\
&= \int_a^b f(t)dt - \left(tf(t)\mid_a^b - \int_a^b f(t) dt\right).
\end{align*}
$$
Combining, we have after cancellation $\oint (xdy - ydx) = 2\int_a^b f(t) dt$, or after dividing by $2$ the signed area under the curve.
@@ -470,7 +477,7 @@ The cut leads to a counter-clockwise orientation on the outer ring and a clockw
To see that the area integral of $F(x,y) = (1/2)\langle -y, x\rangle$ produces the area for this orientation we have, using $C_1$ as the outer ring, and $C_2$ as the inner ring:
$$
\begin{align*}
\oint_{C_1} F \cdot \hat{T} ds &=
\int_0^{2\pi} (1/2)(2)\langle -\sin(t), \cos(t)\rangle \cdot (2)\langle-\sin(t), \cos(t)\rangle dt \\
@@ -479,6 +486,7 @@ To see that the area integral of $F(x,y) = (1/2)\langle -y, x\rangle$ produces t
\int_{0}^{2\pi} (1/2) \langle \sin(t), \cos(t)\rangle \cdot \langle-\sin(t), -\cos(t)\rangle dt\\
&= -(1/2)(2\pi) = -\pi.
\end{align*}
$$
(Using $\vec{r}(t) = 2\langle \cos(t), \sin(t)\rangle$ for the outer ring and $\vec{r}(t) = 1\langle \cos(t), -\sin(t)\rangle$ for the inner ring.)
@@ -739,7 +747,7 @@ $$
This gives the series of approximations:
$$
\begin{align*}
\oint_C F\cdot\hat{T} ds &=
\sum \oint_{C_i} F\cdot\hat{T} ds \\
@@ -750,18 +758,21 @@ This gives the series of approximations:
&\approx
\iint_S \nabla\times{F}\cdot\hat{N} dS.
\end{align*}
$$
In terms of our expanding popcorn, the boundary integral - after accounting for cancellations, as in Green's theorem - can be seen as a microscopic sum of boundary integrals each of which is approximated by a term $\nabla\times{F}\cdot\hat{N} \Delta{S}$ which is viewed as a Riemann sum approximation for the the integral of the curl over the surface. The cancellation depends on a proper choice of orientation, but with that we have:
::: {.callout-note icon=false}
## Stokes' theorem
> **Stokes' theorem**: Let $S$ be an orientable smooth surface in $R^3$ with boundary $C$, $C$ oriented so that the chosen normal for $S$ agrees with the right-hand rule for $C$'s orientation. Then *if* $F$ has continuous partial derivatives
>
> $$
> \oint_C F \cdot\hat{T} ds = \iint_S (\nabla\times{F})\cdot\hat{N} dA.
> $$
Let $S$ be an orientable smooth surface in $R^3$ with boundary $C$, $C$ oriented so that the chosen normal for $S$ agrees with the right-hand rule for $C$'s orientation. Then *if* $F$ has continuous partial derivatives
$$
\oint_C F \cdot\hat{T} ds = \iint_S (\nabla\times{F})\cdot\hat{N} dA.
$$
:::
Green's theorem is an immediate consequence upon viewing the region in $R^2$ as a surface in $R^3$ with normal $\hat{k}$.
@@ -997,17 +1008,17 @@ $$
the last approximation through a Riemann sum approximation. This heuristic leads to:
::: {.callout-note icon=false}
## The divergence theorem
> **The divergence theorem**: Suppose $V$ is a $3$-dimensional volume which is bounded (compact) and has a boundary, $S$, that is piecewise smooth. If $F$ is a continuously differentiable vector field defined on an open set containing $V$, then:
>
> $$
> \iiint_V (\nabla\cdot{F}) dV = \oint_S (F\cdot\hat{N})dS.
> $$
Suppose $V$ is a $3$-dimensional volume which is bounded (compact) and has a boundary, $S$, that is piecewise smooth. If $F$ is a continuously differentiable vector field defined on an open set containing $V$, then:
$$
\iiint_V (\nabla\cdot{F}) dV = \oint_S (F\cdot\hat{N})dS.
$$
That is, the volume integral of the divergence can be computed from the flux integral over the boundary of $V$.
:::
### Examples of the divergence theorem
@@ -1130,12 +1141,13 @@ The divergence theorem provides two means to compute a value, the point here is
Following Schey, we now consider a continuous analog to the crowd counting problem through a flow with a non-uniform density that may vary in time. Let $\rho(x,y,z;t)$ be the time-varying density and $v(x,y,z;t)$ be a vector field indicating the direction of flow. Consider some three-dimensional volume, $V$, with boundary $S$ (though two-dimensional would also be applicable). Then these integrals have interpretations:
$$
\begin{align*}
\iiint_V \rho dV &&\quad\text{Amount contained within }V\\
\frac{\partial}{\partial{t}} \iiint_V \rho dV &=
\iiint_V \frac{\partial{\rho}}{\partial{t}} dV &\quad\text{Change in time of amount contained within }V
\end{align*}
$$
Moving the derivative inside the integral requires an assumption of continuity. Assume the material is *conserved*, meaning that if the amount in the volume $V$ changes it must flow in and out through the boundary. The flow out through $S$, the boundary of $V$, is