when I use
{\mu,\nu}::Indices(vector).
tr{#}::Trace.
ex:=A A tr{u^{\mu} u^{\nu}} tr{u^{\nu} u^{\mu}}- B B tr{u^{\mu} u^{\nu}} tr{u^{\mu} u^{\nu}};
sort_product(_);
collect_factors(_);
factor_in(_,$A**2,B**2$);
I get the following error
{\color{red}{\begin{verbatim}RuntimeError: Power with free indices not
allowed.
At: (4): \end{verbatim}}}
How to solve it?