# Differential Geometry
Given a [[Coordinate Transformations on Manifolds|coordinate system]] system $\{x^i\}$ on a [[manifold]] $M$, it is convenient to adopt the [[coordinate basis]] $\{\partial/\partial x^i\}$ as a [[basis]] for vector fields. However, *any* [[Linear Independence|linearly independent]] set of [[Vector Field|vector fields]] also forms a [[basis]], and not all of them can be written in terms of a [[coordinate basis]] since $\{\partial/\partial x^i\}$ and $\{\partial/\partial x^j\}$ commute for all $i, j$.
> **The Commutator**
> The commutator of two [[Vector Field|vector fields]] $\pmb{V} = \frac{d}{d\lambda}$ and $\pmb{W} = \frac{d}{d\mu}$ is defined as
> $ \left[\frac{d}{d\lambda}, \frac{d}{d\mu}\right] \equiv \frac{d}{d\lambda}\frac{d}{d\mu} -\frac{d}{d\mu} \frac{d}{d\lambda} $
> This is also known as the [[Lie Bracket]], see that page for a more precise definition.
> As we will show below, the commutator of [[Vector Field|vector fields]] is a [[vector field]] whose components do not vanish in general.
The commutator of the [[coordinate basis]] acting on a $C^2$ [[differentiable function]] $f$ is:
$
\left[\frac{\partial}{\partial x^i}, \frac{\partial}{\partial x^j}\right]f =\frac{\partial^2 f}{\partial x^i \partial x^j} - \frac{\partial^2 f}{\partial x^j \partial x^i} = 0,
$
where the last equality follows from [[Clairaut's theorem|Clairaut's Theorem]] on equality of mixed partials. Thus:
$
\left[\frac{\partial}{\partial x^i}, \frac{\partial}{\partial x^j}\right] = 0,
$
and we have proved that the [[basis]] vectors of a [[coordinate basis]] commute.
Now consider the commutator of two arbitrary [[Vector Field|vector fields]] $\pmb{V} = \frac{d}{d\lambda}$ and $\pmb{W} = \frac{d}{d\mu}$ acting on a $C^2$ function $f$ as before (with [[Einstein Summation Convention|Einstein summation]])
$
\begin{align}
\left[\frac{d}{d\lambda}, \frac{d}{d\mu}\right]f &= \left(V^i \frac{\partial}{\partial x^i} W^j \frac{\partial}{\partial x^j} - W^j \frac{\partial}{\partial x^j} V^i \frac{\partial}{\partial x^i} \right) f, \\
&= \left(V^i \frac{\partial W^j}{\partial x^i} \frac{\partial f}{\partial x^j} - W^j \frac{\partial V^i}{\partial x^j} \frac{\partial f}{\partial x^i} \right), \\
&= \left(V^i \frac{\partial W^j}{\partial x^i} \frac{\partial f}{\partial x^j} - W^i \frac{\partial V^j}{\partial x^i} \frac{\partial f}{\partial x^j} \right) , \\
&= \left(V^i \frac{\partial W^j}{\partial x^i} - W^i \frac{\partial V^j}{\partial x^i} \right) \frac{\partial f}{\partial x^j},
\end{align}
$
where in the second-to-last line we relabeled $i \leftrightarrow j$ (recall that they are free indices in a sum, thus they can be relabeled). Thus we get:
$
\left[\frac{d}{d\lambda}, \frac{d}{d\mu}\right] = \left(V^i \frac{\partial W^j}{\partial x^i} - W^i \frac{\partial V^j}{\partial x^i} \right)
$
and we have proved that two arbitrary vector fields do not commuted. The commutator is thus a [[vector field]] whose components do not vanish in general. If $d/d\lambda$ and $d/d\mu$ are two components of a [[basis]], then they cannot be expressed as derivatives of [[Coordinate Transformations on Manifolds|coordinates]] in general. They form a [[Non-coordinate Basis]]
## Interpretation of the Commutator
In the figure below, a coordinate grid of a two-[[dimension|dimensional]] [[manifold]] is shown. By definition, $x^1$ is constant (e.g. $x^1 = b$) along lines of $x^2$ (e.g. $x^2 = c,\, d$), i.e. the integral curves of $\partial/\partial x^2$. This is why $\partial/\partial x^1$ and $\partial/\partial x^2$ commute, they are derivatives along a line where the other is fixed.
![[Pasted image 20210127100735.png]]
Now consider a [[Non-coordinate Basis|non-coordinate]] grid in the figure below. We have the two arbitrary vector fields $\pmb{V} = d/d\lambda$ and $\pmb{W} = d/d\mu$, and the grid is simply their integral curves. It only looks like a coordinate grid as an artifact of 2 spatial dimensions, in 3D these lines may not even cross. They look like coordinate curves but their parameterization is not that of coordinate [[curve|curves]].
[[Integral Curves]] of $\pmb{W}$ (e.g. $(1)$) are not necessarily curves of constant $\lambda$ (e.g. $\lambda$ varies from 3 to ~2.5 along curve $(1)$), and vice-versa. This is why $d/d\lambda$ and $d/d\mu$ do not commute.
![[Pasted image 20210127101047.png]]
Now consider moving along the integral curves in the figure below.
![[Pasted image 20210127102444.png]]
Using the exponential notation shown [[Vector#^b5cea1|here]], we get:
$
\begin{align}
x^i(R) &= \exp\left[ \epsilon \frac{d}{d\lambda}\right]x^i\Bigg|_P, \\
x^i(A) &= \exp\left[ \epsilon \frac{d}{d\mu}\right]x^i\Bigg|_R = \exp\left[ \epsilon \frac{d}{d\mu}\right]\exp\left[ \epsilon \frac{d}{d\lambda}\right]x^i\Bigg|_P, \\
x^i(B) &= \exp\left[ \epsilon \frac{d}{d\mu}\right]x^i\Bigg|_R = \exp\left[ \epsilon \frac{d}{d\lambda}\right]\exp\left[ \epsilon \frac{d}{d\mu}\right]x^i\Bigg|_P, \\
\end{align}
$
Thus:
$
\begin{align}
x^i(B) - x^i(A) &= \left[e^{\epsilon d/d\lambda}, e^{\epsilon d/d\mu}\right] x^i\Bigg|_P ,\\
&= \left[1 + \epsilon \frac{d}{d\lambda} + \mathcal{O}(\epsilon^2), 1 + \epsilon \frac{d}{d\mu} + \mathcal{O}(\epsilon^2)\right] x^i\Bigg|_P , \\
&= \epsilon^2 \left[\frac{d}{d\lambda}, \frac{d}{d\mu}\right]x^i\Bigg|_P + \mathcal{O}(\epsilon^3) ,\\
\end{align}
$
thus, the commutator gives, to second order, the difference between the paths traversed.