In the trans function there are these 2 lines which could be optimized a bit imho.
%eq = $regsubex(%eq,/(\\\\d)x/g,\\\\t*x)
%eq = $regsubex(%eq,/(\\\\d[a-z])/g,$remove(\\\\t,$regsubex(\\\\t,\\\\d+,\\\\t)) $+ * $+ $regsubex(\\\\t,\\\\d+,\\\\t))
Basically, both of them does the same thing, except for the first which considers only the \'x\' character after a digit.
They could be replaced by this single line.
%eq = $regsubex(a,%eq,/(\\\\d)([a-z])/g,\\\\1*\\\\2)
;o)