Re: [sage-support] Re: Convolution Polynomial Ring
Thanks. But in this ring, I can not find gcd. N=7 p=3 R2. = PolynomialRing(GF(p)) S. = R2.quotient(b^N - 1) f=x^6-x^4+x^3+x^2-1 g=x^6+x^4-x^2-x print gcd(f,g),xgcd(f,g) Traceback (click to the left of this block for traceback) ... TypeError: unable to find gcd On 23 August 2013 03:10, Stefan van Zwam wrote: > On Thursday, August 22, 2013 4:06:22 PM UTC-4, Santanu wrote: > >> How to define polynomial ring like Z[x]/(x^10-1) & Z_5[x]/(x^10-1) in >> Sage? >> >> > sage: R1. = PolynomialRing(ZZ) > sage: R. = R1.quotient(a^10 - 1) > > sage: R2. = PolynomialRing(GF(5)) > sage: S. = R2.quotient(b^10 - 1) > > Now you can do: > > sage: x^12 > x^2 > > sage: y^14 + 7 * y > y^4 + 2*y > > -- > 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/groups/opt_out. > -- 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/groups/opt_out.
[sage-support] Re: Convolution Polynomial Ring
On Thursday, August 22, 2013 4:06:22 PM UTC-4, Santanu wrote: > How to define polynomial ring like Z[x]/(x^10-1) & Z_5[x]/(x^10-1) in > Sage? > > sage: R1. = PolynomialRing(ZZ) sage: R. = R1.quotient(a^10 - 1) sage: R2. = PolynomialRing(GF(5)) sage: S. = R2.quotient(b^10 - 1) Now you can do: sage: x^12 x^2 sage: y^14 + 7 * y y^4 + 2*y -- 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/groups/opt_out.
[sage-support] Re: Convolution Polynomial Ring
How to define polynomial ring like Z[x]/(x^10-1) & Z_5[x]/(x^10-1) in Sage? On 22 August 2013 12:37, Santanu Sarkar wrote: > Dear all, > Is convolution polynomial ring implemented in Sage? > I want to implement NTRU public key cryptosystem. Hence I need > modular inverse of a polynomial also in the ring. > > With regards, > Santanu > -- 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/groups/opt_out.