`zeta(0, x), zeta(s, -1)` gives wrong answer
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
Reproduce the shown Julia calls for zeta(0, -n) and zeta(s, -1), then compare the results with the stated Hurwitz zeta and Wolfram references. Done means the negative-argument values match those references, including the listed special values, without introducing the current NaN or Inf results.
Written by the indexing model from the issue text.
Description
We have: zeta(0, x) = 0.5 - x
Ref: https://en.wikipedia.org/wiki/Hurwitz_zeta_function#Negative_integers
But SpecialFunctions v2.5.1 gives:
julia> [ zeta(0, n) for n in 1:3 ] # look good
3-element Vector{Float64}:
-0.5
-1.5
-2.5
julia> [ zeta(0, -n) for n in 1:3 ]
3-element Vector{Float64}:
0.5
1.5
2.5
julia> [ 0.5+n for n in 1:3 ]
3-element Vector{Float64}:
1.5
2.5
3.5
And Wolfram gives:
In[2]:= Zeta[0, -1]
Out[2]= 3/2
In[3]:= Zeta[0, -2]
Out[3]= 5/2
In[4]:= Zeta[0, -3]
Out[4]= 7/2
Special values
Test with: zeta(s, -1) == 1 + zeta(s)
ref: https://reference.wolfram.com/language/ref/Zeta.html#479430652
julia> zeta(-9, -1)
-1.0075757575757576
julia> zeta(-7, -1)
-0.9958333333333333
julia> zeta(-6, -1)
NaN
julia> zeta(2, -1)
Inf
Wolfram:
In[10]:= Zeta[-9, -1]
Out[10]= 131/132
In[11]:= Zeta[-7, -1]
Out[11]= 241/240
In[12]:= Zeta[-6, -1]
Out[12]= 1
In[13]:= Zeta[2, -1]
Out[13]= 1+\[Pi]^2/6
- Dominant language
- Julia
- Stars
- 384
- Forks
- 115
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 5
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from JuliaMath/SpecialFunctions.jl
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
JuliaMath/SpecialFunctions.jl#570 ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 40/100
JuliaMath/SpecialFunctions.jl#569 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
JuliaMath/SpecialFunctions.jl#567 ·
Maintainers usually reply within 1 day
-
Difficulty 4/5 1-2 days Newbie friendliness 56/100
JuliaMath/SpecialFunctions.jl#563 ·
Maintainers usually reply within 1 day
-
Difficulty 3/5 1-2 days Newbie friendliness 72/100
JuliaMath/SpecialFunctions.jl#560 ·
Maintainers usually reply within 1 day
All issues in JuliaMath/SpecialFunctions.jl
Similar issues
-
documentation priority: high
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
epiforecasts/BVDOutbreakSize#1260 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
TuringLang/Turing.jl#2917 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
-
Validate UserDemand return_factorPossibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 2 days