This Jupyter/SageMath notebook is relative to the lectures Geometry and physics of black holes.
The computations make use of tools developed through the SageManifolds project.
version()
'SageMath version 10.2.beta8, Release Date: 2023-10-21'
%display latex
M = Manifold(4, 'M', structure='Lorentzian')
print(M)
4-dimensional Lorentzian manifold M
XN.<v,r,th,ph> = M.chart(r'v:(0,+oo) r:(0,+oo) th:(0,pi):\theta ph:(0,2*pi):\varphi:periodic')
XN
graph = plot((1 - sqrt(1 - 8*x))/(2*x), (x, 0.001, 1/8), color='blue',
legend_label=r'$x_1$', axes_labels=[r'$\alpha$', ''])
graph += plot((1 + sqrt(1 - 8*x))/(2*x), (x, 0.08, 1/8), color='red',
legend_label=r'$x_2$')
graph.show(frame=True, gridlines=True)
x1 = var('x1', latex_name=r'x_1', domain='real')
assume(x1 > 2, x1 < 4)
x2 = var('x2', latex_name=r'x_2', domain='real')
assume(x2 > 4)
alpha = 2/(x1*x2)
alpha
g = M.metric()
g[0,0] = -(1 - alpha*v/r)
g[0,1] = 1
g[2,2] = r^2
g[3,3] = (r*sin(th))^2
g.display()
N1 = M.open_subset('N1', latex_name=r'N_1',
coord_def={XN: r > v/x2})
X1.<u,v,th,ph> = N1.chart(r'u v:(0,+oo) th:(0,pi):\theta ph:(0,2*pi):\varphi:periodic')
X1
assume(x2*r - v > 0)
XN_to_X1 = XN.transition_map(X1, ((v/x1 - r)/((r - v/x2))^(x1/x2),
v, th, ph))
XN_to_X1.display()
g.display_comp(X1.frame(), chart=XN.restrict(N1))
g[X1.frame(),0,1].expr()
To simplify the components of $g$, let us substitute $x_2$ by its expression in terms of $x_1$, i.e. $x_2 = \frac{2 x_1}{x_1 - 2}$:
xx2 = 2*x1/(x1 - 2)
g.apply_map(lambda x: x.subs({x2: xx2}).simplify_full(),
frame=X1.frame(), chart=XN.restrict(N1),
keep_other_components=True)
g.display_comp(X1.frame(), chart=XN.restrict(N1))
Alternative form of $g_{uv}$:
guv = g[X1.frame(),0,1].expr()
guv
guv_alt = - x2/(x2 - x1)/r*(r - v/x2)^(x1/2)
guv_alt
Test:
s = guv - guv_alt.subs({x2: xx2})
s.simplify_full().canonicalize_radical()
Inverse metric in terms of the coordinates $(u,v,\theta,\varphi)$, taking into account the identity $x_2 = \frac{2 x_1}{x_1 - 2}$:
g.inverse().apply_map(lambda x: x.subs({x2: xx2}).simplify_full(),
frame=X1.frame(), chart=XN.restrict(N1),
keep_other_components=True)
g.inverse()[X1.frame(),:,XN.restrict(N1)]
We note that $g^{uu} = 0$ and $g^{vv} = 0$, which proves that the hypersurfaces of constant $u$ are null, as well as the hypersurfaces of constant $v$, i.e. that $(u,v,\theta,\varphi)$ is a double-null coordinate system on $N_1$.
u_vr = XN_to_X1(v, r, th, ph)[0]
u_vr
u_vr1 = u_vr.subs({x1: 3, x2: 6})
u_vr1
u_vr1^2
Solving for $r$ in terms of $(u,v)$:
eq = u^2 == u_vr1^2
eq
solve(eq, r)
ruv = solve(eq, r)[0].rhs()
ruv
Recovering Fig. 3a of B. Waugh and K. Lake, Phys. Rev. D 34, 2978 (1986):
contour_plot(ruv, (v, 0, 9), (u, -3, 9.5), cmap=['black'],
contours=(0.1, 0.2, 0.5, 1., 5), fill=False,
axes_labels=(r'$v$', r'$u$'), axes=True)
plot3d(ruv, (u, -2, 9.5), (v, 0, 9), axes_labels=('u', 'v', 'r'))
ruv.series(v, 3)
N2 = M.open_subset('N2', latex_name=r'N_2',
coord_def={XN: r < v/x1})
X2.<u,v,th,ph> = N2.chart(r'u v:(0,+oo) th:(0,pi):\theta ph:(0,2*pi):\varphi:periodic')
X2
assume(v - x1*r > 0)
XN_to_X2 = XN.transition_map(X2, ((v/x2 - r)/((v/x1 - r))^(x2/x1),
v, th, ph))
XN_to_X2.display()
g.display_comp(X2.frame(), chart=XN.restrict(N2))
g[X2.frame(),0,1].expr()
To simplify the components of $g$, let us substitute $x_1$ by its expression in terms of $x_2$, i.e. $x_1 = \frac{2 x_2}{x_2 - 2}$:
xx1 = 2*x2/(x2 - 2)
g.apply_map(lambda x: x.subs({x1: xx1}).simplify_full(),
frame=X2.frame(), chart=XN.restrict(N2),
keep_other_components=True)
g.display_comp(X2.frame(), chart=XN.restrict(N2))
Alternative form of $g_{uv}$:
guv = g[X2.frame(),0,1].expr()
guv
guv_alt = - x1/(x2 - x1)/r*(v/x1 - r)^(x2/2)
guv_alt
Test:
s = guv - guv_alt.subs({x1: xx1})
s.simplify_full().canonicalize_radical()
Inverse metric in terms of the coordinates $(u,v,\theta,\varphi)$, taking into account the identity $x_1 = \frac{2 x_2}{x_2 - 2}$:
g.inverse().apply_map(lambda x: x.subs({x1: xx1}).simplify_full(),
frame=X2.frame(), chart=XN.restrict(N2),
keep_other_components=True)
g.inverse()[X2.frame(),:,XN.restrict(N2)]
We note that $g^{uu} = 0$ and $g^{vv} = 0$, which proves that the hypersurfaces of constant $u$ are null, as well as the hypersurfaces of constant $v$, i.e. that $(u,v,\theta,\varphi)$ is a double-null coordinate system on $N_2$.
u_vr = XN_to_X2(v, r, th, ph)[0]
u_vr
u_vr1 = u_vr.subs({x1: 3, x2: 6})
u_vr1
Solving for $r$ in terms of $(u,v)$:
eq = u == u_vr1
solve(eq, r)
ruv = solve(eq, r)[1].rhs()
ruv
ruv_alt = v/3 + (sqrt(1 - 2*u*v/3) - 1)/(2*u)
ruv_alt
(ruv - ruv_alt).simplify_full().canonicalize_radical()
ruv_alt.series(u, 2)
ruv_alt.series(v, 3)
Recovering Fig. 3b of B. Waugh and K. Lake, Phys. Rev. D 34, 2978 (1986):
contour_plot(ruv, (v, 0, 14), (u, -10, 5), cmap=['black'],
contours=(0, 0.05, 0.1, 0.2, 0.5, 1., 2.), fill=False,
axes_labels=(r'$v$', r'$u$'), axes=True)
plot3d(ruv, (u, -10, 5), (v, 0, 14), axes_labels=('u', 'v', 'r'))