Calling Sequences

Parameters

NT      - a null tetrad for the spacetime metric $g$

PT      -  the Petrov type of $g$

W       - (optional) the Weyl tensor of $g$

NP      - (optional) the Newman-Penrose Weyl scalars

options - one or more of the keyword arguments method and output

Description

 • The Newman-Penrose Weyl scalars are a set of 5 complex scalars, labeled ${\mathrm{Ψ}}_{0}$, , and defined by certain components of the Weyl tensor with respect to a given null tetrad in a four dimensional spacetime of signature [1, -1, -1, -1]. Under local Lorentz transformations, the Newman-Penrose Weyl scalars transform among themselves in a natural way. Depending upon the Petrov type of the spacetime it is possible to transform the Newman-Penrose Weyl scalars to one of following normal forms. Below, and are complex scalars.See NPCurvatureScalars, NullTetradTransformation.

Type I.

Type II. ${\mathrm{Ψ}}_{0}$

Type III.

Type D.

Type N.

Type O.

See Penrose and Rindle Vol. 2, Section 8.3.

 • Null tetrads for which the Newman-Penrose Weyl scalars are in the above normal form are called adapted null tetrads. Calculations are often simplified by using an adapted null tetrad.
 • The command AdaptedNullTetrad returns a null tetrad which will put the Newman-Penrose Weyl scalars in the above normal form.
 • The command AdaptedNullTetrad is part of the DifferentialGeometry:-Tensor package. It can be used in the form AdaptedNullTetrad(...) only after executing the commands with(DifferentialGeometry) and with(Tensor), but can always be used by executing DifferentialGeometry:-Tensor:-AdaptedNullTetrad(...).

Examples

 > $\mathrm{with}\left(\mathrm{DifferentialGeometry}\right):$$\mathrm{with}\left(\mathrm{Tensor}\right):$

Set the global environment variable _EnvExplicit to true to insure that the adapted null tetrads are free of expressions.

 > $\mathrm{_EnvExplicit}≔\mathrm{true}:$

Example 1. Type I

We calculate an adapted null tetrad for a type spacetime. First define the coordinates to be used and then define the metric.

 > $\mathrm{DGsetup}\left(\left[t,x,y,z\right],M\right)$
 ${\mathrm{frame name: M}}$ (2.1)
 M > $\mathrm{g1}≔\mathrm{evalDG}\left(\mathrm{dt}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dt}-{t}^{2}\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}-{x}^{2}\mathrm{dy}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dy}-\mathrm{dz}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dz}\right)$
 ${\mathrm{g1}}{:=}{\mathrm{dt}}{}{\mathrm{dt}}{-}\left(\left({{t}}^{{2}}{}{\mathrm{dx}}\right){}{\mathrm{dx}}\right){-}\left(\left({{x}}^{{2}}{}{\mathrm{dy}}\right){}{\mathrm{dy}}\right){-}\left({\mathrm{dz}}{}{\mathrm{dz}}\right)$ (2.2)

Here is an initial null tetrad.

 > $\mathrm{NT1}≔\mathrm{evalDG}\left(\left[\mathrm{D_t}+\mathrm{D_z},\frac{1}{2}\left(\mathrm{D_t}-\mathrm{D_z}\right),\frac{\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_x}}{t}+\frac{\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{D_y}}{x},\frac{\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_x}}{t}-\frac{\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{D_y}}{x}\right]\right)$
 ${\mathrm{NT1}}{:=}\left[{\mathrm{D_t}}{+}{\mathrm{D_z}}{,}\frac{{1}}{{2}}{}{\mathrm{D_t}}{-}\left(\frac{{1}}{{2}}{}{\mathrm{D_z}}\right){,}\frac{\sqrt{{2}}}{{2}{}{t}}{}{\mathrm{D_x}}{+}\frac{\frac{{I}}{{2}}{}\sqrt{{2}}}{{x}}{}{\mathrm{D_y}}{,}\frac{\sqrt{{2}}}{{2}{}{t}}{}{\mathrm{D_x}}{-}\left(\frac{\frac{{I}}{{2}}{}\sqrt{{2}}}{{x}}{}{\mathrm{D_y}}\right)\right]$ (2.3)

