On Fri, 03 Nov 2006 08:04:18 -0800, Joel B. Mohler <[EMAIL PROTECTED]> wrote:
> > On Fri, Nov 03, 2006 at 06:29:39AM -0800, William Stein wrote: >> >> On Fri, 03 Nov 2006 03:11:31 -0800, Joel B. Mohler >> <[EMAIL PROTECTED]> wrote: >> >> > >> > It appears that the python complex_number class was moved to pyrex, >> but >> > then >> > the converted class was blithely ignored. Are they supposed to both >> > still >> > exist? >> >> It's in transition. The pyrex class is in the file complex_number2.pyx. >> I've just been looking for somebody to finish it. Would you!? > > Ok, I wondered if that was the case. I'll take a look at it and try and > figure out exactly how unfinished it is (hints on that would be > appreciated). Little did I realize that my little complex number bug > would grow into a pyrexification :-). The main advise is "make it fast". You could look at mpc, which is supposed to be a c library for complex numbers on top of MPFR, but I was unimpressed when I looked into it last, which was a year ago. Basically -- use mpfr to store complex numbers as pairs of reals and do arithmetic with them. Use the PARI C library for complex special functions, since it seems to be the only program that implements them with arbitrary precision. Getting this to all work perfectly will be somewhat nontrivial -- the main difficult is using PARI for special functions efficiently. -- William --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---