Karim BELABAS on Tue, 6 Nov 2001 11:11:57 +0100 (MET) |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: pari-2.2.1.alpha released |
On Mon, 5 Nov 2001, Ilya Zakharevich wrote: > On Sun, Nov 04, 2001 at 02:39:00PM +0100, Karim BELABAS wrote: > > > BTW, is there a "better" semantic than doing substitutions > > > left-to-right? Here "better" meaning one or more of "more > > > convenient", "more functionality", "less surprising". > > > > There should be a way to choose between 'left-to-right' (sequential) and > > 'parallel' (simultaneous) substitution. Both are relatively easy to > > implement. > > But what does 'parallel' substitution means mathematically? E.g. > > x -> y > y -> x > x+y -> x-y Indeed, 'parallel' only makes sense for variable substitution, not for a general algebraic one (as per recent extension and proposal). Hum. In fact, this is a strong point for advocating the sequential default... Then the 'parallel' flag could be documented to make sense on a restricted set of intputs (substitute variables only), but the default behaviour would be consistent. Unfortunately, sequential substitution is probably more confusing for standard use (I would expect to substitute variables most of the time, esp. many at the same time): subst([x,y], [x,y], [y,x], DEFAULT) --> [x,x] \\ maybe surprising subst([x,y], [x,y], [y,x], PARALLEL) --> [y,x] \\ "expected" Karim. -- Karim Belabas email: Karim.Belabas@math.u-psud.fr Dep. de Mathematiques, Bat. 425 Universite Paris-Sud Tel: (00 33) 1 69 15 57 48 F-91405 Orsay (France) Fax: (00 33) 1 69 15 60 19 -- PARI/GP Home Page: http://www.parigp-home.de/