I was exploring some quotient ring operations and came across the following:

{{{
R.<y>=QQ[]
K.<w>=NumberField(y^3 + 2*y - 2401)
k.<v>=K.quo(K.prime_factors(7)[1])
R.<x,y>=PolynomialRing(k)
R.monomial_divides(y,x^3*y)
Error
}}}

{{{
R.<y>=QQ[]
K.<w>=NumberField(y^3 + 2*y - 2401)
k.<v>=K.residue_field(K.prime_factors(7)[1])
R.<x,y>=PolynomialRing(k)
R.monomial_divides(y,x^3*y)
True
}}}

The second works, the first does not. I came across this since 
.monomial_divides is used is a groebner basis computation. So played around 
a little more and the following seems weirder

{{{
A.<x,y,z> = PolynomialRing(Zmod(42))
A.monomial_divides(y,x^2*y)
True
}}}

{{{
A.<x,y,z> = PolynomialRing(Zmod(2521515232))  #but one less digit works
A.monomial_divides(y,x^2*y)
Error
}}

The first works, but the 2nd does not, even though neither is prime. It 
seems to have to do with what type of polynomial ring they are initialized 
as, but I had a hard time tracking down where that code lived and how it 
decided. Is there someone familiar with polynomial rings in Sage who could 
shed some light on whether this is expected behavior?

Thanks,
  Ben

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to