We check that this is indeed a null tetrad for the given metric using GRQuery.

 M > $\mathrm{GRQuery}\left(\mathrm{NT1},\mathrm{g1},"NullTetrad"\right)$
 ${\mathrm{true}}$ (2.4)

Compute the Newman-Penrose coefficients and check that the Petrov type is I. The coefficients are not in normal form for type I (for example, ), so is not an adapted null tetrad.

 M > $\mathrm{NP1}≔\mathrm{NPCurvatureScalars}\left(\mathrm{NT1},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{NP1}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{-}\frac{{1}}{{4}}{}\frac{\sqrt{{2}}}{{x}{}{{t}}^{{2}}}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{0}{,}{"Psi4"}{=}{0}{,}{"Psi3"}{=}{-}\frac{{1}}{{8}}{}\frac{\sqrt{{2}}}{{x}{}{{t}}^{{2}}}\right]\right)$ (2.5)
 M > $\mathrm{PetrovType}\left(\mathrm{NP1}\right)$
 ${"I"}$ (2.6)

 > $\mathrm{newNT1}≔\mathrm{combine}\left(\mathrm{AdaptedNullTetrad}\left(\mathrm{NT1},"I"\right),\mathrm{symbolic}\right)$
 ${\mathrm{newNT1}}{:=}\left[\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_t}}{-}\left(\frac{\sqrt{{2}}}{{2}{}{t}}{}{\mathrm{D_x}}\right){,}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_t}}{+}\frac{\sqrt{{2}}}{{2}{}{t}}{}{\mathrm{D_x}}{,}\frac{\frac{{1}}{{2}}{+}\frac{{I}}{{2}}}{{x}}{}{\mathrm{D_y}}{+}\left(\frac{{1}}{{2}}{-}\frac{{I}}{{2}}\right){}{\mathrm{D_z}}{,}\frac{\frac{{1}}{{2}}{-}\frac{{I}}{{2}}}{{x}}{}{\mathrm{D_y}}{+}\left(\frac{{1}}{{2}}{+}\frac{{I}}{{2}}\right){}{\mathrm{D_z}}\right]$ (2.7)

Calculate the Newman-Penrose coefficients for the new null tetrad. We obtain the correct normal form (with since  and .

 M > $\mathrm{newNP1}≔\mathrm{NPCurvatureScalars}\left(\mathrm{newNT1},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{newNP1}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{-}\frac{\frac{{1}}{{2}}{}{I}}{{{t}}^{{2}}{}{x}}{,}{"Psi2"}{=}{0}{,}{"Psi4"}{=}{-}\frac{\frac{{1}}{{2}}{}{I}}{{{t}}^{{2}}{}{x}}{,}{"Psi3"}{=}{0}\right]\right)$ (2.8)

Example 2. Type II

We calculate an adapted null tetrad for a type spacetime. First define the coordinates to be used and then define the metric.

 > $\mathrm{DGsetup}\left(\left[r,u,x,y\right],M\right)$
 ${\mathrm{frame name: M}}$ (2.9)
 M > $\mathrm{g2}≔\mathrm{evalDG}\left(-\frac{2{r}^{2}}{{\left(2x\right)}^{3}}\left(\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}+\mathrm{dy}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dy}\right)+2\mathrm{du}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&s\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dr}-\left(32x+\frac{2m}{r}\right)\mathrm{du}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{du}\right)$
 ${\mathrm{g2}}{:=}{\mathrm{dr}}{}{\mathrm{du}}{+}{\mathrm{du}}{}{\mathrm{dr}}{-}\left(\left(\frac{{2}{}\left({3}{}{x}{}{r}{+}{m}\right)}{{r}}{}{\mathrm{du}}\right){}{\mathrm{du}}\right){-}\left(\left(\frac{{{r}}^{{2}}}{{4}{}{{x}}^{{3}}}{}{\mathrm{dx}}\right){}{\mathrm{dx}}\right){-}\left(\left(\frac{{{r}}^{{2}}}{{4}{}{{x}}^{{3}}}{}{\mathrm{dy}}\right){}{\mathrm{dy}}\right)$ (2.10)

Here is an initial null tetrad.

 M > $\mathrm{NT2}≔\mathrm{evalDG}\left(\left[\mathrm{D_r},\frac{\left(3xr+m\right)\mathrm{D_r}}{r}+\mathrm{D_u},\frac{I\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_x}}{r}+\frac{\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_y}}{r},-\frac{I\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_x}}{r}+\frac{\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_y}}{r}\right]\right)$
 ${\mathrm{NT2}}{:=}\left[{\mathrm{D_r}}{,}\frac{{3}{}{x}{}{r}{+}{m}}{{r}}{}{\mathrm{D_r}}{+}{\mathrm{D_u}}{,}\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}{+}\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}{,}{-}\left(\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}\right){+}\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}\right]$ (2.11)

We check that this is indeed a null tetrad for the given metric.

 M > $\mathrm{GRQuery}\left(\mathrm{NT2},\mathrm{g2},"NullTetrad"\right)$
 ${\mathrm{true}}$ (2.12)

Compute the Newman-Penrose coefficients and check that the Petrov type is II. The coefficients are not in normal form for type II (for example, ), so is not an adapted null tetrad.

 M > $\mathrm{NP2}≔\mathrm{NPCurvatureScalars}\left(\mathrm{NT2},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{NP2}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{-}\frac{{m}}{{{r}}^{{3}}}{,}{"Psi4"}{=}\frac{{18}{}{{x}}^{{2}}}{{{r}}^{{2}}}{,}{"Psi3"}{=}{-}\frac{{3}{}{I}{}\sqrt{{2}}{}{{x}}^{{3}{/}{2}}}{{{r}}^{{2}}}\right]\right)$ (2.13)
 M > $\mathrm{PetrovType}\left(\mathrm{NP2}\right)$
 ${"II"}$ (2.14)

Calculate an adapted null tetrad. We use the third calling sequence so that the Weyl tensor, or equivalently, the Newman-Penrose Weyl scalars need not be computed. Moreover, all computations are then algebraic and we can use Maple's assuming feature to simplify all intermediate calculations.

 > $\mathrm{newNT2}≔\mathrm{AdaptedNullTetrad}\left(\mathrm{NT2},"II",\mathrm{NP2}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{assuming}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}0
 ${\mathrm{newNT2}}{:=}\left[{-}\left(\frac{\sqrt{{r}}{}\sqrt{{2}{}{x}{}{r}{-}{3}{}{m}}{}{x}}{{m}}{}{\mathrm{D_r}}\right){,}{-}\left(\frac{{2}{}{{r}}^{{3}}{}{{x}}^{{3}}{+}{3}{}{{m}}^{{2}}{}{r}{}{x}{+}{{m}}^{{3}}}{{{r}}^{{3}}{{2}}}{}\sqrt{{2}{}{x}{}{r}{-}{3}{}{m}}{}{x}{}{m}}{}{\mathrm{D_r}}\right){-}\left(\frac{{m}}{\sqrt{{r}}{}\sqrt{{2}{}{x}{}{r}{-}{3}{}{m}}{}{x}}{}{\mathrm{D_u}}\right){-}\left(\frac{{4}{}{{x}}^{{2}}}{\sqrt{{r}}{}\sqrt{{2}{}{x}{}{r}{-}{3}{}{m}}}{}{\mathrm{D_x}}\right){,}{-}\left(\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}{}{r}}{{m}}{}{\mathrm{D_r}}\right){-}\left(\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}\right){-}\left(\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}\right){,}\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}{}{r}}{{m}}{}{\mathrm{D_r}}{+}\frac{{I}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}{-}\left(\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}\right)\right]$ (2.15)

Calculate the Newman-Penrose coefficients for the new null tetrad. We obtain the correct normal form (with ) since  and.

 M > $\mathrm{newNP2}≔\mathrm{NPCurvatureScalars}\left(\mathrm{newNT2},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{newNP2}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{-}\frac{{m}}{{{r}}^{{3}}}{,}{"Psi4"}{=}{-}\frac{{6}{}{m}}{{{r}}^{{3}}}{,}{"Psi3"}{=}{0}\right]\right)$ (2.16)

Example 3. Type III

We calculate an adapted null tetrad for a type spacetime. First define the coordinates to be used and then define the metric.

 > $\mathrm{DGsetup}\left(\left[r,u,x,y\right],M\right)$
 ${\mathrm{frame name: M}}$ (2.17)
 M > $\mathrm{g3}≔\mathrm{evalDG}\left(-\frac{{r}^{2}}{{x}^{3}}\left(\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}+\mathrm{dy}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dy}\right)+2\mathrm{du}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&s\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dr}-\frac{3}{2}x\mathrm{du}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{du}\right)$
 ${\mathrm{g3}}{:=}{\mathrm{dr}}{}{\mathrm{du}}{+}{\mathrm{du}}{}{\mathrm{dr}}{-}\left(\left(\frac{{3}{}{x}}{{2}}{}{\mathrm{du}}\right){}{\mathrm{du}}\right){-}\left(\left(\frac{{{r}}^{{2}}}{{{x}}^{{3}}}{}{\mathrm{dx}}\right){}{\mathrm{dx}}\right){-}\left(\left(\frac{{{r}}^{{2}}}{{{x}}^{{3}}}{}{\mathrm{dy}}\right){}{\mathrm{dy}}\right)$ (2.18)

Here is an initial null tetrad.

 > $\mathrm{NT3}≔\mathrm{evalDG}\left(\left[\left(\frac{3}{8}x+\frac{1}{2}\right)\mathrm{D_r}+\frac{1}{2}\mathrm{D_u}+\frac{\frac{1}{2}\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_y}}{r},\left(\frac{3}{8}x+\frac{1}{2}\right)\mathrm{D_r}+\frac{1}{2}\mathrm{D_u}-\frac{\frac{1}{2}\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_y}}{r},\left(-\frac{3}{8}x+\frac{1}{2}\right)\mathrm{D_r}-\frac{1}{2}\mathrm{D_u}+\frac{\frac{1}{2}I\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_x}}{r},\left(-\frac{3}{8}x+\frac{1}{2}\right)\mathrm{D_r}-\frac{1}{2}\mathrm{D_u}-\frac{\frac{1}{2}I\mathrm{sqrt}\left(2\right){x}^{\frac{3}{2}}\mathrm{D_x}}{r}\right]\right)$
 ${\mathrm{NT3}}{:=}\left[\left(\frac{{3}{}{x}}{{8}}{+}\frac{{1}}{{2}}\right){}{\mathrm{D_r}}{+}\frac{{1}}{{2}}{}{\mathrm{D_u}}{+}\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{2}{}{r}}{}{\mathrm{D_y}}{,}\left(\frac{{3}{}{x}}{{8}}{+}\frac{{1}}{{2}}\right){}{\mathrm{D_r}}{+}\frac{{1}}{{2}}{}{\mathrm{D_u}}{-}\left(\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{2}{}{r}}{}{\mathrm{D_y}}\right){,}{-}\left(\left(\frac{{3}{}{x}}{{8}}{-}\frac{{1}}{{2}}\right){}{\mathrm{D_r}}\right){-}\left(\frac{{1}}{{2}}{}{\mathrm{D_u}}\right){+}\frac{\frac{{I}}{{2}}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}{,}{-}\left(\left(\frac{{3}{}{x}}{{8}}{-}\frac{{1}}{{2}}\right){}{\mathrm{D_r}}\right){-}\left(\frac{{1}}{{2}}{}{\mathrm{D_u}}\right){-}\left(\frac{\frac{{I}}{{2}}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_x}}\right)\right]$ (2.19)

We check that this is indeed a null tetrad for the given metric.

 M > $\mathrm{GRQuery}\left(\mathrm{NT3},\mathrm{g3},"NullTetrad"\right)$
 ${\mathrm{true}}$ (2.20)

Compute the Newman-Penrose coefficients and check that the Petrov type is III. The coefficients are not in normal form for type III (for example, ), so is not an adapted null tetrad.

 M > $\mathrm{NP3}≔\mathrm{NPCurvatureScalars}\left(\mathrm{NT3},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{NP3}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{-}\frac{{3}}{{32}}{}\frac{\left({2}{}{I}{}\sqrt{{2}}{+}{3}{}\sqrt{{x}}\right){}{{x}}^{{3}{/}{2}}}{{{r}}^{{2}}}{,}{"Psi0"}{=}\frac{{3}}{{32}}{}\frac{{x}{}\left({4}{}{I}{}\sqrt{{2}}{}\sqrt{{x}}{+}{3}{}{x}\right)}{{{r}}^{{2}}}{,}{"Psi2"}{=}\frac{{9}}{{32}}{}\frac{{{x}}^{{2}}}{{{r}}^{{2}}}{,}{"Psi4"}{=}{-}\frac{{3}}{{32}}{}\frac{{x}{}\left({4}{}{I}{}\sqrt{{2}}{}\sqrt{{x}}{-}{3}{}{x}\right)}{{{r}}^{{2}}}{,}{"Psi3"}{=}\frac{{3}}{{32}}{}\frac{\left({2}{}{I}{}\sqrt{{2}}{-}{3}{}\sqrt{{x}}\right){}{{x}}^{{3}{/}{2}}}{{{r}}^{{2}}}\right]\right)$ (2.21)
 > $\mathrm{PetrovType}\left(\mathrm{NP3}\right)$
 ${"III"}$ (2.22)

 > $\mathrm{newNT3}≔\mathrm{AdaptedNullTetrad}\left(\mathrm{NT3},"III",\mathrm{NP3}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{assuming}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}0
 ${\mathrm{newNT3}}{:=}\left[\frac{{3}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{8}{}{{r}}^{{2}}}{}{\mathrm{D_r}}{,}\frac{{11}{}\sqrt{{2}}{}{{r}}^{{2}}}{{8}{}\sqrt{{x}}}{}{\mathrm{D_r}}{+}\frac{{4}{}\sqrt{{2}}{}{{r}}^{{2}}}{{3}{}{{x}}^{{3}}{{2}}}}{}{\mathrm{D_u}}{+}{r}{}\sqrt{{x}}{}\sqrt{{2}}{}{\mathrm{D_x}}{,}\frac{{3}{}\sqrt{{2}}{}\sqrt{{x}}}{{8}}{}{\mathrm{D_r}}{+}\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{2}{}{r}}{}{\mathrm{D_x}}{+}\frac{\frac{{I}}{{2}}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}{,}\frac{{3}{}\sqrt{{2}}{}\sqrt{{x}}}{{8}}{}{\mathrm{D_r}}{+}\frac{\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{2}{}{r}}{}{\mathrm{D_x}}{-}\left(\frac{\frac{{I}}{{2}}{}\sqrt{{2}}{}{{x}}^{{3}}{{2}}}}{{r}}{}{\mathrm{D_y}}\right)\right]$ (2.23)

Calculate the Newman-Penrose coefficients for the new null tetrad. We obtain the correct normal form since  and .

 M > $\mathrm{NPCurvatureScalars}\left(\mathrm{newNT3},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{0}{,}{"Psi4"}{=}{0}{,}{"Psi3"}{=}{1}\right]\right)$ (2.24)

Example 4. Type D

We calculate an adapted null tetrad for a type spacetime. First define the coordinates to be used and then define the metric.

 > $\mathrm{DGsetup}\left(\left[t,x,y,z\right],M\right)$
 ${\mathrm{frame name: M}}$ (2.25)
 M > $\mathrm{g4}≔\mathrm{evalDG}\left(-\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}-\mathrm{dy}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dy}-\frac{1}{2}\mathrm{exp}\left(2x\right)\mathrm{dz}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dz}+\left(\mathrm{dt}+\mathrm{exp}\left(x\right)\mathrm{dz}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&s\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\left(\mathrm{dt}+\mathrm{exp}\left(x\right)\mathrm{dz}\right)\right)$
 ${\mathrm{g4}}{:=}{\mathrm{dt}}{}{\mathrm{dt}}{+}\left({{ⅇ}}^{{x}}{}{\mathrm{dt}}\right){}{\mathrm{dz}}{-}\left({\mathrm{dx}}{}{\mathrm{dx}}\right){-}\left({\mathrm{dy}}{}{\mathrm{dy}}\right){+}\left({{ⅇ}}^{{x}}{}{\mathrm{dz}}\right){}{\mathrm{dt}}{+}\left(\frac{{{ⅇ}}^{{2}{}{x}}}{{2}}{}{\mathrm{dz}}\right){}{\mathrm{dz}}$ (2.26)

Here is an initial null tetrad.

 > $\mathrm{NT4}≔\mathrm{evalDG}\left(\left[-\frac{1}{2}\mathrm{sqrt}\left(2\right)\left(\mathrm{sqrt}\left(2\right)-1\right)\mathrm{D_t}+\mathrm{exp}\left(-x\right)\mathrm{D_z},\frac{1}{2}\mathrm{sqrt}\left(2\right)\left(1+\mathrm{sqrt}\left(2\right)\right)\mathrm{D_t}-\mathrm{exp}\left(-x\right)\mathrm{D_z},\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_x}+\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{D_y},\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_x}-\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{D_y}\right]\right)$
 ${\mathrm{NT4}}{:=}\left[{-}\left(\frac{\sqrt{{2}}{}\left(\sqrt{{2}}{-}{1}\right)}{{2}}{}{\mathrm{D_t}}\right){+}{{ⅇ}}^{{-}{x}}{}{\mathrm{D_z}}{,}\frac{\sqrt{{2}}{}\left(\sqrt{{2}}{+}{1}\right)}{{2}}{}{\mathrm{D_t}}{-}\left({{ⅇ}}^{{-}{x}}{}{\mathrm{D_z}}\right){,}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_x}}{+}\frac{{I}}{{2}}{}\sqrt{{2}}{}{\mathrm{D_y}}{,}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_x}}{-}\left(\frac{{I}}{{2}}{}\sqrt{{2}}{}{\mathrm{D_y}}\right)\right]$ (2.27)

We check that this is indeed a null tetrad for the given metric.

 M > $\mathrm{GRQuery}\left(\mathrm{NT4},\mathrm{g4},"NullTetrad"\right)$
 ${\mathrm{true}}$ (2.28)

Compute the Newman-Penrose coefficients and check that the Petrov type is D. The coefficients are not in normal form for type D (for example, ), so is not an adapted null tetrad.

 M > $\mathrm{NP4}≔\mathrm{NPCurvatureScalars}\left(\mathrm{NT4},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{NP4}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}\frac{{1}}{{4}}{,}{"Psi2"}{=}\frac{{1}}{{12}}{,}{"Psi4"}{=}\frac{{1}}{{4}}{,}{"Psi3"}{=}{0}\right]\right)$ (2.29)
 M > $\mathrm{PetrovType}\left(\mathrm{NP4}\right)$
 ${"D"}$ (2.30)

 > $\mathrm{newNT4}≔\mathrm{AdaptedNullTetrad}\left(\mathrm{NT4},"D"\right)$
 ${\mathrm{newNT4}}{:=}\left[\sqrt{{2}}{}{\mathrm{D_t}}{-}\left(\sqrt{{2}}{}{\mathrm{D_y}}\right){,}\frac{\sqrt{{2}}}{{4}}{}{\mathrm{D_t}}{+}\frac{\sqrt{{2}}}{{4}}{}{\mathrm{D_y}}{,}{-}\left({I}{}{\mathrm{D_t}}\right){+}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_x}}{+}{I}{}{{ⅇ}}^{{-}{x}}{}{\mathrm{D_z}}{,}{I}{}{\mathrm{D_t}}{+}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_x}}{-}\left({I}{}{{ⅇ}}^{{-}{x}}{}{\mathrm{D_z}}\right)\right]$ (2.31)

Calculate the Newman-Penrose coefficients for the new null tetrad. We obtain the correct normal form since  = 0.

 M > $\mathrm{newNP}≔\mathrm{NPCurvatureScalars}\left(\mathrm{newNT4},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{newNP}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{-}\frac{{1}}{{6}}{,}{"Psi4"}{=}{0}{,}{"Psi3"}{=}{0}\right]\right)$ (2.32)

Example 5. Type N

We calculate an adapted null tetrad for a type spacetime. First define the coordinates to be used and then define the metric.

 > $\mathrm{DGsetup}\left(\left[u,x,y,z\right],M\right)$
 ${\mathrm{frame name: M}}$ (2.33)
 M > $\mathrm{g5}≔\mathrm{evalDG}\left(\mathrm{exp}\left(-2z\right)\mathrm{du}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}+\mathrm{exp}\left(-2z\right)\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{du}+\mathrm{exp}\left(z\right)\mathrm{dx}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dx}-\mathrm{exp}\left(-2z\right)\mathrm{dy}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dy}-\mathrm{dz}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}&t\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathrm{dz}\right)$
 ${\mathrm{g5}}{:=}\left({{ⅇ}}^{{-}{2}{}{z}}{}{\mathrm{du}}\right){}{\mathrm{dx}}{+}\left({{ⅇ}}^{{-}{2}{}{z}}{}{\mathrm{dx}}\right){}{\mathrm{du}}{+}\left({{ⅇ}}^{{z}}{}{\mathrm{dx}}\right){}{\mathrm{dx}}{-}\left(\left({{ⅇ}}^{{-}{2}{}{z}}{}{\mathrm{dy}}\right){}{\mathrm{dy}}\right){-}\left({\mathrm{dz}}{}{\mathrm{dz}}\right)$ (2.34)

Here is the initial null tetrad.

 > $\mathrm{NT5}≔\mathrm{evalDG}\left(\left[-\frac{1}{4}\left(\mathrm{exp}\left(3z\right)-2\right)\mathrm{exp}\left(z\right)\mathrm{D_u}+\frac{1}{2}\mathrm{exp}\left(z\right)\mathrm{D_x}+\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_z},-\frac{1}{4}\left(\mathrm{exp}\left(3z\right)-2\right)\mathrm{exp}\left(z\right)\mathrm{D_u}+\frac{1}{2}\mathrm{exp}\left(z\right)\mathrm{D_x}-\frac{1}{2}\mathrm{sqrt}\left(2\right)\mathrm{D_z},\frac{1}{4}\left(\mathrm{exp}\left(3z\right)+2\right)\mathrm{exp}\left(z\right)\mathrm{D_u}-\frac{1}{2}\mathrm{exp}\left(z\right)\mathrm{D_x}+\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{exp}\left(z\right)\mathrm{D_y},\frac{1}{4}\left(\mathrm{exp}\left(3z\right)+2\right)\mathrm{exp}\left(z\right)\mathrm{D_u}-\frac{1}{2}\mathrm{exp}\left(z\right)\mathrm{D_x}-\frac{1}{2}I\mathrm{sqrt}\left(2\right)\mathrm{exp}\left(z\right)\mathrm{D_y}\right]\right)$
 ${\mathrm{NT5}}{:=}\left[{-}\left(\frac{\left({{ⅇ}}^{{3}{}{z}}{-}{2}\right){}{{ⅇ}}^{{z}}}{{4}}{}{\mathrm{D_u}}\right){+}\frac{{{ⅇ}}^{{z}}}{{2}}{}{\mathrm{D_x}}{+}\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_z}}{,}{-}\left(\frac{\left({{ⅇ}}^{{3}{}{z}}{-}{2}\right){}{{ⅇ}}^{{z}}}{{4}}{}{\mathrm{D_u}}\right){+}\frac{{{ⅇ}}^{{z}}}{{2}}{}{\mathrm{D_x}}{-}\left(\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_z}}\right){,}\frac{\left({{ⅇ}}^{{3}{}{z}}{+}{2}\right){}{{ⅇ}}^{{z}}}{{4}}{}{\mathrm{D_u}}{-}\left(\frac{{{ⅇ}}^{{z}}}{{2}}{}{\mathrm{D_x}}\right){+}\frac{{I}}{{2}}{}\sqrt{{2}}{}{{ⅇ}}^{{z}}{}{\mathrm{D_y}}{,}\frac{\left({{ⅇ}}^{{3}{}{z}}{+}{2}\right){}{{ⅇ}}^{{z}}}{{4}}{}{\mathrm{D_u}}{-}\left(\frac{{{ⅇ}}^{{z}}}{{2}}{}{\mathrm{D_x}}\right){-}\left(\frac{{I}}{{2}}{}\sqrt{{2}}{}{{ⅇ}}^{{z}}{}{\mathrm{D_y}}\right)\right]$ (2.35)

We check that this is indeed a null tetrad for the given metric.

 M > $\mathrm{GRQuery}\left(\mathrm{NT5},\mathrm{g5},"NullTetrad"\right)$
 ${\mathrm{true}}$ (2.36)

Compute the Newman-Penrose coefficients and check that the Petrov type is N. The coefficients are not in normal form for type N (for example, ), so is not an adapted null tetrad.

 M > $\mathrm{NP5}≔\mathrm{NPCurvatureScalars}\left(\mathrm{NT5},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{NP5}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{-}\frac{{3}}{{8}}{}{{ⅇ}}^{{3}{}{z}}{,}{"Psi0"}{=}\frac{{3}}{{8}}{}{{ⅇ}}^{{3}{}{z}}{,}{"Psi2"}{=}\frac{{3}}{{8}}{}{{ⅇ}}^{{3}{}{z}}{,}{"Psi4"}{=}\frac{{3}}{{8}}{}{{ⅇ}}^{{3}{}{z}}{,}{"Psi3"}{=}{-}\frac{{3}}{{8}}{}{{ⅇ}}^{{3}{}{z}}\right]\right)$ (2.37)
 M > $\mathrm{PetrovType}\left(\mathrm{NP5}\right)$
 ${"N"}$ (2.38)

 > $\mathrm{newNT5}≔\mathrm{AdaptedNullTetrad}\left(\mathrm{NT5},"N",\mathrm{NP5}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{assuming}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}0
 ${\mathrm{newNT5}}{:=}\left[\frac{{{ⅇ}}^{\frac{{5}{}{z}}{{2}}}{}\sqrt{{6}}}{{2}}{}{\mathrm{D_u}}{,}{-}\left(\frac{\sqrt{{6}}{}\left({{ⅇ}}^{{3}{}{z}}{-}{2}\right){}{{ⅇ}}^{{-}\frac{{z}}{{2}}}}{{6}}{}{\mathrm{D_u}}\right){+}\frac{{{ⅇ}}^{{-}\frac{{z}}{{2}}}{}\sqrt{{6}}}{{3}}{}{\mathrm{D_x}}{+}\frac{{2}{}\sqrt{{3}}{}{{ⅇ}}^{{-}\frac{{3}{}{z}}{{2}}}}{{3}}{}{\mathrm{D_z}}{,}{-}\left({{ⅇ}}^{{z}}{}{\mathrm{D_u}}\right){+}\frac{{I}}{{2}}{}\sqrt{{2}}{}{{ⅇ}}^{{z}}{}{\mathrm{D_y}}{-}\left(\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_z}}\right){,}{-}\left({{ⅇ}}^{{z}}{}{\mathrm{D_u}}\right){-}\left(\frac{{I}}{{2}}{}\sqrt{{2}}{}{{ⅇ}}^{{z}}{}{\mathrm{D_y}}\right){-}\left(\frac{\sqrt{{2}}}{{2}}{}{\mathrm{D_z}}\right)\right]$ (2.39)

Calculate the Newman-Penrose coefficients for the new null tetrad. We obtain the correct normal form since  = 0 and

 M > $\mathrm{newNP5}≔\mathrm{NPCurvatureScalars}\left(\mathrm{newNT5},\mathrm{output}=\left["WeylScalars"\right]\right)$
 ${\mathrm{newNP5}}{:=}{\mathrm{table}}\left(\left[{"Psi1"}{=}{0}{,}{"Psi0"}{=}{0}{,}{"Psi2"}{=}{0}{,}{"Psi4"}{=}{1}{,}{"Psi3"}{=}{0}\right]\right)$ (2.40)