https://bugs.documentfoundation.org/show_bug.cgi?id=114922
Bug ID: 114922
Summary: Calc misinterprets order of operations
Product: LibreOffice
Version: 5.3.7.2 release
Hardware: x86-64 (AMD64)
OS: Linux (All)
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Calc
Assignee: [email protected]
Reporter: [email protected]
Description:
Bad calculation of exponents, x^n provides the same result as -x^n.
Steps to Reproduce:
1. Put a number into a cell in LO Calc, e.g. "6" in cell A1.
2. In another cell, try to calculate relation "=-A1^2".
3. The result should be -36, LO Calc gives 36.
Actual Results:
The LO Calc calculates the relation as if parentheses were present, for -A1^2,
where A1=6 it gives 36, which is incorrect.
Expected Results:
It is expected to first process the power operation, then addition of sign.
Reproducible: Always
User Profile Reset: Yes
OpenGL enabled: Yes
Additional Info:
See these relations, they are not the same, yet LO processes them identically:
1. -x^n
2. (-x)^n
The first expression should be processed as -(x^n), not as the second one. Just
check the same relations in e.g. GNU/Octave.
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like
Gecko) Chrome/57.0.2987.98 Safari/537.36
--
You are receiving this mail because:
You are the assignee for the bug._______________________________________________
Libreoffice-bugs mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs