xPert gives apparently the wrong answer

86 views
Skip to first unread message

Ruben Campos Delgado

unread,
Nov 24, 2022, 5:26:48 AM11/24/22
to xAct Tensor Computer Algebra
Hello,

I was computing the perturbation of the metric determinant. At first order I get the
correct result, at second order (and higher) it seems to me that the result is wrong.
You can also have a look at the official pdf of the documentation: 
Go to page 16, Output 74. There, there is the perturbation of the metric determinant
at second order. However, comparing it with the known answer in the literature, it seems that it has the wrong numerical coefficients....
See this post on stack.exchange on how to compute by hand this perturbation
(there they compute the square root of the determinant, but you can adapt it easily).

So, is xPert wrong?

Cyril Pitrou

unread,
Nov 24, 2022, 6:59:04 AM11/24/22
to Ruben Campos Delgado, xAct Tensor Computer Algebra
Dear Ruben

From the page
and if I square the result I do get that the perturbation of the determinant is the determinant times
(1 + h^i_i + (h^i_i)^2/2 - h^{ij}h_{ij}/2)

Perturbations are defined with a prefactor 1/n! in xPert, for instance
h^i_i = h^{1}^i_i + h^{2}^i_i/2 + h^{3}^i_i/6 + h^{4}^i_i / 24

Hence the second order pertubation is twice what appears at second order and is
h^{2}_i^i  + (h^i_i)^2 - h^{ij}h_{ij}
which is what is given by xPert.

Best regards,
Cyril

--
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.
To view this discussion on the web visit https://groups.google.com/d/msgid/xact/d7a3b902-6479-4edc-83a4-041a47a12576n%40googlegroups.com.

Ruben Campos Delgado

unread,
Nov 24, 2022, 7:51:04 AM11/24/22
to xAct Tensor Computer Algebra
Hi Cyril,
thank you for the reply, but I still think this does not solve the issue.
In stack.exchange we expanded the metric as g=b+h.
If I undertstand correctly, xPert does the following: it write g as g=b+h1+h2^2/2 etc..
but in our starting point we don't have h^2, so we have to set h^2 to zero.
See also at the end of page 2 of https://arxiv.org/pdf/0807.0824.pdf (below equation 4)
The answer of xPert for the second order perturbation is
h^{2}_i^i  + (h1^i_i)^2 - h1^{ij}h_{ij}
So, setting h^2=0 we have
(h1^i_i)^2 - h1^{ij}h_{ij}
However, this does not match with the expression
(h1^i_i)^2/2 - h1^{ij}h1_{ij}/2,
factors of two are missing...

Jose

unread,
Nov 28, 2022, 2:16:34 AM11/28/22
to xAct Tensor Computer Algebra
Hi Ruben,

I don't understand where do you see a problem. Take for example this computation, which produces the same coefficients as the stackexchange page you mention. I use an arbitrary dimension to make it clear that this computation is dimension-independent:

<< xAct`xPert`

DefConstantSymbol[dim]

DefManifold[M, dim, {a, b, c, d, e, f}]

DefMetric[-1, g[-a, -b], cd]

DefMetricPerturbation[g, h, \[Epsilon]]

Perturbed[Sqrt[-Detg[]], 2]/Sqrt[-Detg[]] // ExpandPerturbation // Expand // NoScalar

Collect[% /. h[LI[2], __] -> 0, \[Epsilon], ToCanonical]

Screen Shot 2022-11-28 at 01.11.11.png

As you said, if the full metric is exactly g + h then xPert's h1 is your h and the perturbations of higher order (in this case just h2) must be replaced by zero.

Cheers,
Jose.

Ruben Campos Delgado

unread,
Nov 28, 2022, 6:44:28 AM11/28/22
to Jose, xAct Tensor Computer Algebra
Hi Jose,
ok I see, thank you very much. You use Perturbed[ ] which gives you the full expansion.
I used Perturbation[,2] which gives the terms at second order only. There I got an answer which was "wrong" by a factor of 2.
As Cyril told me, you have to divide the answer by n!, in this case 2, because xpert gives you g^n and not g^n/n!.
But now that I see your command Perturbed[ ], I will definitely use it, because it gives the full answer and I don't need to divide.
Thank you very much again,
Ruben

You received this message because you are subscribed to a topic in the Google Groups "xAct Tensor Computer Algebra" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/xact/jahtVrM9wN0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to xact+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xact/5856b5ab-b2ea-49c3-be03-00ffea05cd31n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages