Metric tensor

The metric tensor's elements are the coefficients read off of the line element

d s 2 = g μ ν d x μ d x ν {\displaystyle ds^{2}=g_{\mu \nu }dx^{\mu }dx^{\nu }}

For special relativity rectilinear coordinate inertial frames are used which given

x 0 = c t {\displaystyle x^{0}=ct}

x 1 = x {\displaystyle x^{1}=x}

x 2 = y {\displaystyle x^{2}=y}

x 3 = z {\displaystyle x^{3}=z}

the metric tensor will be designated  η μ ν {\displaystyle \eta _{\mu \nu }} and the line element will be

d s 2 = d c t 2 − ( d x 2 + d y 2 + d z 2 ) {\displaystyle ds^{2}=dct^{2}-\left(dx^{2}+dy^{2}+dz^{2}\right)}

and the Minkowski metric tensor elements given by

η 00 = 1 {\displaystyle \eta _{00}=1}

η 11 = η 22 = η 33 = − 1 {\displaystyle \eta _{11}=\eta _{22}=\eta _{33}=-1}

All other elements are 0.

Written as a matrix this is

| | η μ ν | | = [ 1 0 0 0 0 − 1 0 0 0 0 − 1 0 0 0 0 − 1 ] {\displaystyle ||\eta _{\mu \nu }||={\begin{bmatrix}1&0&0&0\\\0&-1&0&0\\\0&0&-1&0\\\0&0&0&-1\end{bmatrix}}}

The metric tensor acts a an index raising

T μ = g μ ν T ν {\displaystyle T^{\mu }=g^{\mu \nu }T_{\nu }}

and lowering

T μ = g μ ν T ν {\displaystyle T_{\mu }=g_{\mu \nu }T^{\nu }}

opperator. And as an inner product operator in 4d spacetime

U μ T μ = g λ μ U μ T λ {\displaystyle U^{\mu }T_{\mu }=g_{\lambda \mu }U^{\mu }T^{\lambda }}

There is an inverse relationship between the contravariant and covariant metric tensor elements

g μ λ g λ ν = δ μ ν {\displaystyle g_{\mu \lambda }g^{\lambda \nu }=\delta _{\mu }^{\nu }}

which can be expressed as the matrix

| | g μ λ g λ ν | | = [ 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 ] {\displaystyle ||g_{\mu \lambda }g^{\lambda \nu }||={\begin{bmatrix}1&0&0&0\\\0&1&0&0\\\0&0&1&0\\\0&0&0&1\end{bmatrix}}}

So solving for the contravariant metric tensor elements given the covariant ones and vica-versa can be done by simple matrix inversion.

The covariant derivative of the metric with respect to any coordinate is zero

g μ ν ; λ = 0 {\displaystyle g_{\mu \nu };_{\lambda }=0}

g μ ν ; λ = 0 {\displaystyle g^{\mu \nu };_{\lambda }=0}

where the covariant derivative is done with the use of Christoffel symbols. And so of course the covariant divergence of the metric is also zero

g μ ν ; ν = 0 {\displaystyle g^{\mu \nu };_{\nu }=0}