#21000: wrong result for pari minpoly
-------------------------------------------------+-------------------------
       Reporter:  vdelecroix                     |        Owner:
           Type:  defect                         |       Status:  new
       Priority:  major                          |    Milestone:  sage-7.3
      Component:  interfaces                     |   Resolution:
       Keywords:                                 |    Merged in:
        Authors:                                 |    Reviewers:
Report Upstream:  Reported upstream. No          |  Work issues:
  feedback yet.                                  |
         Branch:                                 |       Commit:
   Dependencies:                                 |     Stopgaps:
-------------------------------------------------+-------------------------
Description changed by vdelecroix:

Old description:

> {{{
> sage: R.<x> = ZZ[]
> sage: q = x^24 - 12*x^23 + 70*x^22 - 264*x^21 + 757*x^20 - 1872*x^19 +
> 4258*x^18 - 8796*x^17 + 15922*x^16 - 24900*x^15 + 33886*x^14 - 40608*x^13
> + 43117*x^12 - 40608*x^11 + 33886*x^10 - 24900*x^9 + 15922*x^8 - 8796*x^7
> + 4258*x^6 - 1872*x^5 + 757*x^4 - 264*x^3 + 70*x^2 - 12*x + 1
> sage: pari(1).Mod(q).minpoly()
> x - 1
> sage: pari(1+x-x).Mod(q).minpoly()
> x
> }}}
> This is reproducible in a gp console
> {{{
> ? q = x^24 - 12*x^23 + 70*x^22 - 264*x^21 + 757*x^20 - 1872*x^19 +
> 4258*x^18 - 8796*x^17 + 15922*x^16 - 24900*x^15 + 33886*x^14 - 40608*x^13
> + 43117*x^12 - 40608*x^11 + 33886*x^10 - 24900*x^9 + 15922*x^8 - 8796*x^7
> + 4258*x^6 - 1872*x^5 + 757*x^4 - 264*x^3 + 70*x^2
> ? minpoly(Mod(1, q))
> %2 = x - 1
> ? minpoly(Mod(1+x-x, q))
> %3 = x
> }}}
>
> Original report
>
>     https://groups.google.com/forum/#!topic/sage-devel/GfanbBRor6M

New description:

 {{{
 sage: R.<x> = ZZ[]
 sage: q = x^24 - 12*x^23 + 70*x^22 - 264*x^21 + 757*x^20 - 1872*x^19 +
 4258*x^18 - 8796*x^17 + 15922*x^16 - 24900*x^15 + 33886*x^14 - 40608*x^13
 + 43117*x^12 - 40608*x^11 + 33886*x^10 - 24900*x^9 + 15922*x^8 - 8796*x^7
 + 4258*x^6 - 1872*x^5 + 757*x^4 - 264*x^3 + 70*x^2 - 12*x + 1
 sage: pari(1).Mod(q).minpoly()
 x - 1
 sage: pari(1+x-x).Mod(q).minpoly()
 x
 }}}
 This is reproducible in a gp console
 {{{
 ? q = x^24 - 12*x^23 + 70*x^22 - 264*x^21 + 757*x^20 - 1872*x^19 +
 4258*x^18 - 8796*x^17 + 15922*x^16 - 24900*x^15 + 33886*x^14 - 40608*x^13
 + 43117*x^12 - 40608*x^11 + 33886*x^10 - 24900*x^9 + 15922*x^8 - 8796*x^7
 + 4258*x^6 - 1872*x^5 + 757*x^4 - 264*x^3 + 70*x^2 - 12*x + 1;
 ? minpoly(Mod(1, q))
 %2 = x - 1
 ? minpoly(Mod(1+x-x, q))
 %3 = x
 }}}

 Original report

     https://groups.google.com/forum/#!topic/sage-devel/GfanbBRor6M

--

--
Ticket URL: <https://trac.sagemath.org/ticket/21000#comment:7>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

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

Reply via email to