Back

Arc Length and Metric Tensor

To calculate the (squared) length of a vector, we take the dot product of the vector with it self:

∣v∣2=v⋅v=(vμeμ)⋅(vνeν)=vμvν(eμ⋅eν). \begin{align*} |\boldsymbol{v}|^2 &= \boldsymbol{v} \cdot \boldsymbol{v} \\ &= (v^{\mu} \boldsymbol{e_{\mu}}) \cdot (v^{\nu} \boldsymbol{e_{\nu}}) \\ &= v^{\mu} v^{\nu} (\boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}}). \end{align*}

In 2D Cartesian coordinates, the dot products of basis vectors are as follows:

ex⋅ex=1,ex⋅ey=0,ey⋅ey=1. \begin{align*} \boldsymbol{e_x} \cdot \boldsymbol{e_x} = 1, \\ \boldsymbol{e_x} \cdot \boldsymbol{e_y} = 0, \\ \boldsymbol{e_y} \cdot \boldsymbol{e_y} = 1. \end{align*}

The metric tensor gμνg_{\mu \nu} contains these dot products:

gμν=eμ⋅eν.g_{\mu \nu} = \boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}}.

For the Cartesian coordinate system, the metric tensor is equal to the Kronecker delta:

gμν=δμν={1μ=ν,0μ≠ν,g_{\mu \nu} = \delta_{\mu \nu} = \begin{cases} 1 & \mu &= \nu, \\ 0 & \mu &\neq \nu, \end{cases}

Or represented as matrix for 2D Cartesian coordinate system:

gμν=[1001]g_{\mu \nu} = \begin{bmatrix} 1 & 0 \\ 0 & 1 \end{bmatrix}

This means that the vectors are parallel to each other due to the missing off diagonal components.

The metric tensor has two covariant indices. Consider the coordinate transformation xμ→x~μx^{\mu} \to \tilde{x}^{\mu}, the bases transform as follows:

e~μ=∂xν∂x~μeν,\boldsymbol{\tilde{e}_{\mu}} = \frac{\partial x^{\nu}}{\partial \tilde{x}^{\mu}} \boldsymbol{e}_{\nu},

and the metric:

g~μν=e~μ⋅e~ν=∂xα∂x~μeα⋅∂xβ∂x~νeβ=∂xα∂x~μ∂xβ∂x~νeα⋅eβ=∂xα∂x~μ∂xβ∂x~νgαβ. \begin{align*} \tilde{g}_{\mu \nu} &= \boldsymbol{\tilde{e}_{\mu} \cdot \tilde{e}_{\nu}} \\ &= \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \boldsymbol{e}_{\alpha} \cdot \frac{\partial x^{\beta}}{\partial \tilde{x}^{\nu}} \boldsymbol{e}_{\beta} \\ &= \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \frac{\partial x^{\beta}}{\partial \tilde{x}^{\nu}} \boldsymbol{e}_{\alpha} \cdot \boldsymbol{e}_{\beta} \\ &= \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \frac{\partial x^{\beta}}{\partial \tilde{x}^{\nu}} g_{\alpha \beta}. \end{align*}

The metric tensor is also symmetric:

gμν=eμ⋅eν=eν⋅eμ=gνμ. \begin{align*} g_{\mu \nu} &= \boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}} \\ &= \boldsymbol{e_{\nu}} \cdot \boldsymbol{e_{\mu}} \\ &= g_{\nu \mu}. \end{align*}

Generally, if we want to compute the dot product of two vectors, we use the metric tensor:

v⋅w=(vμeμ)⋅(wνeν)=vμwν(eμ⋅eν)=vμwνgμν=∣v∣∣w∣cos⁡θ, \begin{align*} \boldsymbol{v} \cdot \boldsymbol{w} &= (v^{\mu} \boldsymbol{e_{\mu}}) \cdot (w^{\nu} \boldsymbol{e_{\nu}}) \\ &= v^{\mu} w^{\nu} (\boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}}) \\ &= v^{\mu} w^{\nu} g_{\mu \nu} = |\boldsymbol{v}| |\boldsymbol{w}| \cos \theta, \end{align*}

where θ\theta is the angle between the two vectors.

The metric tensor is a function g:V×V→Rg: V \times V \to \mathbb{R}:

g(v,w)=vμwνgμν.g(\boldsymbol{v}, \boldsymbol{w}) = v^{\mu} w^{\nu} g_{\mu \nu}.

We can scale the inputs of the metric tensor:

g(av,w)=g(v,aw)=ag(v,w),a(vμwνgμν)=(avμ)wνgμν=vμ(awν)gμν \begin{align*} g(a \boldsymbol{v}, \boldsymbol{w}) &= g(\boldsymbol{v}, a \boldsymbol{w}) = a g(\boldsymbol{v}, \boldsymbol{w}), \\ a (v^{\mu} w^{\nu} g_{\mu \nu}) &= (a v^{\mu}) w^{\nu} g_{\mu \nu} = v^{\mu} (a w^{\nu}) g_{\mu \nu} \end{align*}

The inputs can also be added:

