Ask Your Question

Lauren's profile - activity

2023-01-02 10:46:02 +0200 received badge  Notable Question (source)
2023-01-02 10:46:02 +0200 received badge  Popular Question (source)
2015-01-28 21:57:06 +0200 received badge  Student (source)
2015-01-28 16:33:16 +0200 received badge  Scholar (source)
2014-12-16 06:16:23 +0200 asked a question Computations in a Quotient Ring

I'm trying to do some computations in a quotient ring in Sage, and I'm having some trouble. For example:

Working with the ring:

R.<x,y,z,w,u,z1,z2,z3,z4,z5> = PolynomialRing(QQ,10)
S.<a,b,c,d,e,m1,m2,m3,m4,m5> = R.quo((x^2,y^2+x*y, z^2+x*z + y*z, w^2 - w*x+w*y, u^2 + u*x+ u*z + u*w))

I want to compute (a*(m3+m4+m5) + b*(m1+m2+m3+m4) + c*(m1+m3) + d*(m1+m2) + e*m1)^5

where I'm thinking about m1, m2, m3, m4, and m5 as arbitrary coefficients. When I type this in it returns

4/19*e^5*m1^5 + 15/19*e^5*m1^4*m2 + 10/19*e^5*m1^3*m2^2 +
10/19*e^5*m1^4*m3 + 40/19*e^5*m1^3*m2*m3 + 15/19*e^5*m1^2*m2^2*m3 -
15/19*e^5*m1*m2^2*m3^2 - 5/19*e^5*m1^2*m3^3 - 10/19*e^5*m1*m2*m3^3 +
5/19*e^5*m1^4*m4 - 15/19*e^5*m1^2*m2^2*m4 - 30/19*e^5*m1*m2^2*m3*m4 -
15/19*e^5*m1^2*m3^2*m4 - 30/19*e^5*m1*m2*m3^2*m4 - 10/19*e^5*m1^3*m4^2 -
15/19*e^5*m1^2*m2*m4^2 - 15/19*e^5*m1^2*m3*m4^2 -
30/19*e^5*m1*m2*m3*m4^2 - 5/19*e^5*m1^4*m5 - 20/19*e^5*m1^3*m2*m5 -
15/19*e^5*m1^2*m2^2*m5 - 20/19*e^5*m1^3*m3*m5 - 60/19*e^5*m1^2*m2*m3*m5
- 30/19*e^5*m1*m2^2*m3*m5 - 15/19*e^5*m1^2*m3^2*m5 -
30/19*e^5*m1*m2*m3^2*m5 - 20/19*e^5*m1^3*m4*m5 - 30/19*e^5*m1^2*m2*m4*m5
- 30/19*e^5*m1^2*m3*m4*m5 - 60/19*e^5*m1*m2*m3*m4*m5

However, this is also equivalent to (some expression of mi's)*a*b*c*d*e.

I want it in this form, because for the problem I'm working on I need this coefficient in front of a*b*c*d*e. But I'm not sure how to ask Sage to convert it to this form? For example, "solve" doesn't seem to work in a quotient ring.

(I'm sorry if this is a silly question. I'm new to Sage!)