help-gsl
[Top][All Lists]
Advanced

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

[Help-gsl] strange behaviour of addition of floats and exponential funct


From: Chandra Sekhar Mallarapu
Subject: [Help-gsl] strange behaviour of addition of floats and exponential function
Date: Wed, 26 Jan 2011 15:18:16 +0000

Hi
I am trying to do C=A+B, where 
A=0.0000000000000000021675312011946934078589202290913712085038187871567725434340800916288571897894144058
and 
B=0.0589894145005643161239206051504879724234342575073242187500000000000000000000000000000000000000000000

Value of C turns out to be equal to B, the value of A is not added to it. Why 
does that happen?

Moreover, I am using 
gsl_sf_exp(0.0000000000000000000000005731906218817495693050559208091994557794428814131237532386326994000326495726),
 and it gives me the value as 
1.0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,
 instead of the actual value. What can I do to get a better answer for the 
result of the exponential function?

Thanks
Chandra


reply via email to

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