Re: Odd phenomenon

*To*: mathgroup at smc.vnet.net*Subject*: [mg109497] Re: Odd phenomenon*From*: Andrzej Kozlowski <akoz at mimuw.edu.pl>*Date*: Fri, 30 Apr 2010 05:50:05 -0400 (EDT)*References*: <201004290652.CAA18235@smc.vnet.net>

On 29 Apr 2010, at 15:52, S. B. Gray wrote: > I did a symbolic calculation in which x,y,z were treated exactly the > same. The result was three long, messy expressions, but the result for x > was much simpler than those for y and z, even after FullSimplify. I then > changed the expression for x into one for y (z->w,y->z,x->y,w->x) > and the expression for x into one for z (x->w, y->x, z->y, w->z). > These manually created y,z expressions are identical to the original y,z > ones according to FullSimplify[new - old] and they give the same numeric > results. > > Is this surprising? Obviously FullSimplify is not perfect but to get > around it was a fair amount of work. > > Steve Gray > No, it's not surprising. Certain algebraic transformations used by FullSimplify, such as PolynomialRecuce, will give you a result which depends on the ordering of the variables so that even if the expression that is being simplified is symmetric the result may not be so. If you change the ordering of the variables you will get a different result. The default ordering is lexicographic. To obtain an optimal result you should try all possible variable orderings and then choose the simplest answer but doing this will substantially increase the time FullSimplify takes to do so, which is why FullSimplify does not do this sort of thing by default. Remember that if FullSimplify was changed so that it always tried all possible variable orderings it would cause a major slowdown in all applications of FullSimplify, while only a relatively small number of cases would benefit, which is why it is preferable to leave this sort of thing to the user.

**References**:**Odd phenomenon***From:*"S. B. Gray" <stevebg@ROADRUNNER.COM>