[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gmp-discuss
Subject:    Exponential of a mpf_t or mpf_class
From:       linas () austin ! ibm ! com (Linas Vepstas)
Date:       2006-08-16 15:53:00
Message-ID: 20060816155300.GA20551 () austin ! ibm ! com
[Download RAW message or body]

On Wed, Aug 16, 2006 at 11:29:03AM -0400, Marc wrote:
> Hello,
> 
> I've been using mpf_class and mpf_t in some numerical programs where the
> results do not fit into doubles. All was well until it was required to take
> the exponential of an mpf_t.
> 
> Specifically, I've been using GNU GSL with GNU GMP. Calling gsl_sf_exp() on
> a mpf_t that has been converted to a double results in an overflow. I'd
> appreciate help in solving this problem. I looked to see if there was an
> arbitrary power function to a float for GMP, but didn't see one listed in
> the documentation.
> 
> I'd appreciate any possible solutions for this problem. GMP has solved many
> of my large number problems, but this last issue remains.

I've been using a home-made implementation of exp by merely summing up
the plain-old power-series x^n/n! by brute force. For values of x < 10K
this will converge fairly rapidly (i.e. with order of 10K multiply-adds 
or less)

--linas


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic