[I cc'd this to haskell users since I couldn't find out what the name was of the forum to which the original thread belonged to. Appologies if I have made a mistake and I am upseting somebody.] Jerzy Karczmarczuk: : horrible complexity. Does it answer your question? ************************************************************** It does. I just hadn't heared of the term you used before. Sometimes one has to resort to this kind of algorithms. The polynomial remainder e.g. is just the same as the result of a substitution: rem p1 (x - p2) == subs( x = p2, p1 ) where it is assumed that x is the leading term of x - p2. ************************************************************** I am using Haskell for Gr{\"o}bner basis computations and conversions of such bases. I am quite happy with it: - I have implemented existing algorithms quite easilly. In particular I found list comprehensions very useful because they allow for an almost one to one translation from mathematical set comprehension to a program in Haskell; - The basic (Gr{\"o}bner basis) algorithms perform quite well. I have not yet been able to carry out a fair comparison with other CAS (Computer Algebra Systems) but the Haskell based algorithms do leave Maple *far* behind. For reasons mentioned earlier in this thread, I do not take that to be a proof for the superiority of Haskell based CA Algorithms:-) - Finally I have been able to implement some new algorithms without much problems (i.e. from a programmer's point of view). The new algorithms outperform the existing ones I was trying to improve. I hope to be able to report on this as soon as I have some more time. Regards, Marc