-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve besselj accuracy for large arguments for orders -1, 0, 1 #56
Comments
Very much thank you for this report!!!! And the details are so helpful. @oscardssmith this looks related to Lines 4 to 20 in 3bd0109
On a quick inspection.. julia> cos_sum(1e20, 1.2)
-3.5964366282318264e27
julia> cos(1e20 + 1.2)
0.7639704044417283 |
Relevant discussion on where this was introduced. Sure enough as Oscar said as long as x<1e16. I’m sorry for this I should have had tests for very large inputs. |
Great! Such fast work :) |
Thank you very much for the bug report! It is much appreciated. Hopefully this is fixed on master and will tag a new release soon. If the situation persists please let me know and can reopen! |
Related to #37, which gives examples for order 11 and argument 1e9.
It looks as though the large argument expansions for
besselj0
andbesselj1
are also inaccurate. I made a gist comparing the differences with SpecialFunctions.jl over a large range of orders and magnitude of argument.The gist produces this figure indicating that the errors blow up for orders -1, 0 and 1 and arguments > 1e16.
BesseljComparison.pdf
The text was updated successfully, but these errors were encountered: