I think this algorithm does not provide a minimum. Try it on ratsimp ((x+y+z)^4); There are many ways of rearranging expressions to minimize multiplications and additions, and while you may reduce the number somewhat by this technique, it is not a minimum. RJF