g(v+u,w)=g(v,w)+g(u,w),(vμ+uμ)wνgμν=vμwνgμν+uμwνgμν,g(v,w+t)=g(v,w)+g(v,t),vμ(wν+tν)gμν=vμwνgμν+vμtνgμν, \begin{align*} g(\boldsymbol{v} + \boldsymbol{u}, \boldsymbol{w}) &= g(\boldsymbol{v}, \boldsymbol{w}) + g(\boldsymbol{u}, \boldsymbol{w}), \\ (v^{\mu} + u^{\mu}) w^{\nu} g_{\mu \nu} &= v^{\mu} w^{\nu} g_{\mu \nu} + u^{\mu} w^{\nu} g_{\mu \nu}, \\ g(\boldsymbol{v}, \boldsymbol{w} + \boldsymbol{t}) &= g(\boldsymbol{v}, \boldsymbol{w}) + g(\boldsymbol{v}, \boldsymbol{t}), \\ v^{\mu} (w^{\nu} + t^{\nu}) g_{\mu \nu} &= v^{\mu} w^{\nu} g_{\mu \nu} + v^{\mu} t^{\nu} g_{\mu \nu}, \end{align*}

however:

g(v+u,w+t)≠g(v,w)+g(u,t),g(v+u,w+t)=g(v,w+t)+g(u,w+t)=g(v,w)+g(v,t)+g(u,w)+g(u,t). \begin{align*} g(\boldsymbol{v} + \boldsymbol{u}, \boldsymbol{w} + \boldsymbol{t}) &\neq g(\boldsymbol{v}, \boldsymbol{w}) + g(\boldsymbol{u}, \boldsymbol{t}), \\ g(\boldsymbol{v} + \boldsymbol{u}, \boldsymbol{w} + \boldsymbol{t}) &= g(\boldsymbol{v}, \boldsymbol{w} + \boldsymbol{t}) + g(\boldsymbol{u}, \boldsymbol{w} + \boldsymbol{t}) \\ &= g(\boldsymbol{v}, \boldsymbol{w}) + g(\boldsymbol{v}, \boldsymbol{t}) + g(\boldsymbol{u}, \boldsymbol{w}) + g(\boldsymbol{u}, \boldsymbol{t}). \end{align*}

And this is the same definition as bilinear form:

B:V×V→R,aB(v,w)=B(av,w)=B(v,aw),B(v+u,w)=B(v,w)+B(u,w),B(v,w+t)=B(v,w)+B(v,t). \begin{gather*} \mathcal{B}: V \times V \to \mathbb{R}, \\ a\mathcal{B}(\boldsymbol{v}, \boldsymbol{w}) = \mathcal{B}(a\boldsymbol{v}, \boldsymbol{w}) = \mathcal{B}(\boldsymbol{v}, a\boldsymbol{w}), \\ \mathcal{B}(\boldsymbol{v} + \boldsymbol{u}, \boldsymbol{w}) = \mathcal{B}(\boldsymbol{v}, \boldsymbol{w}) + \mathcal{B}(\boldsymbol{u}, \boldsymbol{w}), \\ \mathcal{B}(\boldsymbol{v}, \boldsymbol{w} + \boldsymbol{t}) = \mathcal{B}(\boldsymbol{v}, \boldsymbol{w}) + \mathcal{B}(\boldsymbol{v}, \boldsymbol{t}). \end{gather*}

The metric tensor is a bilinear form, but in addition it has two properties:

g(v,w)=g(w,v),g(v,v)≥0. \begin{align*} g(\boldsymbol{v}, \boldsymbol{w}) &= g(\boldsymbol{w}, \boldsymbol{v}), \tag{symmetricity} \\ g(\boldsymbol{v}, \boldsymbol{v}) &\geq 0. \tag{positive or zero length} \end{align*}

A curve may be broken up into small pieces:

Curve

and if we sum over the lengths these small pieces, we get the arc length LL:

L≈∑i∣R(λ+h)−R(λ)∣L=lim⁡h→0∑i∣R(λ+h)−R(λ)∣hh=∫∣dRdλ∣dλ, \begin{align*} L &\approx \sum_i |\boldsymbol{R}(\lambda + h) - \boldsymbol{R}(\lambda)| \\ L &= \lim_{h \to 0} \sum_i \frac{|\boldsymbol{R}(\lambda + h) - \boldsymbol{R}(\lambda)|}{h} h \\ &= \int \left|\frac{d\boldsymbol{R}}{d \lambda}\right| d\lambda, \end{align*}

where dRdλ\frac{d\boldsymbol{R}}{d\lambda} is the vector tangent to the curve. Its length squared is equal to:

∣dRdλ∣2=dRdλ⋅dRdλ=(∂R∂RμdRμdλ)⋅(∂R∂RνdRνdλ)=dRμdλdRνdλ(∂R∂Rμ⋅∂R∂Rν)=dRμdλdRνdλ(eμ⋅eν)=dRμdλdRνdλgμν. \begin{align*} \left|\frac{d\boldsymbol{R}}{d \lambda}\right|^2 &= \frac{d \boldsymbol{R}}{d\lambda} \cdot \frac{d \boldsymbol{R}}{d\lambda} \\ &= \left(\frac{\partial \boldsymbol{R}}{\partial R^{\mu}} \frac{d R^{\mu}}{d \lambda}\right) \cdot \left(\frac{\partial \boldsymbol{R}}{\partial R^{\nu}} \frac{d R^{\nu}}{d \lambda}\right) \\ &= \frac{d R^{\mu}}{d \lambda} \frac{d R^{\nu}}{d \lambda} \left(\frac{\partial \boldsymbol{R}}{\partial R^{\mu}} \cdot \frac{\partial \boldsymbol{R}}{\partial R^{\nu}}\right) \\ &= \frac{d R^{\mu}}{d \lambda} \frac{d R^{\nu}}{d \lambda} \left(\boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}}\right) \\ &= \frac{d R^{\mu}}{d \lambda} \frac{d R^{\nu}}{d \lambda} g_{\mu \nu}. \end{align*}

We would like to find a way to relate the vectors v\boldsymbol{v} from the vector space VV and covectors from the dual space V∗V^*. For a vector v\boldsymbol{v}, we will introduce its "partner" covector v⋅_\boldsymbol{v} \cdot \_ where _\_ is a "slot" for another vector. This covector really is a member of V∗V^* by the abstract definition:

v⋅_:V→R,v⋅(na)=n(v⋅a),v⋅(a+b)=(v⋅a)+(v⋅b), \begin{align*} \boldsymbol{v} \cdot \_: V \to \mathbb{R}, \\ \boldsymbol{v} \cdot (n\boldsymbol{a}) = n (\boldsymbol{v} \cdot \boldsymbol{a}), \\ \boldsymbol{v} \cdot (\boldsymbol{a} + \boldsymbol{b}) = (\boldsymbol{v} \cdot \boldsymbol{a}) + (\boldsymbol{v} \cdot \boldsymbol{b}), \end{align*}

and since it lives in the dual space V∗V^*, we should be able to build it from the dual basis:

v⋅_=vμϵμ\boldsymbol{v} \cdot \_ = v_{\mu} \epsilon^{\mu}

If we substitute w\boldsymbol{w} into v⋅_\boldsymbol{v} \cdot \_:

v⋅w=g(v,w)=gαβϵαϵβ(vγeγ,wδeδ)=gαβϵα(vγeγ)ϵβ(wδeδ)=gαβvγwδϵα(eγ)ϵβ(eδ)=gαβvγwδδγαδδβ=gαβvαwβ \begin{align*} \boldsymbol{v} \cdot \boldsymbol{w} &= g(\boldsymbol{v}, \boldsymbol{w}) \\ &= g_{\alpha \beta} \epsilon^{\alpha} \epsilon^{\beta} (v^{\gamma} \boldsymbol{e_{\gamma}}, w^{\delta} \boldsymbol{e_{\delta}}) \\ &= g_{\alpha \beta} \epsilon^{\alpha} (v^{\gamma} \boldsymbol{e_{\gamma}}) \epsilon^{\beta} (w^{\delta} \boldsymbol{e_{\delta}}) \\ &= g_{\alpha \beta} v^{\gamma} w^{\delta} \epsilon^{\alpha} (\boldsymbol{e_{\gamma}}) \epsilon^{\beta} (\boldsymbol{e_{\delta}}) \\ &= g_{\alpha \beta} v^{\gamma} w^{\delta} \delta^{\alpha}_{\gamma} \delta^{\beta}_{\delta} \\ &= g_{\alpha \beta} v^{\alpha} w^{\beta} \end{align*}

we arrive at the formula for dot product. If we instead not substitute anything and consider just v⋅_\boldsymbol{v} \cdot \_, we arrive at:

v⋅_=g(v,_)=gαβϵαϵβ(vγeγ)=gαβvγϵαϵβ(eγ)=gαβvγϵαδγβ=gαβvβϵα. \begin{align*} \boldsymbol{v} \cdot \_ &= g(\boldsymbol{v}, \_) \\ &= g_{\alpha \beta} \epsilon^{\alpha} \epsilon^{\beta} (v^{\gamma} \boldsymbol{e_{\gamma}}) \\ &= g_{\alpha \beta} v^{\gamma} \epsilon^{\alpha} \epsilon^{\beta} (\boldsymbol{e_{\gamma}}) \\ &= g_{\alpha \beta} v^{\gamma} \epsilon^{\alpha} \delta^{\beta}_{\gamma} \\ &= g_{\alpha \beta} v^{\beta} \epsilon^{\alpha}. \end{align*}

This is the component decomposition of v⋅_\boldsymbol{v} \cdot \_. Instead of writing gαβvβg_{\alpha \beta} v^{\beta}, we can write vαv_{\alpha}:

vα=gαβvβ,v⋅_=vαϵα=gαβvβϵα. \begin{align*} v_{\alpha} &= g_{\alpha \beta} v^{\beta}, \\ \boldsymbol{v} \cdot \_ &= v_{\alpha} \epsilon^{\alpha} = g_{\alpha \beta} v^{\beta} \epsilon^{\alpha}. \end{align*}

Generally vμ≠vμv_{\mu} \neq v^{\mu} except in orthonormal basis.

We can lower an index. Now we need to figure out how to raise an index. For this, we will use the inverse metric gμνg^{\mu \nu} defined as follows:

gαβgβγ=δγα.g^{\alpha \beta} g_{\beta \gamma} = \delta^{\alpha}_{\gamma}.

The equation for covector components vα=gαβvβv_{\alpha} = g_{\alpha \beta} v^{\beta}. We can multiply both sides by gγαg^{\gamma \alpha}:

gγαvα=gγαgαβvβ=δβγvβ=vγ. \begin{align*} g^{\gamma \alpha} v_{\alpha} &= g^{\gamma \alpha} g_{\alpha \beta} v^{\beta} \\ &= \delta^{\gamma}_{\beta} v^{\beta} \\ &= v^{\gamma}. \end{align*}

So to summarize:

