bug-gmp
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

wishlist: support for long doubles; new add/multiply routines


From: Dan Christensen
Subject: wishlist: support for long doubles; new add/multiply routines
Date: Sun, 05 Aug 2001 13:26:42 -0400
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.0.100

Here are two wishlist items, the first being very important to
me, and the second being more superficial.

1) It would be great to be have long double versions of the
   mpf_set_d and mpf_get_d functions.  I have a large code base
   that uses long doubles, and in all but one spot long doubles
   give sufficient precision.  But in that one spot I want to use
   gmp, and to do so it seems like I have to convert to doubles
   in between, which loses all the precision I need.  I could
   of course use gmp everywhere, but that would require changing
   too much code.  Am I overlooking any other workarounds?

2) I often find myself wanting to add or multiple a mpf_t variable
   by a double (or long double).  Currently I need to declare a
   second mpf_t, init it, mpf_set it, and do the mpf_mul.  It
   would be great if there was a function mpf_mul_d analogous to
   mpf_mul_ui.  Here there is an obvious workaround, which is to
   write this function myself using a temporary variable, but I
   guess I'm wondering if a built-in function to do this might be
   faster.

I did a quick search of the archives and didn't see any discussion
of these possibilities.

Thanks for a wonderful package!

Dan

-- 
Dan Christensen
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]