Comments (6)
confirmed in mate-calc 1.20.3
from mate-calc.
Confirmed in 1.22.0 as well
from mate-calc.
It doesn't work in gnome-calculator 3.11.90
It works in gnome-calculator 3.12.0
from mate-calc.
seems it was fixed for gnome-calculator with one of these commits, (or both):
Fix precision loss of ln(e^1) (fixes bug 711766)
https://gitlab.gnome.org/GNOME/gnome-calculator/commit/e1ba299acfe4cf6631de4d457b9451471171ee39
Use double instead of float for better precision ln (fixes bug 702817).
https://gitlab.gnome.org/GNOME/gnome-calculator/commit/6eb0f2b5e6df456a97a796b35d811376a69679e0
from mate-calc.
It seems to be related the function mp_ln_real
in /src/mp.c
from mate-calc.
Preferences -> Calculator -> Angle Units -> Radians
e^(i*π) = cos(π) + sin(π)i = -1 + 0i = -1 [WORKS]
ln(-1) = ln(-(-1)) + πi = ln(1) + πi = 0 + πi = πi [WORKS]
Fails on parse.
(gdb) backtrace
#0 0x000000000041f0c4 in mp_set_from_float (rx=<optimized out>, z=z@entry=0x7fffcd7e8060) at mp-convert.c:54
#1 0x000000000041df60 in mp_ln_real (x=x@entry=0x7fffcd7f1d20, z=z@entry=0x7fffcd7f5bc0) at mp.c:1256
#2 0x000000000041e31e in mp_ln (x=x@entry=0x7fffd0013bf0, z=z@entry=0x7fffd0011c90) at mp.c:1297
#3 0x00000000004206d6 in get_function (state=0x7fffd000fcd0, name=0x7fffd00015c0 "ln", x=0x7fffd0013bf0, z=0x7fffd0011c90) at mp-equation.c:173
#4 0x0000000000427962 in pf_apply_func (self=0x7fffd0004e10) at parserfunc.c:306
#5 0x0000000000429b1b in p_parse (state=state@entry=0x7fffd000fcd0) at parser.c:276
#6 0x0000000000421139 in mp_equation_parse (expression=expression@entry=0xd9ccc0 "ln(e^(i×π))", options=options@entry=0x7fffcd7f7be0, result=result@entry=0x7fffcd7f7c30, error_token=error_token@entry=0x7fffcd7f7bd8) at mp-equation.c:266
#7 0x0000000000415ec1 in parse (error_token=0x7fffcd7f7bd8, z=0x7fffcd7f7c30, text=<optimized out>, equation=0x4faa90) at math-equation.c:1184
#8 0x0000000000415ec1 in math_equation_solve_real (data=<optimized out>) at math-equation.c:1219
#9 0x00007ffff716f752 in () at /lib64/libglib-2.0.so.0
#10 0x00007ffff6f975a2 in start_thread () at /lib64/libpthread.so.0
#11 0x00007ffff6ec4023 in clone () at /lib64/libc.so.6
from mate-calc.
Related Issues (20)
- Eulers identity gives no (blank) result HOT 1
- App consuming 100% of CPU with common usage HOT 2
- Prime factorization is not displayed in history view
- wrong result for (535^125x125^854) mod 1283
- [atan] arctan does not get calculated correctly HOT 4
- incorrect parenthesis handling HOT 1
- Calculation order error HOT 1
- Convergence issue with the ln function HOT 1
- mpc is required, but not searched HOT 5
- Window all cut off on Librem 5/small screen HOT 3
- 1.25.1: test suite is failing with core dump HOT 6
- [Question] [History listbox] How can I change the foreground color from 'black to 'white'?? HOT 1
- mate-calc: Financial mode incorrectly places currency for Russian Rouble HOT 2
- mate-calc: issues with Russian localization - not translated items HOT 1
- Paste figures with spaces should either cut or ignore spaces
- Complicated expressions with logarithm return incorrect results HOT 2
- provide option for pressure conversion HOT 2
- Expressions like e²3 crashes mate-calc HOT 4
- [Feature request] A Quit button HOT 2
- Error with log() HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mate-calc.