Ask Your Question
4

Multivariate Polynomials over Rational Function Fields

asked 2010-08-26 03:12:25 +0200

Sameer Agarwal gravatar image

updated 2011-04-28 16:48:26 +0200

Kelvin Li gravatar image

Is it possible to define multivariate polynomials where the coefficients lie in a rational function field and do Groebner basis computations on them? Maple, Reduce and Axiom support this. For example I would like to be able to compute the Groebner basis of the polynomials

{v * x^2 + y, u* x * y + y^2}

where the polynomials belong to the ring Q(u,v)[x,y].

I tried the following

B.<u,v> = PolynomialRing(QQ, 'u', 'v')
R.<x,y> = PolynomialRing(B, 'x', 'y')
I = R.ideal(v * x^2 + y, u* x * y + y^2) 
g = I.groebner_basis()

This fails with the error

TypeError: Can only reduce polynomials over fields.
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
6

answered 2010-08-26 03:15:22 +0200

William Stein gravatar image

Make u and v be in the Fraction field:

sage: B.<u,v> = Frac(QQ['u,v'])
sage: R.<x,y> = PolynomialRing(B, 'x', 'y')
sage: I = R.ideal(v * x^2 + y, u* x * y + y^2) 
sage: g = I.groebner_basis()
sage: g
[y^3 + u^2/v*y^2, x^2 + 1/v*y, x*y + 1/u*y^2]
edit flag offensive delete link more

Comments

1

Thanks, that works perfectly. Now my quest for the Elimination ideal I2 = I.elimination_ideal([x]) fails with TypeError: Cannot call Singular function 'eliminate' with ring parameter of type '<class 'sage.rings.polynomial.multi_polynomial_ring.mpolynomialring_polydict_do\="" main'="">'

Sameer Agarwal gravatar imageSameer Agarwal ( 2010-08-26 04:14:24 +0200 )edit
1

answered 2010-08-26 11:24:49 +0200

niles gravatar image

When I try this, the error I get is a little more informative:

sage: I2 = I.elimination_ideal([x])
...
TypeError: Cannot call Singular function 'eliminate' with ring parameter of type 
'<class 'sage.rings.polynomial.multi_polynomial_ring.MPolynomialRing_polydict_domain'>'

The function eliminte comes from

sage: eliminate = sage.libs.singular.ff.eliminate

which is a wrapper for the Singular function and is supposed to convert Sage's rings to rings that Singular understands . . . however it seems that this wrapper does not understand the _polydict_domain rings. Perhaps one could convert R to a ring that the wrapper does understand (or file this as a bug in the wrapper and fix it). Checking, I see that there is a ring type MPolynomialRing_libsingular, but it only allows base rings from a very small list (like ZZ and finite fields).

Maybe someone who knows more about the Singular interface can help here?

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2010-08-26 03:12:25 +0200

Seen: 1,805 times

Last updated: Aug 26 '10