On Wed, Jun 4, 2008 at 2:26 AM, Simon King <[EMAIL PROTECTED]> wrote: > > Dear Andrey, > > On Jun 4, 7:21 am, Andrey Novoseltsev <[EMAIL PROTECTED]> wrote: >> What is wrong with the code below and how to fix it? > > I don't know what precisely is wrong with that code, but a very > similar code works. > > First, i can reproduce the trouble: > sage: Rt.<t> = PolynomialRing(QQ,1) > sage: p = 1+t > sage: R.<u,v> = PolynomialRing(QQ, 2) > sage: p(u/v) > --------------------------------------------------------------------------- > TypeError Traceback (most recent call > last) > ... > > The following works: > sage: Rt2.<t> = PolynomialRing(QQ) > sage: p2 = 1+t > sage: p2(u/v) > (u + v)/v > > The difference is that Rt is a Multivariate Polynomial Ring (with one > variable, though), but Rt2 is a genuine Univariate Polynomial Ring. > > So, at least there is a work-around. > Yours
I've opened a trac ticket for this here: http://trac.sagemath.org/sage_trac/ticket/3359 --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-support URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---