vμ=gμνvν,vμ=gμνvν. \begin{align*} v_{\mu} &= g_{\mu \nu} v^{\nu}, \\ v^{\mu} &= g^{\mu \nu} v_{\nu}. \end{align*}

Consider a point parametrized by the distance from the origin rr and the angle θ\theta

Polar coordinates

From the diagram we can see:

x=rcos⁡θ,y=rsin⁡θ. \begin{align*} x &= r \cos \theta, \\ y &= r \sin \theta. \end{align*}

The partial derivatives are:

∂x∂r=cos⁡θ,∂x∂θ=−rsin⁡θ,∂y∂r=sin⁡θ,∂y∂θ=rcos⁡θ. \begin{align*} \frac{\partial x}{\partial r} &= \cos \theta, & \frac{\partial x}{\partial \theta} &= -r \sin \theta, \\ \frac{\partial y}{\partial r} &= \sin \theta, & \frac{\partial y}{\partial \theta} &= r \cos \theta. \end{align*}

The metric tensor in 2D Cartesian coordinates is the Kronecker delta δμν\delta_{\mu \nu}, the polar metric tensor g~μν\tilde{g}_{\mu \nu} is equal to:

g~μν=∂xα∂xμ∂xβ∂xνgαβ=∂xα∂xμ∂xβ∂xνδαβ=∑α∂xα∂xμ∂xα∂xν. \begin{align*} \tilde{g}_{\mu \nu} &= \frac{\partial x^{\alpha}}{\partial x^{\mu}} \frac{\partial x^{\beta}}{\partial x^{\nu}} g_{\alpha \beta} \\ &= \frac{\partial x^{\alpha}}{\partial x^{\mu}} \frac{\partial x^{\beta}}{\partial x^{\nu}} \delta_{\alpha \beta} \\ &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial x^{\mu}} \frac{\partial x^{\alpha}}{\partial x^{\nu}}. \end{align*}

The components of the polar metric tensor are equal to:

g~rr=∑α∂xα∂r∂xα∂r=cos⁡2θ+sin⁡2θ=1,g~rθ=g~θr=∑α∂xα∂r∂xα∂θ=−rcos⁡θsin⁡θ+rsin⁡θcos⁡θ=0,g~θθ=∑α∂xα∂θ∂xα∂θ=(−rsin⁡θ)2+(rcos⁡θ)2=r2sin⁡2θ+r2cos⁡2θ=r2, \begin{align*} \tilde{g}_{rr} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial r} \frac{\partial x^{\alpha}}{\partial r} \\ &= \cos^2 \theta + \sin^2 \theta \\ &= 1, \\ \tilde{g}_{r \theta} = \tilde{g}_{\theta r} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial r} \frac{\partial x^{\alpha}}{\partial \theta} \\ &= -r \cos \theta \sin \theta + r \sin \theta \cos \theta \\ &= 0, \\ \tilde{g}_{\theta \theta} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial \theta} \frac{\partial x^{\alpha}}{\partial \theta} \\ &= (-r \sin \theta)^2 + (r \cos \theta)^2 \\ &= r^2 \sin^2 \theta + r^2 \cos^2 \theta \\ &= r^2, \end{align*}

or in matrix notation:

g~μν=[100r2].\tilde{g}_{\mu \nu} = \begin{bmatrix} 1 & 0 \\ 0 & r^2 \end{bmatrix}.

Consider the spherical coordinates where the coordinates are: rr - the distance from the origin, θ\theta - the colatitude and ϕ\phi - the azimuthal angle:

Spherical coordinates

We can start by solving for the cartesian coordinate zz and the projection xyxy onto the x-yx\textrm{-}y plane:

Spherical coordinates 2
z=rcos⁡θ,xy=rsin⁡θ. \begin{align*} z &= r \cos \theta, \\ xy &= r \sin \theta. \end{align*}

And now we can solve fot the Cartesian coordinates xx and yy:

Spherical coordinates 3
x=xycos⁡ϕ=rcos⁡ϕsin⁡θ,y=xysin⁡ϕ=rsin⁡ϕsin⁡θ. \begin{align*} x &= xy \cos \phi = r \cos \phi \sin \theta, \\ y &= xy \sin \phi = r \sin \phi \sin \theta. \\ \end{align*}

Putting it all together, the Cartesian coordinates with the cartesian metric tensor gμνg_{\mu \nu} are equal to:

x=rsin⁡θcos⁡ϕ,y=rsin⁡θsin⁡ϕ,z=rcos⁡θ,gμν=δμν=[100010001]. \begin{align*} x &= r \sin \theta \cos \phi, \\ y &= r \sin \theta \sin \phi, \\ z &= r \cos \theta, \\ g_{\mu \nu} &= \delta_{\mu \nu} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{bmatrix}. \end{align*}

The metric tensor g~μν\tilde{g}_{\mu \nu} for spherical coordinates is equal to:

g~μν=∂xα∂x~μ∂xβ∂x~νgαβ=∂xα∂x~μ∂xβ∂x~νδαβ=∑α∂xα∂x~μ∂xα∂x~ν. \begin{align*} \tilde{g}_{\mu \nu} &= \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \frac{\partial x^{\beta}}{\partial \tilde{x}^{\nu}} g_{\alpha \beta} \\ &= \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \frac{\partial x^{\beta}}{\partial \tilde{x}^{\nu}} \delta_{\alpha \beta} \\ &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\mu}} \frac{\partial x^{\alpha}}{\partial \tilde{x}^{\nu}}. \end{align*}

The partial derivatives in the transformation are equal to:

∂x∂r=sin⁡θcos⁡ϕ,∂x∂θ=rcos⁡θcos⁡ϕ,∂x∂ϕ=−rsin⁡θsin⁡ϕ,∂y∂r=sin⁡θsin⁡ϕ,∂y∂θ=rcos⁡θsin⁡ϕ,∂y∂ϕ=rsin⁡θcos⁡ϕ,∂z∂r=cos⁡θ,∂z∂θ=−rsin⁡θ,∂z∂ϕ=0. \begin{align*} \frac{\partial x}{\partial r} &= \sin \theta \cos \phi, & \frac{\partial x}{\partial \theta} &= r \cos \theta \cos \phi, & \frac{\partial x}{\partial \phi} &= -r \sin \theta \sin \phi, \\ \frac{\partial y}{\partial r} &= \sin \theta \sin \phi, & \frac{\partial y}{\partial \theta} &= r \cos \theta \sin \phi, & \frac{\partial y}{\partial \phi} &= r \sin \theta \cos \phi, \\ \frac{\partial z}{\partial r} &= \cos \theta, & \frac{\partial z}{\partial \theta} &= -r \sin \theta, & \frac{\partial z}{\partial \phi} &= 0. \end{align*}

Transforming the metric tensor components:

g~rr=∑α∂xα∂r∂xα∂r=(sin⁡θcos⁡ϕ)2+(sin⁡θsin⁡ϕ)2+(cos⁡θ)2=sin⁡2θcos⁡2ϕ+sin⁡2θsin⁡2ϕ+cos⁡2θ=sin⁡2θ+cos⁡2θ=1,g~rθ=g~θr=∑α∂xα∂r∂xα∂θ=sin⁡θcos⁡ϕ rcos⁡θcos⁡ϕ+sin⁡θsin⁡ϕ rcos⁡θsin⁡ϕ−cos⁡θ rsin⁡θ=rsin⁡θcos⁡θ(cos⁡2ϕ+sin⁡2ϕ)−rsin⁡θcos⁡θ=rsin⁡θcos⁡θ−rsin⁡θcos⁡θ=0,g~rϕ=g~ϕr=∑α∂xα∂r∂xα∂ϕ=−sin⁡θcos⁡ϕ rsin⁡θsin⁡ϕ+sin⁡θsin⁡ϕ rsin⁡θcos⁡ϕ+cos⁡θ 0=−sin⁡θcos⁡ϕ rsin⁡θsin⁡ϕ+sin⁡θsin⁡ϕ rsin⁡θcos⁡ϕ+cos⁡θ 0=0,g~θθ=∑α∂xα∂θ∂xα∂θ=(rcos⁡θcos⁡ϕ)2+(rcos⁡θsin⁡ϕ)2+(−rsin⁡θ)2=r2cos⁡2θcos⁡2ϕ+r2cos⁡2θsin⁡2ϕ+r2sin⁡2θ=r2cos⁡2θ(cos⁡2ϕ+sin⁡2ϕ)+r2sin⁡2θ=r2cos⁡2θ+r2sin⁡2θ=r2g~θϕ=g~ϕθ=∑α∂xα∂θ∂xα∂ϕ=−rcos⁡θcos⁡ϕ rsin⁡θsin⁡ϕ+rcos⁡θsin⁡ϕ rsin⁡θcos⁡ϕ−rsin⁡θ 0=0,g~ϕϕ=∑α∂xα∂ϕ∂xα∂ϕ=(−rsin⁡θsin⁡ϕ)2+(rsin⁡θcos⁡ϕ)2+02=r2sin⁡2θsin⁡2ϕ+r2sin⁡2θcos⁡2ϕ=r2sin⁡2θ(sin⁡2ϕ+cos⁡2ϕ)=r2sin⁡2θ, \begin{align*} \tilde{g}_{r r} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial r} \frac{\partial x^{\alpha}}{\partial r} \\ &= (\sin \theta \cos \phi)^2 + (\sin \theta \sin \phi)^2 + (\cos \theta)^2 \\ &= \sin^2 \theta \cos^2 \phi + \sin^2 \theta \sin^2 \phi + \cos^2 \theta \\ &= \sin^2 \theta + \cos^2 \theta \\ &= 1, \\ \tilde{g}_{r \theta} = \tilde{g}_{\theta r} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial r} \frac{\partial x^{\alpha}}{\partial \theta} \\ &= \sin \theta \cos \phi\ r \cos \theta \cos \phi + \sin \theta \sin \phi\ r \cos \theta \sin \phi - \cos \theta\ r \sin \theta \\ &= r \sin \theta \cos \theta (\cos^2 \phi + \sin^2 \phi) - r \sin \theta \cos \theta \\ &= r \sin \theta \cos \theta - r \sin \theta \cos \theta \\ &= 0, \\ \tilde{g}_{r \phi} = \tilde{g}_{\phi r} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial r} \frac{\partial x^{\alpha}}{\partial \phi} \\ &= -\sin \theta \cos \phi\ r \sin \theta \sin \phi + \sin \theta \sin \phi\ r \sin \theta \cos \phi + \cos \theta\ 0 \\ &= -\sin \theta \cos \phi\ r \sin \theta \sin \phi + \sin \theta \sin \phi\ r \sin \theta \cos \phi + \cos \theta\ 0 \\ &= 0, \\ \tilde{g}_{\theta \theta} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial \theta} \frac{\partial x^{\alpha}}{\partial \theta} \\ &= (r \cos \theta \cos \phi)^2 + (r \cos \theta \sin \phi)^2 + (- r \sin \theta)^2 \\ &= r^2 \cos^2 \theta \cos^2 \phi + r^2 \cos^2 \theta \sin^2 \phi + r^2 \sin^2 \theta \\ &= r^2 \cos^2 \theta (\cos^2 \phi + \sin^2 \phi) + r^2 \sin^2 \theta \\ &= r^2 \cos^2 \theta + r^2 \sin^2 \theta \\ &= r^2 \\ \tilde{g}_{\theta \phi} = \tilde{g}_{\phi \theta} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial \theta} \frac{\partial x^{\alpha}}{\partial \phi} \\ &= -r \cos \theta \cos \phi\ r \sin \theta \sin \phi + r \cos \theta \sin \phi\ r \sin \theta \cos \phi - r \sin \theta\ 0 \\ &= 0, \\ \tilde{g}_{\phi \phi} &= \sum_{\alpha} \frac{\partial x^{\alpha}}{\partial \phi} \frac{\partial x^{\alpha}}{\partial \phi} \\ &= (- r \sin \theta \sin \phi)^2 + (r \sin \theta \cos \phi)^2 + 0^2 \\ &= r^2 \sin^2 \theta \sin^2 \phi + r^2 \sin^2 \theta \cos^2 \phi \\ &= r^2 \sin^2 \theta (\sin^2 \phi + \cos^2 \phi) \\ &= r^2 \sin^2 \theta, \end{align*}

