Ask Your Question
1

Is there a way to create the ring of multi-variable polynomials over a field?

asked 2017-05-08 21:24:23 +0100

Anton Mellit gravatar image

updated 2017-05-09 16:32:08 +0100

Suppose I create a field in SAGE. Maybe it is my own field implemented in some particular way, but I know it is a field and it can do all the operations. Is there any way at all to create a ring of polynomials in several variables over my field? Of course it might be less efficient than SINGULAR implementation, but still some fall back "toy" implementation would be nice, so that I can run the "toy" Groebner basis algorithm on it.

UPDATE: it turns out, the question should have been formulated as "how to make SAGE believe that my field is a field?". Once this is solved, the usual PolynomialRing function works as expected.

edit retag flag offensive close merge delete

Comments

1

PolynomialRing does not help (and is the answer)?

dan_fulea gravatar imagedan_fulea ( 2017-05-08 22:41:53 +0100 )edit

By the way, if you have a nice implementation of some interesting field, please consider contributing it to Sage !

tmonteil gravatar imagetmonteil ( 2017-05-09 11:38:40 +0100 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2017-05-09 11:12:32 +0100

B r u n o gravatar image

As mentioned, PolynomialRing should work with your field.

Note though that the fact that you know it is a field is not the same as SageMath knows it is a field. And the second case is much more interesting of course, since then SageMath will provide you generic implementations for multivariate polynomial rings over fields (such as the "toy" Groebner basis algorithm).

To learn how to create some algebraic structure (with SageMath knowing its nature), you may begin with the thematic tutorial: How to implement new algebraic structures in Sage?

edit flag offensive delete link more

Comments

I am trying the following:

R0.<y1,y2,y3>=ZZ[]
R0F = R0.fraction_field()
Rx.<x1> = R0F[]
R1.<x1> = R0F.extension(x1^2-y1^3-1)
Rx.<x2> = R1[]
R2.<x2> = R1.extension(x2^2-y2^3-1)
Rx.<x3> = R2[]

The last command gives me NotImplementedError

Anton Mellit gravatar imageAnton Mellit ( 2017-05-09 11:53:03 +0100 )edit

I think I found a workaround:

def yesitis(proof=False):
    return True
R2.is_field = yesitis
Rx.<x3> = R2[]
Anton Mellit gravatar imageAnton Mellit ( 2017-05-09 13:11:17 +0100 )edit

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: 2017-05-08 21:24:23 +0100

Seen: 674 times

Last updated: May 09 '17