On Sat, Mar 14, 2015 at 6:30 PM, david.guichard
<david.guich...@gmail.com> wrote:
> I want to do something like this:
>
> R = PolynomialRing(QQ,'x');S.<a>=R.quotient(x^3+x+1);
> T.<b>=QQ[]
> b*a
>
> Namely, create expressions mixing rational variables and elements of a
> quotient field over the rationals.
>
> Doing something like this:
>
> (3/4)*a
>
> is fine, but the b*a, gives me
>
> TypeError: unsupported operand parent(s) for '*': 'Univariate Polynomial
> Ring in b over Rational Field' and
> 'Univariate Quotient Polynomial Ring in a over Rational Field with modulus
> x^3 + x + 1'
>
>
> Is there a way to do what I want?

Use a number field instead:

R.<x> = QQ[]
S.<a> = NumberField(x^3 + x + 1)
T.<b> = QQ[]
a*b


https://cloud.sagemath.com/projects/4a5f0542-5873-4eed-a85c-a18c706e8bcd/files/support/2015-03-14-poly-nf.sagews

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



-- 
William (http://wstein.org)

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

Reply via email to