or in matrix notation:

g~μν=[1000r2000r2sin⁡2θ].\tilde{g}_{\mu \nu} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & r^2 & 0 \\ 0 & 0 & r^2 \sin^2 \theta \\ \end{bmatrix}.

In this section, I will refer to the spherical metric tensor as gμνg_{\mu \nu}:

gμν=[1000r2000r2sin⁡2θ].g_{\mu \nu} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & r^2 & 0 \\ 0 & 0 & r^2 \sin^2 \theta \\ \end{bmatrix}.

By keeping rr constant, we get a parametric surface of sphere:

Sphere

To represent coordinates, we choose a 2D θ-ϕ\theta\textrm{-}\phi plane representing the θ\theta and ϕ\phi coordinates respectively:

Coordinate plane of sphere

where 0≤θ≤π0 \leq \theta \leq \pi and 0≤ϕ≤2π0 \leq \phi \leq 2\pi.

Consider a curve parametrized in the ϕ-θ\phi\textrm{-}\theta plane as follows:

θ(λ)=λ,ϕ(λ)=λ,0≤λ≤π. \begin{align*} \theta(\lambda) &= \lambda, \\ \phi(\lambda) &= \lambda, \\ 0 \leq \lambda &\leq \pi. \end{align*}

Rendering, on our plane, the curve looks like this:

Coordinate plane of sphere with curve

However, on the sphere, the curve looks like this:

Sphere with curve

We could naively calculate the length of the curve from the plane using Pythagorean theorem:

s=ϕ2+θ2=π2+π2=π2.s = \sqrt{\phi^2 + \theta^2} = \sqrt{\pi^2 + \pi^2} = \pi \sqrt{2}.

However, we always have to use the metric tensor:

s=∫0π∣dRdλ∣dλ=∫0πgμνdRμdλdRνdλdλ=∫0πgμμ(dRμdλ)2dλ=∫0π(drdλ)2+r2(dθdλ)2+r2sin⁡2θ(dϕdλ)2dλ=∫0πr2+r2sin⁡2θdλ=r2∫0π1+sin⁡2λ dλ≈3.8202r2≠π2. \begin{align*} s &= \int_0^{\pi} \left|\frac{d \boldsymbol{R}}{d \lambda}\right| d\lambda \\ &= \int_0^{\pi} \sqrt{g_{\mu \nu} \frac{d R^{\mu}}{d \lambda} \frac{d R^{\nu}}{d \lambda}} d\lambda \\ &= \int_0^{\pi} \sqrt{g_{\mu \mu} \left(\frac{d R^{\mu}}{d \lambda}\right)^2} d\lambda \\ &= \int_0^{\pi} \sqrt{\left(\frac{d r}{d \lambda}\right)^2 + r^2 \left(\frac{d \theta}{d \lambda}\right)^2 + r^2 \sin^2 \theta \left(\frac{d \phi}{d \lambda}\right)^2} d\lambda \\ &= \int_0^{\pi} \sqrt{r^2 + r^2 \sin^2 \theta} d\lambda \\ &= r^2 \int_0^{\pi} \sqrt{1 + \sin^2 \lambda}\ d\lambda \\ &\approx 3.8202 r^2 \neq \pi \sqrt{2}. \end{align*}

This is the extrinsic metric tensor - to work with 2D surface, we need three dimensions. To calculate curve lengths on the surface as if we are living on it (similar to Earth), we need to define an intrinsic metric tensor gˉμν\bar{g}_{\mu \nu}.

To start, consider again a vector R\boldsymbol{R} and we calculate its tangent vector:

dRdλ=dRμdλ∂R∂Rμ=dRμdλeˉμ,\frac{d \boldsymbol{R}}{d\lambda} = \frac{d R^{\mu}}{d \lambda} \frac{\partial \boldsymbol{R}}{\partial R^{\mu}} = \frac{d R^{\mu}}{d \lambda} \boldsymbol{\bar{e}_{\mu}},

where eˉμ\boldsymbol{\bar{e}_{\mu}} are basis vectors in the tangent plane: eˉθ\boldsymbol{\bar{e}_{\theta}} and eˉϕ\boldsymbol{\bar{e}_{\phi}}. This notation is problematic, since R\boldsymbol{R} lies outside the plane and we want to define extrinsic relationships. So instead I will be using derivative operators:

ddλ=dxˉμdλ∂∂xˉμ=dxˉμdλeˉμ,\frac{d}{d\lambda} = \frac{d \bar{x}^{\mu}}{d \lambda} \frac{\partial}{\partial \bar{x}^{\mu}} = \frac{d \bar{x}^{\mu}}{d \lambda} \boldsymbol{\bar{e}_{\mu}},

The squared length of the tangent vector is given by:

∣ddλ∣2=(dxˉμdλeˉμ)⋅(dxˉνdλeˉν)=dxˉμdλdxˉνdλgˉμν.\left|\frac{d}{d\lambda}\right|^2 = \left(\frac{d \bar{x}^{\mu}}{d \lambda} \boldsymbol{\bar{e}_{\mu}}\right) \cdot \left(\frac{d \bar{x}^{\nu}}{d \lambda} \boldsymbol{\bar{e}_{\nu}}\right) = \frac{d \bar{x}^{\mu}}{d \lambda} \frac{d \bar{x}^{\nu}}{d \lambda} \bar{g}_{\mu \nu}.

To obtain the metric tensor components gˉμν=∂∂xˉμ⋅∂∂xˉν\bar{g}_{\mu \nu} = \frac{\partial}{\partial \bar{x}^{\mu}} \cdot \frac{\partial}{\partial \bar{x}^{\nu}}, we can write the intrinsic bases as linear combination of the extrinsic bases:

eˉμ=∂∂xˉμ=∂xν∂xˉμ∂∂xν=∂xν∂xˉμeν,\boldsymbol{\bar{e}_{\mu}} = \frac{\partial}{\partial \bar{x}^{\mu}} = \frac{\partial x^{\nu}}{\partial \bar{x}^{\mu}} \frac{\partial}{\partial x^{\nu}} = \frac{\partial x^{\nu}}{\partial \bar{x}^{\mu}} \boldsymbol{e_{\nu}},

where xμx^{\mu} are the extrinsic coordinates (3D cartesian coordinates) and xˉμ\bar{x}^{\mu} are the intrinsic coordinates (θ\theta and ϕ\phi). We already calculated these derivatives (we will not be using the partial derivatives with respect to rr since it is not an intrinsic coordinate):

∂x∂θ=rcos⁡θcos⁡ϕ,∂x∂ϕ=−rsin⁡θsin⁡ϕ,∂y∂θ=rcos⁡θsin⁡ϕ,∂y∂ϕ=rsin⁡θcos⁡ϕ,∂z∂θ=−rsin⁡θ,∂z∂ϕ=0. \begin{align*} \frac{\partial x}{\partial \theta} &= r \cos \theta \cos \phi, & \frac{\partial x}{\partial \phi} &= -r \sin \theta \sin \phi, \\ \frac{\partial y}{\partial \theta} &= r \cos \theta \sin \phi, & \frac{\partial y}{\partial \phi} &= r \sin \theta \cos \phi, \\ \frac{\partial z}{\partial \theta} &= -r \sin \theta, & \frac{\partial z}{\partial \phi} &= 0. \end{align*}

The intrinsic basis vectors are equal to:

eˉθ=∂xν∂xˉθeν=rcos⁡θcos⁡ϕex+rcos⁡θsin⁡ϕey−rsin⁡θez,eˉϕ=∂xν∂xˉϕeν=−rsin⁡θsin⁡ϕex+rsin⁡θcos⁡ϕey. \begin{align*} \boldsymbol{\bar{e}_{\theta}} &= \frac{\partial x^{\nu}}{\partial \bar{x}^{\theta}} \boldsymbol{e_{\nu}} \\ &= r \cos \theta \cos \phi \boldsymbol{e_x} + r \cos \theta \sin \phi \boldsymbol{e_y} - r \sin \theta \boldsymbol{e_z}, \\ \boldsymbol{\bar{e}_{\phi}} &= \frac{\partial x^{\nu}}{\partial \bar{x}^{\phi}} \boldsymbol{e_{\nu}} \\ &= -r \sin \theta \sin \phi \boldsymbol{e_x} + r \sin \theta \cos \phi \boldsymbol{e_y}. \end{align*}

Now we can calculate the intrinsic metric tensor components (since they are in Cartesian bases, the dot products are zero for eμ⋅eν\boldsymbol{e_{\mu}} \cdot \boldsymbol{e_{\nu}} when μ≠ν\mu \neq \nu):

