JuliaMath / JuliaMath/Bessels.jl

`besselj(n, x)` returns `NaN` when `x` is negative and `n` is a large negative integer

Open
#113 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Julia
Stars
90
Forks
11
PR merge metrics
No merged PRs in 30d

Description

Consider calling `besselj(n, x)` where `x` is negative, while `n` is a large negative integer:
```julia
julia> Bessels.besselj(-172, -2.0)
NaN

julia> Bessels.besselj(-37, -2.0f0)
NaN32
```
When at least one argument is positive, there is no problem:
```julia
julia> Bessels.besselj(172, -2.0)
4.657823561745e-312

julia> Bessels.besselj(-37, 2.0f0)
-7.1f-44
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.