Cadabra
a field-theory motivated approach to computer algebra

Metric

Makes a two-tensor a metric.
Labels the object as a symmetric tensor, and optionally gives it the indicated signature through the signature parameter.
g_{m n}::Metric(signature=1). ex:= g_{m n} A^{n p}; eliminate_metric(_);
\(\displaystyle{}g_{m n} A^{n p}\)
{\color{red}{
Traceback (most recent call last):
  File "<string>", line 3, in <module>
NameError: name 'eliminate_metric' is not defined
}}
Objects declared as Metric can be used to automatically raise or lower indices using the eliminate_metric algorithm, as above.
Copyright © 2001-2024 Kasper Peeters
Questions? info@cadabra.science