Visualizing Precession in Schwarzschild Spacetime¶

Importing required modules¶

In [1]:
import numpy as np

from einsteinpy.geodesic import Timelike
from einsteinpy.plotting.geodesic import GeodesicPlotter


Setting up the system¶

• Initial position & momentum of the test partcle
• Spin of the Schwarzschild Black Hole (= 0)
• Other solver parameters

Note that, we are working in M-Units ($G = c = M = 1$). Also, since the Schwarzschild spacetime has spherical symmetry, the values of the angular components do not affect the end result (We can always rotate our coordinate system to bring the geodesic in the equatorial plane). Hence, we set $\theta = \pi / 2$ (equatorial plane), with initial $p_\theta = 0$, which implies, that the geodesic should stay in the equatorial plane.

In [2]:
position = [40., np.pi / 2, 0.]
momentum = [0., 0., 3.83405]
a = 0.
steps = 5500
delta = 1.


Calculating the geodesic¶

In [3]:
geod = Timelike(
metric="Schwarzschild",
metric_params=(a,),
position=position,
momentum=momentum,
steps=steps,
delta=delta,
return_cartesian=True
)


Plotting the geodesic¶

In [4]:
gpl = GeodesicPlotter()
gpl.plot(geod)
gpl.show()