ASKSAGE: Sage Q&A Forum - Individual question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Wed, 29 May 2019 15:56:10 -0500How to perform modulus in polynomial rings..http://ask.sagemath.org/question/46700/how-to-perform-modulus-in-polynomial-rings/The following code i wrote in cocalc.com in sage sheet
x = PolynomialRing(RationalField(), 'x').gen()
a = PolynomialRing(RationalField(), 'a').gen()
b = PolynomialRing(RationalField(), 'b').gen()
f =a* x/(x+1)
g = b*x**3/(x+1)
g1 = f%g
print g1
It is giving error.
My main objective is to find quotient and remainder.Thanks in advance.Wed, 29 May 2019 12:17:28 -0500http://ask.sagemath.org/question/46700/how-to-perform-modulus-in-polynomial-rings/Comment by rburing for <p>The following code i wrote in <a href="http://cocalc.com">cocalc.com</a> in sage sheet</p>
<pre><code>x = PolynomialRing(RationalField(), 'x').gen()
a = PolynomialRing(RationalField(), 'a').gen()
b = PolynomialRing(RationalField(), 'b').gen()
f =a* x/(x+1)
g = b*x**3/(x+1)
g1 = f%g
print g1
</code></pre>
<p>It is giving error.
My main objective is to find quotient and remainder.Thanks in advance.</p>
http://ask.sagemath.org/question/46700/how-to-perform-modulus-in-polynomial-rings/?comment=46702#post-id-46702`f` and `g` are not polynomials but rational functions (with denominators), so what do you mean? What quotient and remainder do you expect?Wed, 29 May 2019 15:56:10 -0500http://ask.sagemath.org/question/46700/how-to-perform-modulus-in-polynomial-rings/?comment=46702#post-id-46702