defining (partial) inverse image of a ring homomorphism

64 views
Skip to first unread message

Dima Pasechnik

unread,
Mar 10, 2020, 1:22:45 PM3/10/20
to sage-support
Suppose I have

R.<x,y,z>=QQ[]
K.<u,v>=QQ[]
f=R.hom([u*v,u^2,v^2-u^2])

then for any even degree p in K one can compute
a preimage under f (e.g. u^4-u*v goes to y^2+x, etc)

Does Sage support this kind of maps? Yes, I can write the code that will for an
even degree monomial in K compute the corresponding polynomial in R,
and use it, but this is a bit ugly.

Dima

Nils Bruin

unread,
Mar 11, 2020, 2:43:18 AM3/11/20
to sage-support
On Tuesday, March 10, 2020 at 6:22:45 AM UTC-7, Dima Pasechnik wrote:
Suppose I have

R.<x,y,z>=QQ[]
K.<u,v>=QQ[]
f=R.hom([u*v,u^2,v^2-u^2])

then for any even degree p in K one can compute
a preimage under f (e.g. u^4-u*v goes to y^2+x, etc)

I think the general way (which should be pretty performant for such a nice example) is to do it via reduction wrt. the graph ideal:

sage: R.<u,v,x,y,z>=PolynomialRing(QQ,order="degrevlex(2),degrevlex(3)")
sage: I=R.ideal([x-u^2,y-u*v,z-v^2])
sage: inv=lambda f:QQ['x,y,z']((I.reduce(f)))
sage: inv(u^2)
x

Obviously, the term order chosen will dictate what representative you get back, if the map isn't injective. You should of course choose an elimination order.

Markus Wageringel

unread,
May 1, 2020, 8:15:28 PM5/1/20
to sage-support
Am Mittwoch, 11. März 2020 03:43:18 UTC+1 schrieb Nils Bruin:
I think the general way (which should be pretty performant for such a nice example) is to do it via reduction wrt. the graph ideal:

sage: R.<u,v,x,y,z>=PolynomialRing(QQ,order="degrevlex(2),degrevlex(3)")
sage: I=R.ideal([x-u^2,y-u*v,z-v^2])
sage: inv=lambda f:QQ['x,y,z']((I.reduce(f)))
sage: inv(u^2)
x

Obviously, the term order chosen will dictate what representative you get back, if the map isn't injective. You should of course choose an elimination order.

I think it would be nice if we implemented this. It might not solve the very complicated cases, but most of the time when I want an inverse I already know that it can be computed easily, such as for linear or triangular transformations. Doing this computation manually every time is a bit cumbersome.
Reply all
Reply to author
Forward
0 new messages