Can I make inverse metric the only thing with raised indices

145 views
Skip to first unread message

Niall Macpherson

unread,
Nov 15, 2021, 11:54:24 AM11/15/21
to xa...@googlegroups.com
Hello,

Is there some built-in way to take an arbitrary expression containing contracted indices, and reexpress it in a  canonical way such that the inverse metric is the only thing that appears with raised indices?

ie how can I send  X^{...,N,...} Y_{...,-N,...}   to   g^{MN} X_{...,-M,...}Y_{...,-N,....} everywhere such a contraction appears in an expression.

I've noticed that several of the built-in computational tools require you to express things in such a  canonical way before you use them, for instance when you expand about a product metric or do a conformal transformation.

On the other hand other built in processes (eg xPerm) give rather long winded expressions that are not in this canonical form - and putting them into this form by hand can be extremely laborious (and more importantly easy to make mistakes while doing).

I attach a file giving examples of what I mean - typically I am not dealing with something as simple as this though, hence the wish to automate.

thanks
Niall

productandconformalmetric.nb

Jose

unread,
Nov 15, 2021, 12:37:51 PM11/15/21
to xAct Tensor Computer Algebra
Hi,

In most computations we want xTensor to handle metric factors automatically, but it's true that sometimes (for example when dealing with non-compatible derivatives of the metric) it's better to have all metric factors explicitly.

There are two things to do:

1) Input all expressions with explicit metric factors. If some expression has contracted metrics, you can separate them with SeparateMetric[g][expr]. This function can be considered the inverse of ContractMetric, which of course should never be used in your computations.

2) ToCanonical moves indices up and down by default. You can deactivate this with ToCanonica[expr, UseMetricOnVBundle -> None]. The default is All. If you want to set this permanently in your session, evaluate SetOptions[ToCanonical, UseMetricOnVBundle -> None] before you start your computations.

Cheers,
Jose.

Niall Macpherson

unread,
Nov 15, 2021, 1:06:58 PM11/15/21
to Jose, xAct Tensor Computer Algebra
This command SeperateMetric does exactly what I want - Fantastic! 

thank you Jose,

-Niall

--
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/599d05ae-fa5e-476e-971e-a7885e1c0c29n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages