How can I change the order of multiplication/composition of elements in the symmetric group?
Example:
sage: S=SymmetricGroup(4)
sage: a=S((1,2))
sage: b=S((2,3))
sage: c=S((3,4))
sage: a*b*c
(1,4,3,2)
How can I change this behavior so that I can execute a*b*c
and the output will be (1,2,3,4)
? I want to keep using the star *
, not an inconvenient command like a.__rmul__(b).__rmul__(c)
, otherwise I would have to rewrite all my code.