On Jul 20, 1:23 pm, Ondrej Certik <ondrej.cer...@gmail.com> wrote: > On Wed, Jul 20, 2011 at 11:59 AM, Aaron Meurer <asmeu...@gmail.com> wrote: > > First off, if you want an explicit order of substitution, you should > > not use a dictionary. Subs also allows the [(old, new), ...] syntax, > > which lets you define a specific order. > > > But even in this case, it will perform the substitution iteratively. > > This is actually a useful feature. For example, you can take the > > output of cse() and back-substituted it all in one step, even though > > the various substitutions depend on each other.
For what it's worth, in Sage, the substitution is done simultaneously: sage: var('x,y,a,b') (x, y, a, b) sage: (x**2+y**3).subs({x: a*x+b*y, y: b*x-a*y}) -(a*y - b*x)^3 + (a*x + b*y)^2 --Mike -- You received this message because you are subscribed to the Google Groups "sympy" group. To post to this group, send email to sympy@googlegroups.com. To unsubscribe from this group, send email to sympy+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/sympy?hl=en.