physics.hep.kahane simplify() incorrectly reverses order of leading uncontracted gamma matrices The kahane…
physics.hep.kahane simplify() incorrectly reverses order of leading uncontracted gamma matrices The kahane…: a task in Lego-RL-SWE-Bench-Verified (Harbor dataset). The bug is illustrated by the following example: python import sympy from sympy.physics.hep.gamma matrices import GammaMatrix as G…
The task
The bug is illustrated by the following example: ```python import sympy from sympy.physics.hep.gamma_matrices import GammaMatrix as G, gamma_trace, LorentzIndex from sympy.physics.hep.gamma_matrices import kahane_simplify from sympy.tensor.tensor import tensor_indices
Part of Lego-X/Lego-RL-SWE-Bench-Verified.