#2329: add interface to Pari's rnfisnorm
-----------------------------------------+----------------------------------
   Reporter:  craigcitro                 |       Owner:  craigcitro       
       Type:  enhancement                |      Status:  needs_work       
   Priority:  major                      |   Milestone:  sage-4.6.1       
  Component:  number fields              |    Keywords:  editor_craigcitro
     Author:  Craig Citro, Marco Streng  |    Upstream:  N/A              
   Reviewer:  Nick Alexander             |      Merged:                   
Work_issues:  bug in Pari 2.3.5          |  
-----------------------------------------+----------------------------------
Changes (by fwclarke):

  * work_issues:  compilation problems => bug in Pari 2.3.5


Comment:

 Replying to [comment:15 davidloeffler]:

 > ..., it *still* doesn't work:
 {{{
 sage -t  number_field_element.pyx
 **********************************************************************
 File "/storage/masiao/sage-4.6.alpha1/devel/sage-
 hacking/sage/rings/number_field/number_field_element.pyx", line 971:
     sage: (beta/2).is_norm(L)
 Exception raised:
     Traceback (most recent call last):
 ...
 File "gen.pyx", line 9470, in sage.libs.pari.gen._pari_trap
 (sage/libs/pari/gen.c:45353)
 PariError:  (5)
 **********************************************************************
 }}}
 > At that point I gave up. Sorry. That's "needs work".

 Looks like a Pari bug.  This is what the doctest asks Pari to do (with the
 equivalent of beta.is_norm(L) first):

 {{{
 trousseau-bash% sage-4.6/sage -gp
                    GP/PARI CALCULATOR Version 2.4.3 (development
 svn-12577:12605)
                     i386 running darwin (x86-64/GMP-4.2.1 kernel) 64-bit
 version
 ...
 parisize = 8000000, primelimit = 500509
 ? bnf = bnfinit(y^3 + 5);
 ? p = x^2 + x + Mod(y, y^3 + 5);
 ? T = rnfisnorminit(bnf, p);
 ? rnfisnorm(T, Mod(y, y^3 + 5))
 %4 = [Mod(x, x^2 + x + Mod(y, y^3 + 5)), 1]
 ? rnfisnorm(T, Mod(y/2, y^3 + 5))
   ***   at top-level: rnfisnorm(T,Mod(y/2,
   ***                 ^--------------------
   *** rnfisnorm: zero argument in factorint.
   ***   Break loop: type 'break' to go back to GP
 break> break
 }}}
 But previously, it worked alright:

 {{{
 trousseau-bash% sage-4.5.3/sage -gp
                             GP/PARI CALCULATOR Version 2.3.5 (released)
                     i386 running darwin (x86-64/GMP-4.2.1 kernel) 64-bit
 version
 ...
 parisize = 8000000, primelimit = 500000
 ? bnf = bnfinit(y^3 + 5);
 ? p = x^2 + x + Mod(y, y^3 + 5);
 ? T = rnfisnorminit(bnf, p);
 ? rnfisnorm(T, Mod(y, y^3 + 5))
 %4 = [Mod(-x, x^2 + x + Mod(y, y^3 + 5)), 1]
 ? rnfisnorm(T, Mod(y/2, y^3 + 5))
 %5 = [Mod(Mod(-1/2, y^3 + 5)*x, x^2 + x + Mod(y, y^3 + 5)), 2]
 ?
 }}}
 Note also that the two versions give a different result at %4.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/2329#comment:17>
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 post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en.

Reply via email to