The Schwarzschild spacetime

This notebook shows how you can do component computations in Cadabra. It illustrates this by computing
properties of the Schwarzschild spacetime.
The first thing we always need to do is to declare the coordinates used, and the names of the indices.

Below is the Schwarzschild metric in standard coordinates. Note how the components are
given in terms of substitution rules, and how the inverse metric is computed.
The complete algorithm adds the rules for the inverse metric to the rules for the metric.

We can now compute the Christoffel symbols. We give Cadabra the expression for the
Christoffel symbols in terms of the metric, and then evaluate the components of the
metric using the evaluate algorithm.

Continuing from here we can compute the Riemann tensor components. Again, we start
by giving this tensor in terms of the Christoffel symbols. We then subsitute the
Christoffel symbols just found, and work out any remaining component substitions using
evaluate (the computation takes a few seconds, essentially because of the round
trips through Sympy).

You could have computed the Riemann tensor in a different way, first expanding it fully in terms of the metric tensor,
and then substituting the components. This is a bit more wasteful on resources, but of course gives the same result: