Cadabra
a field theory motivated approach to computer algebra

SelfAntiCommuting

Make components of tensors anti-commute.
Used to make objects with indices anti-commuting when their index values are different. Example:
\psi^{\mu}::SelfAntiCommuting. ex:= \psi^{\nu} \psi^{\mu};
\(\displaystyle{}\psi^{\nu} \psi^{\mu}\)
canonicalise(_);
\(\displaystyle{}-\psi^{\mu} \psi^{\nu}\)
ex:= \psi^{\mu} \psi^{\mu};
\(\displaystyle{}\psi^{\mu} \psi^{\mu}\)
canonicalise(_);
\(\displaystyle{}0\)
This could not be handled with AntiCommuting because that property handles the behaviour of \emph{different} expression patterns.
Copyright © 2001-2017 Kasper Peeters
Questions? info@cadabra.science