Hello all,

I don´t know if the following is an error in the implementation of the
method polynomial
or if I am using it in a way that is not intended, but it seems that
the use of the method
polynomial changes when I am in a polynomial ring with 2 or with 3
variables.

pol and pol2 are the "same" polynomial in rings with 3 or 2 variables
resp. and
the method pol.polynomial(q) and pol2.polynomial(q) return different
answers.


sage: R.<p,q,t>=ZZ[]
sage: pol=2+3*q+4*q^3;pol
4*q^3 + 3*q + 2
sage: parent(pol)
Multivariate Polynomial Ring in p, q, t over Integer Ring
sage: pol2=pol.polynomial(t).coefficients()[0];pol2
4*q^3 + 3*q + 2
sage: parent(pol2)
Multivariate Polynomial Ring in p, q over Integer Ring
sage: pol2.polynomial(q)
2
sage: pol.polynomial(q)
4*q^3 + 3*q + 2

Can anyone give me some insight about why I am getting these
different answers?

Thanks!

Rafael

-- 
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to 
sage-support+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org

Reply via email to