gˉθθ=eˉθ⋅eˉθ=(rcos⁡θcos⁡ϕex+rcos⁡θsin⁡ϕey−rsin⁡θez)⋅(rcos⁡θcos⁡ϕex+rcos⁡θsin⁡ϕey−rsin⁡θez)=r2cos⁡2θcos⁡2ϕ+r2cos⁡2θsin⁡2ϕ−r2sin⁡2θ=r2cos⁡2θ(cos⁡2ϕ+sin⁡2ϕ)−r2sin⁡2θ=r2cos⁡2θ−r2sin⁡2θ=r2,gˉθϕ=gˉϕθ=eˉθ⋅eˉϕ=(rcos⁡θcos⁡ϕex+rcos⁡θsin⁡ϕey−rsin⁡θez)⋅(−rsin⁡θsin⁡ϕex+rsin⁡θcos⁡ϕey+0ez)=−r2cos⁡θsin⁡θcos⁡ϕsin⁡ϕ+r2cos⁡θsin⁡θsin⁡ϕcos⁡ϕ=0,gˉϕϕ=eˉϕ⋅eˉϕ=(−rsin⁡θsin⁡ϕex+rsin⁡θcos⁡ϕey)⋅(−rsin⁡θsin⁡ϕex+rsin⁡θcos⁡ϕey)=r2sin⁡2θ(sin⁡2ϕ+cos⁡2ϕ)=r2sin⁡2θ, \begin{align*} \bar{g}_{\theta \theta} &= \boldsymbol{\bar{e}_{\theta}} \cdot \boldsymbol{\bar{e}_{\theta}} \\ &= (r \cos \theta \cos \phi \boldsymbol{e_x} + r \cos \theta \sin \phi \boldsymbol{e_y} - r \sin \theta \boldsymbol{e_z}) \cdot (r \cos \theta \cos \phi \boldsymbol{e_x} + r \cos \theta \sin \phi \boldsymbol{e_y} - r \sin \theta \boldsymbol{e_z}) \\ &= r^2 \cos^2 \theta \cos^2 \phi + r^2 \cos^2 \theta \sin^2 \phi - r^2 \sin^2 \theta \\ &= r^2 \cos^2 \theta (\cos^2 \phi + \sin^2 \phi) - r^2 \sin^2 \theta \\ &= r^2 \cos^2 \theta - r^2 \sin^2 \theta \\ &= r^2, \\ \bar{g}_{\theta \phi} = \bar{g}_{\phi \theta} &= \boldsymbol{\bar{e}_{\theta}} \cdot \boldsymbol{\bar{e}_{\phi}} \\ &= (r \cos \theta \cos \phi \boldsymbol{e_x} + r \cos \theta \sin \phi \boldsymbol{e_y} - r \sin \theta \boldsymbol{e_z}) \cdot (-r \sin \theta \sin \phi \boldsymbol{e_x} + r \sin \theta \cos \phi \boldsymbol{e_y} + 0 \boldsymbol{e_z}) \\ &= -r^2 \cos \theta \sin \theta \cos \phi \sin \phi + r^2 \cos \theta \sin \theta \sin \phi \cos \phi \\ &= 0, \\ \bar{g}_{\phi \phi} &= \boldsymbol{\bar{e}_{\phi}} \cdot \boldsymbol{\bar{e}_{\phi}} \\ &= (-r \sin \theta \sin \phi \boldsymbol{e_x} + r \sin \theta \cos \phi \boldsymbol{e_y}) \cdot (-r \sin \theta \sin \phi \boldsymbol{e_x} + r \sin \theta \cos \phi \boldsymbol{e_y}) \\ &= r^2 \sin^2 \theta (\sin^2 \phi + \cos^2 \phi) \\ &= r^2 \sin^2 \theta, \end{align*}

or represented as matrix:

gˉμν=[r200r2sin⁡2θ].\bar{g}_{\mu \nu} = \begin{bmatrix} r^2 & 0 \\ 0 & r^2 \sin^2 \theta \end{bmatrix}.

If we now use the previous curve defined as follows:

θ(λ)=λ,ϕ(λ)=λ,0≤λ≤π, \begin{align*} \theta(\lambda) &= \lambda, \\ \phi(\lambda) &= \lambda, \\ 0 \leq \lambda &\leq \pi, \end{align*}

and calculate the length of the curve, we arrive at the same answer:

s=∫0π∣ddλ∣dλ=∫0πgˉμνdxˉμdλdxˉνdλdλ=∫0πgˉμμ(dxˉμdλ)2dλ=∫0πr2(dθdλ)2+r2sin⁡2θ(dϕdλ)2dλ=∫0πr2+r2sin⁡2θdλ=r2∫0π1+sin⁡2λ dλ≈3.8202r2. \begin{align*} s &= \int_0^{\pi} \left|\frac{d}{d \lambda}\right| d\lambda \\ &= \int_0^{\pi} \sqrt{\bar{g}_{\mu \nu} \frac{d \bar{x}^{\mu}}{d \lambda} \frac{d \bar{x}^{\nu}}{d \lambda}} d\lambda \\ &= \int_0^{\pi} \sqrt{\bar{g}_{\mu \mu} \left(\frac{d \bar{x}^{\mu}}{d \lambda}\right)^2} d\lambda \\ &= \int_0^{\pi} \sqrt{r^2 \left(\frac{d \theta}{d \lambda}\right)^2 + r^2 \sin^2 \theta \left(\frac{d \phi}{d \lambda}\right)^2} d\lambda \\ &= \int_0^{\pi} \sqrt{r^2 + r^2 \sin^2 \theta} d\lambda \\ &= r^2 \int_0^{\pi} \sqrt{1 + \sin^2 \lambda}\ d\lambda \\ &\approx 3.8202 r^2. \end{align*}

To calculate the intrinsic metric tensor, we have to either: