You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I was implementing the logarithm of gamma function for complex numbers, I found that the lgamma for complex numbers is not quite as precies as lgamma for reals.
Finally I found out that, the precision of sin for complex numbers is high, but not extremely high.
I'm not sure how much impact this difference has. Even I use the correct sin results to continue to compute lgamma, the precision get improved, but it seems that it's still not as precies as that for reals.
But anyway, this issue is for the sine algorithm for complex numbers.
The text was updated successfully, but these errors were encountered:
As you can see, this was a bug reported in complex.js almost four years ago, with a suggested fix that seems to work absolutely fine. Hopefully this additional report can induce some motion on a fix; if not, we will simply implement the fix suggested in the above issue in complex.js, but internally in mathjs. Thanks for the detailed report!
When I was implementing the logarithm of gamma function for complex numbers, I found that the lgamma for complex numbers is not quite as precies as lgamma for reals.
Finally I found out that, the precision of
sin
for complex numbers is high, but not extremely high.We can get a reference result from WolframAlpha: https://www.wolframalpha.com/input?i=sin%5B3.141592653589793e-9+%2B+3.14159273913291e-9i%5D
The real numbers are the same, but there is a little difference between the imaginary numbers:
I'm not sure how much impact this difference has. Even I use the correct sin results to continue to compute lgamma, the precision get improved, but it seems that it's still not as precies as that for reals.
But anyway, this issue is for the sine algorithm for complex numbers.
The text was updated successfully, but these errors were encountered: