Ask Your Question
0

Coercion - polynomial in two variable/polynomial in one variable over function field

asked 2023-11-28 22:10:09 +0100

jgarnek gravatar image

updated 2023-11-28 23:39:46 +0100

I need to convert a polynomial $P \in \overline{\mathbb F}_p[x, y]$ to a polynomial in $\overline{\mathbb F}_p(x)[y]$. The following code works when the first line is replaced by F = GF(3), but at present it returns "ValueError: finite field modulus must be irreducible but it is not".

F = GF(3).algebraic_closure()
Rxy.<x, y> = PolynomialRing(F, 2)
g = x*y
Rx.<x> = PolynomialRing(F)
Fx = FractionField(Rx)
FxRy.<y> = PolynomialRing(Fx)
h = FxRy(g)
print(h)

Is there an easy fix? What is the reason? Edit: checked on SageMath 10.1 (on cocalc).

edit retag flag offensive close merge delete

Comments

First, it looks like you're trying to convert the polynomial to an element in $\overline{\mathbb F}_p(x)[y]$ (note $(x)$ instead of $[x]$). Second, what version of Sage are you using, and what platform? This doesn't seem to work for me, either, but the line h = FxRy(g) just hangs rather than raising an error. (I'm using the latest beta release.)

John Palmieri gravatar imageJohn Palmieri ( 2023-11-28 22:38:14 +0100 )edit

Yes, I made a mistake in the description, I meant the polynomial ring over the function field. Version is 10.1 via http://cocalc.com.

jgarnek gravatar imagejgarnek ( 2023-11-28 23:26:15 +0100 )edit

1 Answer

Sort by » oldest newest most voted
2

answered 2023-11-29 00:55:26 +0100

Max Alekseyev gravatar image

updated 2023-11-29 00:56:35 +0100

In your code you define x and y and then re-define them in a new way, which may be confusing. Below I distinguish the variables definitions and convert g into h by simply evaluating it at new variables:

F = GF(3).algebraic_closure()
Rxy.<x, y> = PolynomialRing(F, 2)
g = x*y
Rx.<xx> = PolynomialRing(F)
Fx = FractionField(Rx)
FxRy.<yy> = PolynomialRing(Fx)
h = g(xx,yy)
edit flag offensive delete link more

Comments

Thanks! I tried distinguishing only y earlier, but it wasn't enough.

jgarnek gravatar imagejgarnek ( 2023-11-29 09:25:32 +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: 2023-11-28 22:10:09 +0100

Seen: 122 times

Last updated: Nov 29 '23