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
This issue might be related to #61 , but I tried to compare the result of the Tricomi confluent hypergeometric function HypergeometricFunctions.U(a,b,z) across softwares when the final argument z is a negative number. Here are some results:
Note that HypergeometricFunctions.U(0.5, 0.5, -2.5) throws a DomainError with -2.5: Exponentiation yielding a complex result requires a complex argument. Probably one needs to make sure z^(1-b) is defined for negative real z.
Hi,
Thanks a lot for the wonderful package!
This issue might be related to #61 , but I tried to compare the result of the Tricomi confluent hypergeometric function
HypergeometricFunctions.U(a,b,z)
across softwares when the final argumentz
is a negative number. Here are some results:Experiment 1: Evaluate
U(0.5, 0.5, -2.5)
:HypergeometricU[0.5, 0.5, -2.5]
yields0.145492 - 0.810467i
.kummerU(0.5, 0.5, -2.5)
yields0.1455 - 0.8105i
.HypergeometricFunctions.U(0.5, 0.5, Complex(-2.5))
yields0.0 - 1.1612906236707266im
.Note that
HypergeometricFunctions.U(0.5, 0.5, -2.5)
throws aDomainError with -2.5: Exponentiation yielding a complex result requires a complex argument.
Probably one needs to make surez^(1-b)
is defined for negative real z.Experiment 2: Evaluate
U(-0.5 -0.5, -2.5)
:HypergeometricU[-0.5, -0.5, -2.5]
yields0.0727459 + 1.17591i
.kummerU(-0.5, -0.5, -2.5)
yields0.0727 + 1.1759i
.HypergeometricFunctions.U(-0.5, -0.5, Complex(-2.5))
yields0.0 + 0.0im
.The issue does not seem to appear (the results matches across platforms) if z is a positive real or z is a complex number with a negative real part:
Experiment 3: Evaluate
U(-0.5 -0.5, -2.5-1.5im)
:HypergeometricU[-0.5, -0.5, -2.5-1.5i]
yields0.595921 - 1.34976i
.0.5959 - 1.3498i
.0.5959210215481137 - 1.3497630048128746im
.Environment: Julia 1.8.5, package ver. 0.3.15. MATLAB R2022a. Mathematica 12.3.1.0 on a macOS 13.3.
The text was updated successfully, but these errors were encountered: