After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 702817 - ln (e^x) : Overflow: the result couldn't be calculated (for x >= 3)
ln (e^x) : Overflow: the result couldn't be calculated (for x >= 3)
Status: RESOLVED FIXED
Product: gnome-calculator
Classification: Core
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: gcalctool maintainers
gcalctool maintainers
Depends on: 698400
Blocks:
 
 
Reported: 2013-06-21 14:23 UTC by PioneerAxon
Modified: 2014-12-22 20:36 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (2.58 KB, patch)
2014-02-26 02:11 UTC, Daniel Renninghoff
committed Details | Review

Description PioneerAxon 2013-06-21 14:23:52 UTC
Reported by Rob on the mailing list [1].

When entered equation in the form of

ln (e^x)

where x >= 3, Calculator gives following error : "Overflow: the result couldn't be calculated".

Expected result is value of x.

[1] : https://mail.gnome.org/archives/gcalctool-list/2013-June/msg00000.html
Comment 1 Daniel Renninghoff 2014-02-26 02:11:23 UTC
Created attachment 270343 [details] [review]
patch

Hi, I've fixed this bug.

When using doubles instead of floats, the precision is high enough to not cause an overflow.

Btw: overflows are almost always caused by adding a really small number, such as 0.9e-99 :)
Comment 2 PioneerAxon 2014-03-05 18:25:34 UTC
Review of attachment 270343 [details] [review]:

Daniel,

Thanks for the patch. :)
It works fine for any number till 55.

I'm keeping the bug still open.
Comment 3 PioneerAxon 2014-12-22 20:36:12 UTC
The issue has been fixed.

Reference commit : https://git.gnome.org/browse/gnome-calculator/commit/?id=0e863eeb121d670d8f5266a82b6152e98b2428ea