# Lemaître-Tolman solutions¶

This Jupyter/SageMath worksheet is relative to the lectures Introduction to black hole physics

These computations are based on SageManifolds (version 1.0, as included in SageMath 7.5)

Click here to download the worksheet file (ipynb format). To run it, you must start SageMath with the Jupyter notebook, with the command sage -n jupyter

NB: a version of SageMath at least equal to 7.5 is required to run this worksheet:

In [1]:
version()

Out[1]:
'SageMath version 8.0.beta6, Release Date: 2017-05-12'

First we set up the notebook to display mathematical objects using LaTeX rendering:

In [2]:
%display latex


## Spacetime¶

We declare the spacetime manifold $M$:

In [3]:
M = Manifold(4, 'M')
print(M)

4-dimensional differentiable manifold M


and declare the chart of Lemaître synchronous coordinates on it:

In [4]:
X.<t,x,th,ph> = M.chart(r't:\tau x:(0,+oo):\chi th:(0,pi):\theta ph:(0,2*pi):\phi')
X

Out[4]:

The most general metric tensor, assuming spherical symmetry and synchronous coordinates:

In [5]:
g = M.lorentzian_metric('g')
a = function('a')
r = function('r')
g[0,0] = -1
g[1,1] = a(t,x)^2
g[2,2] = r(t,x)^2
g[3,3] = (r(t,x)*sin(th))^2
g.display()

Out[5]:

## Einstein equation¶

The cosmological constant:

In [6]:
var('Lamb', latex_name='\Lambda')

Out[6]:

The Ricci tensor:

In [7]:
Ric = g.ricci()
print(Ric)

Field of symmetric bilinear forms Ric(g) on the 4-dimensional differentiable manifold M

In [8]:
Ric.display()

Out[8]:

The Einstein tensor:

In [9]:
G = Ric - 1/2*g.ricci_scalar() * g
G.set_name('G')
print(G)

Field of symmetric bilinear forms G on the 4-dimensional differentiable manifold M

In [10]:
G.display_comp()

Out[10]:

### Dust matter model¶

Let us consider a pressureless fluid ("dust"). Moreover, we assume that the coordinates $(\tau,\chi,\theta,\phi)$ are comoving, i.e. that the fluid 4-velocity is equal to $\partial_\tau$:

In [11]:
u = M.vector_field('u')
u[0] = 1
u.display()

Out[11]:

Since $(\tau,\chi,\theta,\chi)$ are synchronous, the above does define a unit timelike vector:

In [12]:
g(u,u).display()

Out[12]:

The 1-form associated to the fluid 4-velocity by metric duality:

In [13]:
u_form = u.down(g)
print(u_form)

1-form on the 4-dimensional differentiable manifold M

In [14]:
u_form.display()

Out[14]:

The pressureless energy-momentum tensor:

In [15]:
rho = function('rho')
T = rho(t,x)*(u_form * u_form)
T.set_name('T')
print(T)

Field of symmetric bilinear forms T on the 4-dimensional differentiable manifold M

In [16]:
T.display()

Out[16]:

The Einstein equation:

In [17]:
E = G + Lamb*g - 8*pi*T
E.set_name('E')
print(E)

Field of symmetric bilinear forms E on the 4-dimensional differentiable manifold M

In [18]:
E.display_comp()

Out[18]:

## Solving the Einstein equation¶

### $\tau\chi$ component¶

Let us first consider the $01 = \tau\chi$ component of the Einstein equation:

In [19]:
E[0,1]

Out[19]:

A slight rearrangement of the equation:

In [20]:
eq = E[0,1]*r(t,x)/(-2*a(t,x))
eq

Out[20]:

We see that this equation is equivalent to $$\frac{\partial}{\partial\tau} \left( \frac{1}{a}\frac{\partial r}{\partial\chi} \right) = 0$$ since

In [21]:
drdx = diff(r(t,x), x)
eq - diff(drdx/a(t,x), t)

Out[21]:

Hence there exists a function of $\chi$ only, $f(\chi)$ say, such that $\frac{1}{a}\frac{\partial r}{\partial\chi} = f(\chi)$. We disregard the case $f(\chi)=0$, which would imply $\frac{\partial r}{\partial\chi}=0$ and would lead to the so-called Datt model (1938). Accordingly, we may write $$a(\tau,\chi) = \frac{1}{f(\chi)}\frac{\partial r}{\partial\chi}$$ Let us call af this expression of $a$:

In [22]:
f = function('f')
af(t,x) = drdx / f(x)
af(t,x)

Out[22]:

We check that if we substitute $a$ by af in the $\tau\chi$ component of the Einstein equation, we get identically zero:

In [23]:
E[0,1].expr().substitute_function(a, af)

Out[23]:

NB: expr() returns a Sage symbolic expression from the coordinate function E[0,1], so that we may apply substitute_function

Hence the first Lemaitre-Tolman equation is

In [24]:
LT1 = a(t,x) == af(t,x)
LT1

Out[24]:

### $\chi\chi$ component¶

The $11 = \chi\chi$ component of Einstein equation is

In [25]:
E[1,1]

Out[25]:

It is equivalent to

In [26]:
eq = (- E[1,1] * r(t,x)^2).expr() == 0
eq

Out[26]:

Let us substitute for $a(\tau,\chi)$ the value found above when solving the $\tau\chi$ component:

In [27]:
eq1 = eq.substitute_function(a, af)
eq1

Out[27]:

Some slight rearrangement and simplification:

In [28]:
eq2 = (eq1 * f(x)^2 / diff(r(t,x), x)^2).simplify_full()
eq2

Out[28]:
In [29]:
eq3 = (eq2 * diff(r(t,x),t)).simplify_full()
eq3

Out[29]:

We notice that the left-hand side of this equation is nothing but the partial derivative w.r.t. $\tau$ of the following quantity:

In [30]:
A = (diff(r(t,x),t)^2 + 1 - f(x)^2 - (Lamb/3)*r(t,x)^2) * r(t,x)
A

Out[30]:
In [31]:
bool(eq3.lhs() == diff(A, t))

Out[31]:

Hence eq3 tells that $A$ is independent of $\tau$, i.e. is a function of $\chi$ only, which we call $2 m(\chi)$:

In [32]:
m = function('m')
eq4 = A - 2*m(x) == 0
eq4

Out[32]:

Let us solve extract $(\partial r/\partial\tau)^2$ from this equation:

In [33]:
drdt2_sol = solve(eq4, diff(r(t,x),t)^2)
drdt2_sol

Out[33]:

We thus obtain the second Lemaitre-Tolman equation:

In [34]:
LT2 = drdt2_sol[0].expand()
LT2

Out[34]:
In [35]:
drdt2 = LT2.rhs()
drdt2

Out[35]:

### $\tau\tau$ component¶

The $00 = \tau\tau$ component of Einstein equation is

In [36]:
E[0,0]

Out[36]:

It is equivalent to

In [37]:
eq = (- E[0,0] * a(t,x)^3 * r(t,x)^2).expr() == 0
eq

Out[37]:

As above, we substitute for $a(\tau,\chi)$ the value found when solving the $\tau\chi$ component:

In [38]:
eq1 = eq.substitute_function(a, af)
eq1

Out[38]:
In [39]:
eq2 = (eq1 * f(x)^3).simplify_full()
eq2

Out[39]:

Let us substitute for $\partial r/\partial \tau$ the positive square root of the value of $(\partial r/\partial \tau)^2$ found when solving the $\chi\chi$ component:

In [40]:
drdt = sqrt(drdt2)
drdt

Out[40]:
In [41]:
eq3 = eq2.subs({diff(r(t,x),t): drdt, diff(r(t,x),t,x): diff(drdt, x)}).simplify_full()
eq3

Out[41]:

If we use the negative square root of $(\partial r/\partial \tau)^2$ instead, we get the same result:

In [42]:
drdt = - sqrt(drdt2)
drdt

Out[42]:
In [43]:
eq3_minus = eq2.subs({diff(r(t,x),t): drdt, diff(r(t,x),t,x): diff(drdt, x)}).simplify_full()
eq3_minus

Out[43]:
In [44]:
eq3_minus == eq3

Out[44]:

Thus we continue with eq3 and rearrange it to get the third Lemaitre-Tolman equation:

In [45]:
eq4 = (eq3 / (2*diff(r(t,x),x)^2)).simplify_full()
eq4

Out[45]:
In [46]:
dmdx_sol = solve(eq4, diff(m(x),x))
dmdx_sol

Out[46]:
In [47]:
LT3 = dmdx_sol[0]
LT3

Out[47]:

### $\theta\theta$ and $\phi\phi$ components¶

First we notice that the $\theta\theta$ and $\phi\phi$ components of the Einstein equation are equivalent:

In [48]:
E[3,3] == E[2,2] * sin(th)^2

Out[48]:

Let us thus consider only the $22 = \theta\theta$ component:

In [49]:
E[2,2]

Out[49]:

It is equivalent to

In [50]:
eq = (- E[2,2] * a(t,x)^3).expr() == 0
eq

Out[50]:

We substitute for $a(\tau,\chi)$ the value found when solving the $\tau\chi$ component:

In [51]:
eq1 = eq.substitute_function(a, af).simplify_full()
eq1

Out[51]:
In [52]:
eq2 = (eq1 * f(x)^3).simplify_full()
eq2

Out[52]:

Then we substitute for $\partial r/\partial\tau$ the value obtained when solving the $\tau\tau$ component:

In [53]:
eq3 = eq2.subs({diff(r(t,x),t,t,x): diff(drdt,t,x), diff(r(t,x),t,t): diff(drdt,t)}).simplify_full()
eq4 = eq3.subs({diff(r(t,x),t): drdt, diff(r(t,x),t,x): diff(drdt,x)}).simplify_full()
eq4

Out[53]:

We conclude that the $\theta\theta$ component of Einstein equation does add any independent equation.

## Summary¶

Let us collect the three independent equations obtained from the Einstein equation, constituting the Lemaître-Tolman system:

In [54]:
for eq in [LT1, LT2, LT3]:
show(eq)


The first equation is the unnumbered one just above Eq. (8.1) in Lemaître's article L'univers en expansion, Annales de la Société Scientifique de Bruxelles A 53, 51 (1933), translated in English in Gen. Relativ. Gravit. 29, 641 (1997). The second equation is Eq. (8.2) in Lemaître's article, while the third one is Eq. (8.3).

In [ ]: