It sounds like a C program using MPFR (http://www.mpfr.org) would do what you want. As MPFR is built into SAGE, you might perhaps find it more convenient to invoke MPFR within SAGE.
Sincerely, Greg Marks ------------------------------------------------ | Greg Marks | | Department of Mathematics and Computer Science | | St. Louis University | | St. Louis, MO 63103-2007 | | U.S.A. | | | | Phone: (314)977-7206 | | Fax: (314)977-1452 | | Web: http://math.slu.edu/~marks | ------------------------------------------------ On Sep 8, 11:19 am, KvS <keesvansch...@gmail.com> wrote: > Dear all, > > I am trying to implement a recursive algorithm that is rather complex, > in the sense that it uses a high number of variables and (elementary) > computations. The output in Sage looks fine but it gets quite slow, so > I am thinking of ways to speed it up. Given that it is mainly a lot of > looping and a lot of elementary computations, I would guess > translating it to Cython could help a lot. > > However I am afraid that doubles won't have enough precision to avoid > too much numerical noise in the end result of the algorithm. So I > would like to use a higher precision real number representation. The > question is whether this is possible, and if so what is a sensible > choice? Could/Should I use mpmath e.g. or rather something else? What > I need to be doing, next to elementary computations, is: > > - compute exponentials > - perform find_root's > - being able to store those real numbers in a few big Numpy-arrays. > > I am very grateful for any hint! > > Many thanks, Kees -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org