GNOME Bugzilla – Bug 309182
exponential numbers with negative exponents can't be entered
Last modified: 2005-12-20 15:43:09 UTC
Please describe the problem: in scientific mode, the gcalctool howto explains how to enter an exponential number correctly. For instance it reads: number: 0.00000012 enter: 12 Exp 8 +/- display: 1.2e-7 From at least version 5.5.41 entering the keys [1] [2] [Exp] [8] [+/-] yields the number: -1.2e9 I can't find a way to enter negative exponents, which makes the app unusable for scientific purposes. Steps to reproduce: 1. Just try to enter any floating point number with a negative exponent in scientific mode 2. 3. Actual results: the negative sign is interpreted to belong to the mantissa Expected results: the negative sign has to go to the exponent Does this happen every time? Yes Other information:
When the support for arithmetic operator precedence was added into gcalctool in the 5.X.Y series, it looks like a section of code was removed from the +/- handling, that specifically dealt with changing the sign on the exponent. Now that the GNOME servers are back up, I'll get that added back in today. Having said that, you should be able to use the arithmetic operator precdence mode to enter these numbers. First do to the View menu and check the "Use Arithmetic Precedence" menu item. Then enter the number with: 12 Exp +/- 8 You'll notice that the order of entry is different, and I'll open a separate placeholder bug against the gcalctool documation, for this to be fixed. Tom, can you please confirm that you are able to successfully enter number in arithmetic operator precedence mode using the above approach. I've tried it with the latest gcalctool (5.6.18), but hopefully it should work with 5.5.41 too.
Created attachment 48456 [details] Patch to fix the problem.
Change checked back into CVS HEAD. I've bumped the version number in configure.in to 5.6.19.
I've opened bug #309210 to handle gcalctool documentation changes needed for GNOME 2.11/12.
Entering the keys 12 Exp +/- 8 gives -(12*10^)8 which means it does not work in version 5.5.41. The minus sign generated by "+/-" is not taken to belong to the exponent but in front of the whole expression. Anyway, thanks for your efforts. Cheers, Tom
Sorry, I gave you the wrong expression. In arithmetic precedence mode that should have been: 12 Exp - 8 (minus not change sign). Does that expression work for you? If it does, I'll fixup the doc bug reference too.
Allright, this way it works. Cheers!
Cool. I've update the gcalctool bug accordingly. Thanks.
Jeez. I write one line and make two mistakes. Let's try that again. Cool. I've updated the gcalctool documentation bug accordingly. Thanks.
*** Bug 314308 has been marked as a duplicate of this bug. ***
*** Bug 324598 has been marked as a duplicate of this bug. ***