Hi!
If the indices belongs to the same VBundle, you can only allow or disallow ToCanonical to raise or lower all indices of the VBundle.
The best way to handle this is probably to allow ToCanonical to
change the index position of all tensors, and afterwards try to
arrange the index positions for some of the tensors.
For instance, you can reset the standard index positions (used in
DefTensor) of MyTensor with the rule
SeparateMyTensorRule = x : MyTensor[inds__] :>
SeparateMetric[][x];
Unfortunately, this also introduces extra metrics which needs to
be contracted into the other factors. This can for instance be
done with
ContractOthersRule = Times[MyTensor[inds__], factors__]
:> MyTensor[inds] ContractMetric[Times[factors]];
This rule only works the way you wanted if MyTensor only appears
once, but with a bit more coding one can probably make it work in
a more general setting too.
I hope this gives you some ideas how to do this.
Regards
Thomas
--
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/35b596c8-8401-463b-a3fe-c2b7be124b81n%40googlegroups.com.
Hi!
Could you send a small example notebook so we can see exactly what is going wrong?
Regards
Thomas
To view this discussion on the web visit https://groups.google.com/d/msgid/xact/56fd8ffc-0b1b-4c67-9aa8-f05a790d9016n%40googlegroups.com.