https://bugs.kde.org/show_bug.cgi?id=495232

--- Comment #5 from Gabriel Barrantes <gabriel.barrantes....@outlook.com> ---
(In reply to Wolfram Klaus from comment #3)
> (In reply to Gabriel Barrantes from comment #1)
> > I am getting "3e8/3e8 = 1", I guess you are getting "3⏨8/3⏨8 = 1e+16", but
> > this would be expected as the "⏨" is actually "*10^" so it does
> > "3*10^8/3*10^8". Actually gnome calculator does the same, check the
> > screenshot attached.
> 
> It is the expected behaviour to get 1E16 if you type "*" "1" "0" "^",
> because the "*" is an operator of equal precedence with /.
> 
> It is not the expected behaviour of the "*10^" key. This key has been in use
> for decades on calculators (including kcalc) to enter numbers in scientific
> notation without the need to surround them by braces. It is supposed to
> behave like 3E8 in most programming languages:
> 
> #include <stdio.h>
> int main()
> {
>   float one=3E8/3E8;
>   printf("%f", one);
> }
> prints  1.000000 on the terminal, as it should.
> 
> I just installed gnome-calculator, I couldn't even find the "*10^" key.

check the second attachment, there is a small button there with ... that will
show the button on the gnome calculator.

Either way, inputs like "3E8/3E8" actually result in 1, the problem I guess is
that the button is doing "*10^" and not "e" or "E" and that from the
mathematical sense is not the same.

I just checked Qalculate and they are inserting "e" instead of "*10^", and the
button label is "EXP" and not "*10^y", that could be an option, I guess that
people expect having the scientific notation take precedence even tho it
shouldn't (definitely should't when using *10^).

For now the button is doing what it should,  we could change it to be "e", but
let's wait to see if someone else reports the same.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to