####
Contract

#####
Description

Contract[expr] contracts pairs of Lorentz indices of metric tensors, four-vectors and (depending on the optionEpsContract) of Levi-Civita tensors in expr. For the contraction of Dirac matrices with each other use DiracSimplify. Contract[exp1, exp2] contracts (exp1*exp2), where exp1 and exp2 may be larger products of sums of metric tensors and 4-vectors.

See also: Pair, DiracSimplify, MomentumCombine.

#####
Examples

The default dimension for MetricTensor is 4.

A short way to enter D-dimensional metric tensors is given by MTD. The "." as multiplication operator is not necessary but just convenient for typesetting.

Converted from the *Mathematica* notebook Contract.nb