How to define Vierbein using xCoba

986 views
Skip to first unread message

Dat Nguyen

unread,
May 10, 2014, 3:01:20 PM5/10/14
to xa...@googlegroups.com
Dear all,
I have a problem when I try to define vierbein in a spherical chart of 4-dim manifold.
To do this I have to define 2 metric. The curvilinear metric g[muy,nuy]  (muy, nuy is the indices of the chart) and flat metric (Minkowski metric) eta[a,b] (a, b is the indices of Tangent space). If I do it right, we have g[muy,nuy]=e_muy^a*e_nuy^b*eta[a,b].
But I can't define the eta metric. I have done as follow:

in[1]:= <<xAct`xCoba`
in[2]:= DefManifold[M, 4, {\[Mu], \[Nu], \[Rho], \[Sigma]}]
in[3]:= DefChart[sphere, M, {0, 1, 2, 3}, {t[], r[], \[Theta][], \[Phi][]}, 
 ExtendedCoordinateDerivatives -> False]
in[4]:= DefMetric[-1, metric[-\[Mu], -\[Nu]], CD, SymbolOfCovD -> {";", "D"}, 
 PrintAs -> "g"]
in[5]:= DefVBundle[tangent, M, 4, {a, b, c, d}]
in[6]:= DefMetric[-1, gflat[-a, -b], PD, SymbolOfCovD -> {",", "\[PartialD]"},
  FlatMetric -> True]
In this step I received an error: DefMetric::notan: Metrics can only be defined on a tangent bundle.

Could you please give me an explain or advice to solve this problem?
Thanks in advance.

Jose

unread,
Sep 7, 2014, 5:46:54 PM9/7/14
to xa...@googlegroups.com
Hi,

Sorry for the late reply...

The error you are getting is half correct and half limitation. It is correct because you don't need to create the tangent bundle to M. That object is automatically created when you defined the manifold M. DefManifold automatically creates the vbundle TangentM, and attaches to it the indices {\[Mu], \[Nu], \[Rho], \[Sigma]}. That is, the indices of a manifold are actually the indices of its tangent spaces.

The limitation part is that xTensor should be able to handle metric fields in vbundles other than the tangent bundle of the manifold, but currently it is not.

I'm not really sure what you want to do here. If you want to introduce a basis of 4 vector fields in which to specify metric components, I would recommend to use DefBasis. For example, imagine I want to show that the Kerr metric is Ricci-flat using a basis in which the metric is diagonal. You can do this:

Load xCoba:

In[1]:= Needs["xAct`xCoba`"]

Eliminate all info-messages:

In[2]:= $DefInfoQ = $UndefInfoQ = False;
           SetOptions[MetricCompute, Verbose -> False];
           $xCobaCacheVerbose = False;

Define the manifold (and its tangent bundle):

In[5]:= DefManifold[M, 4, {a, b, c, d, e, f}]

Define a chart, which will be used to give the noncoordinated frame and to define coordinated functions:

In[6]:= DefChart[BL, M, {0, 1, 2, 3}, {t[], r[], x[], \[Phi][]}]

These are the two constants of the Kerr metric:

In[7]:= DefConstantSymbol[{\[Alpha], \[CapitalMu]}]

In[8]:= Sigma = r[]^2 + \[Alpha]^2 x[]^2;
           Delta = r[]^2 + \[Alpha]^2 - 2 \[CapitalMu] r[];

Everything will be simplified with Simplify:

In[10]:= $CVSimplify = Simplify;

Now define the non-coordinated basis R, and give the transformation matrix from the coordinated basis, as a CTensor:

In[11]:= DefBasis[R, TangentM, {0, 1, 2, 3}, BasisColor -> Blue, 
 BasisChange ->  CTensor[Transpose@Inverse@
     {{1, 0, 0, 2 \[Alpha] \[CapitalMu] r[] (1 - x[]^2)/(Sigma - 2 \[CapitalMu] r[])},
      {0, 1, 0, 0}, {0, 0, 1, 0}, {0, 0, 0,1}}, {-R, BL}]
]

The metric in this basis (note the {-R, -R}) indicating the basis of the components used:

In[12]:= met = CTensor[DiagonalMatrix[{1 - 2 \[CapitalMu] r[]/Sigma, -Sigma/Delta, -Sigma/(1 - x[]^2), -Delta Sigma (1 - x[]^2)/(Sigma - 2 \[CapitalMu] r[])}], {-R, -R}];

Set this metric, telling xCoba that it is a field in the BL coordinates. A few things are precomputed:

In[13]:= SetCMetric[met, BL] // AbsoluteTiming
Out[13]= {0.688177, Null}

Now compute everything needed to get the Ricci tensor:

In[14]:= MetricCompute[met, BL, "Ricci"[-1, -1]] // AbsoluteTiming
Out[14]= {2.125050, Null}

(At this moment xCoba knows that the Ricci is zero, and so it took less than 3 seconds of total computation time.)

This is the Levi-Civita connection of the metric:

In[15]:= cd = CovDOfMetric[met];

And this is the Ricci tensor, which is zero as we wanted to show:

In[16]:= Ricci[cd]
Out[16]= Zero

Cheers,
Jose.

Dat Nguyen

unread,
Sep 28, 2014, 11:21:55 AM9/28/14
to xa...@googlegroups.com
Hi,
I got it, thanks for your help.
Regards,
Dat

aux...@gmail.com

unread,
Jun 21, 2015, 10:21:50 PM6/21/15
to xa...@googlegroups.com
I'm trying to define the Carter frame for the Kerr metric and I'm stuck in the verification that the metric expressed in the frame basis is Minkowski, even though I've verified using xAct the opposite direction, namely from Minkowski to the Kerr metric in Boyer-Lindquist coordinates.

The definitions are:

DefManifold[M, 4, IndexRange[a, q]]
DefMetric[-1, metric[-a, -b], CD, PrintAs -> "g"]
DefChart[BL, M, {0, 1, 2, 3}, {t[], r[], \[Theta][], \[Phi][]}]
DefConstantSymbol[Mass, PrintAs -> "m"]
DefConstantSymbol[Rotation, PrintAs -> "a"]

\[CapitalDelta] = r[]^2 + Rotation^2 - 2 Mass r[];

\[CapitalSigma] = r[]^2 + Rotation^2 Cos[\[Theta][]]^2;

$Assumptions = {Mass > 0 && Rotation > 0 && MagneticField \[Element] Reals && \[CapitalDelta] > 0 && r[] >= 0 && 
   0 <= \[Theta][] <= Pi && 0 <= \[Phi][] <= 2 Pi};

MetricInBasis[metric, -BL, {{-((\[CapitalDelta] - Rotation^2 Sin[\[Theta][]]^2)/\[CapitalSigma]), 0, 0, -Rotation Sin[\[Theta][]]^2 (
    r[]^2 + Rotation^2 - \[CapitalDelta])/\[CapitalSigma]}, {0, \[CapitalSigma]/\[CapitalDelta], 0, 0}, {0, 0, \[CapitalSigma], 
   0}, {-Rotation Sin[\[Theta][]]^2 (r[]^2 + Rotation^2 - \[CapitalDelta])/\[CapitalSigma], 0, 0, ((r[]^2 + 
       Rotation^2)^2 - \[CapitalDelta] Rotation^2 Sin[\[Theta][]]^2)/\[CapitalSigma] Sin[\[Theta][]]^2}}]

DefBasis[ON, TangentM, {0, 1, 2, 3}, BasisColor -> Blue]

transmat = {{Sqrt[\[CapitalDelta]/\[CapitalSigma]], 0, 0, -Rotation  Sqrt[\[CapitalDelta]/\[CapitalSigma]] \Sin[\[Theta][]]^2}, {0, Sqrt[\[CapitalSigma]/\[CapitalDelta]], 0, 0}, {0, 0, Sqrt[\[CapitalSigma]], 0}, {-Rotation Sin[\[Theta][]]/Sqrt[\[CapitalSigma]], 0, 0, 
   Sin[\[Theta][]]/Sqrt[\[CapitalSigma]] (r[]^2 + Rotation^2)}}

AllComponentValues[Basis[-{a, ON}, {b, BL}], transmat]
AllComponentValues[Basis[-{a, BL}, {b, ON}], Simplify@Inverse[transmat]]
ChangeComponents[metric[-{a, ON}, -{b, ON}], metric[-{a, BL}, -{b, BL}]

This is the Kerr metric in BL coordinates:
metric[-a, -b] // ToBasis[BL] // SeparateBasis[ON] //TraceBasisDummy // ComponentArray // ToValues //ToValues // Simplify

But this attempt to calculate the metric in the orthonormal frame yields the wrong result:
metric[-a, -b] // ToBasis[ON] // SeparateBasis[BL] //TraceBasisDummy // ComponentArray // ToValues // FullSimplify

I've verified both manually and with a couple of references that the vierbeins are correctly defined. Since this is the first time I'm using xAct with two bases, perhaps I'm making some trivial mistake. Would you have any hints about this? Also, I noticed that the previous answer is more concise when defining the transformation. Is there any other disadvantage with the way I'm doing the calculations?

Thank you in advance,
Peter

Leo Stein

unread,
Jun 22, 2015, 11:06:56 AM6/22/15
to aux...@gmail.com, xAct Tensor Computer Algebra
Hi Peter,

Have a look at the file xAct/Documentation/English/xCobaDoc2.nb, section 4.1. There is an explicit example of how to define a Basis which has a specific Jacobian with respect to another basis. This involves giving DefBasis the option BasisChange->CTensor[change, {-newbasis, old}] where change is an NxN Jacobian matrix. A lot of this is simpler in the new CTensor approach than in the old approach.

I hope this helps!
Good luck
Leo

--
You received this message because you are subscribed to the Google Groups "xAct Tensor Computer Algebra" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xact+uns...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

auxsvr

unread,
Jun 24, 2015, 4:56:32 AM6/24/15
to Leo Stein, xAct Tensor Computer Algebra
On Monday 22 of June 2015 11:06:55 Leo Stein wrote:
> Hi Peter,
>
> Have a look at the file xAct/Documentation/English/xCobaDoc2.nb,
> section 4.1. There is an explicit example of how to define a Basis
> which has a specific Jacobian with respect to another basis. This
> involves giving DefBasis the option BasisChange->CTensor[change,
> {-newbasis, old}] where change is an NxN Jacobian matrix. A lot of
> this is simpler in the new CTensor approach than in the old approach.

Hi Leo,

This is exactly what I needed and with fully developed examples; finally
the calculation went as expected. One problem of the new approach is
that it is undocumented according to ?DefBasis, but the documentation in
xCobaDoc2.nb is excellent, provided that one is aware of its existence!
A couple of minor nitpicks: the matrix of the linear map between a non-
holonomic and a coordinate basis in general cannot be a jacobian,
correct? Also, {-newbasis,old} corresponds to the matrix that transforms
between vectors, correct? But how can this be so, when basis vectors in
Wald's notation have the index up? This has the potential to cause
confusion, because Wald's abstract index notation results in the
opposite placement of indices by the vierbein compared to that of the
form notation.

The next step is to define a 2-form in the chart and then express it in
terms of the Carter orthonormal basis. Is xTerior capable of handling
coordinates this way or should I define the 2-form as a tensor with
antisymmetric indices? Ideally, I would express the orthonormal forms in
terms of the coordinate forms, express the 2-form in terms of the
coordinate basis and then convert it into the orthonormal one.

I wrote the 2-form as a CTensor and soon came to another problem. My
definition is F=cd[-a]@eta[-b] - cd[-b]@eta[-a], where
cd=CovDOfMetric[metric] and eta is a 1-form. The problem is that F
cannot be handled as a CTensor! No index expression works, no basis
transformation etc. I had to work around this by constructing a CTensor
from it by selecting each element in the definition with nested Table.
Shouldn't the result of the covariant derivatives be a CTensor?

> I hope this helps!
> Good luck
> Leo

Very helpful, thanks.
> >>> *in[1]:= <<xAct`xCoba`*
> >>>
> >>> *in[2]:= DefManifold[M, 4, {\[Mu], \[Nu], \[Rho], \[Sigma]}]*
> >>> *in[3]:= DefChart[sphere, M, {0, 1, 2, 3}, {t[], r[], \[Theta][],
> >>> \[Phi][]}, *
> >>> * ExtendedCoordinateDerivatives -> False]*
> >>> *in[4]:= DefMetric[-1, metric[-\[Mu], -\[Nu]], CD, SymbolOfCovD ->
> >>> {";", "D"}, *
> >>> * PrintAs -> "g"]*
> >>> *in[5]:= DefVBundle[tangent, M, 4, {a, b, c, d}]*
> >>> *in[6]:= DefMetric[-1, gflat[-a, -b], PD, SymbolOfCovD -> {",",
> >>> "\[PartialD]"},*
> >>> * FlatMetric -> True]*
> >>> In this step I received an error: *DefMetric::notan: Metrics can
> >>> only
> >>> be defined on a tangent bundle.*

Alfonso García-Parrado Gómez-Lobo

unread,
Jun 24, 2015, 9:14:57 AM6/24/15
to auxsvr, Leo Stein, xAct Tensor Computer Algebra
Hi Peter,


> The next step is to define a 2-form in the chart and then express it in
> terms of the Carter orthonormal basis. Is xTerior capable of handling
> coordinates this way or should I define the 2-form as a tensor with
> antisymmetric indices? Ideally, I would express the orthonormal forms in
> terms of the coordinate forms, express the 2-form in terms of the
> coordinate basis and then convert it into the orthonormal one.
>

In relation to this specific question I must say that the implementation
of the CTensor framework in xTerior is still work in progress. However,
both the holonomic and an-holonomic version of the co-basis 1 forms
already exist in xTerior. They are defined respectively with the objects
"dx" and "Coframe" and you can find some examples in section 8 of
xTeriorDoc.nb


Alfonso.




Reply all
Reply to author
Forward
0 new messages