#11952: Fix conversion Python -> PARI
--------------------------+-------------------------------------------------
   Reporter:  jdemeyer    |          Owner:  was                                
                   
       Type:  defect      |         Status:  needs_work                         
                   
   Priority:  major       |      Milestone:  sage-4.7.3                         
                   
  Component:  interfaces  |       Keywords:                                     
                   
Work_issues:              |       Upstream:  N/A                                
                   
   Reviewer:              |         Author:  Jeroen Demeyer                     
                   
     Merged:              |   Dependencies:  #11130, #11321, #11854, #11891, 
#11890, #11836, #11904
--------------------------+-------------------------------------------------
Description changed by jdemeyer:

Old description:

> Conversion of a Python `complex` to PARI fails:
> {{{
> sage: pari(complex(I))
>   ***   Warning: unused characters: j.
> 1
> }}}
>
> Moreover, the conversion of other Python types to PARI can be improved by
> adding special code instead of using strings.

New description:

 Conversion of a Python `complex` to PARI fails:
 {{{
 sage: pari(complex(I))
   ***   Warning: unused characters: j.
 1
 }}}

 Moreover, the conversion of other Python types to PARI can be improved by
 adding special code instead of using strings.  This also makes the
 conversion more precise, see the example below:

 Without patch:
 {{{
 sage: f = float(4651990089563211/4503599627370496)
 sage: f
 1.0329493015522242
 sage: pari(f)
 1.03294930155000
 }}}
 With patch:
 {{{
 sage: f = float(4651990089563211/4503599627370496)
 sage: f
 1.0329493015522242
 sage: pari(f)
 1.03294930155222
 }}}

--

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/11952#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 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