Skip to content
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

2F1 sometimes errors due to Gamma function: #105

Open
dlfivefifty opened this issue Dec 5, 2017 · 4 comments
Open

2F1 sometimes errors due to Gamma function: #105

dlfivefifty opened this issue Dec 5, 2017 · 4 comments

Comments

@dlfivefifty
Copy link
Member

dlfivefifty commented Dec 5, 2017

n = 5;
a ,b = 0.1, 0.2
 _₂F₁(-n,n+a+b+1,a+1,z+eps()*im)
@dlfivefifty
Copy link
Member Author

[1] nan_dom_err at ./math.jl:300 [inlined]
 [2] gamma(::Float64) at ./special/gamma.jl:3
 [3] reconeβ₀(::Float64, ::Float64, ::Float64, ::Complex{Float64}, ::Int64, ::Float64) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/specialfunctions.jl:215
 [4] Bone(::Float64, ::Float64, ::Float64, ::Complex{Float64}, ::Int64, ::Float64) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/specialfunctions.jl:229
 [5] _₂F₁one(::Float64, ::Float64, ::Float64, ::Complex{Float64}) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/specialfunctions.jl:245
 [6] _₂F₁general(::Float64, ::Float64, ::Float64, ::Complex{Float64}) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/Gauss.jl:95
 [7] _₂F₁general(::Float64, ::Float64, ::Float64, ::Complex{Float64}) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/Gauss.jl:81
 [8] _₂F₁general(::Int64, ::Float64, ::Float64, ::Complex{Float64}) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/Gauss.jl:82
 [9] _₂F₁(::Int64, ::Float64, ::Float64, ::Complex{Float64}) at /Users/solver/.julia/v0.6/SingularIntegralEquations/src/HypergeometricFunctions/Gauss.jl:51

@dlfivefifty
Copy link
Member Author

Also, shouldn't we calculate 2F1_regularized to avoid issues with c being a negative integer?

@MikaelSlevinsky
Copy link
Member

MikaelSlevinsky commented Dec 6, 2017 via email

@dlfivefifty
Copy link
Member Author

According to F.W.J. Olver, one should always calculate the regularized version:

instead of F(a,b;c;z), the function on the left-hand side of Equation (9.02) on page 159 of my book is a much better choice. This is because it is an entire function of each of its parameters a, b, c and hence avoids computational problems that stem from the fact that as a function of c, F(a,b;c;z) has an infinite set of poles on the real axis. Similarly for other hgf”s.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants