[Scipy-tickets] [SciPy] #737: gammaln valid range is incorrect

SciPy scipy-tickets@scipy....
Sun Sep 7 03:18:33 CDT 2008

#737: gammaln valid range is incorrect
 Reporter:  cdavid  |       Owner:  somebody
     Type:  defect  |      Status:  new     
 Priority:  high    |   Milestone:  0.7.0   
Component:  Other   |     Version:          
 Severity:  normal  |    Keywords:          
 Gamma in negative for negative x whose floor value is odd. As such,
 gammaln does not make sense for those values (while staying in the real
 domain, at least). scipy.special.gammaln returns bogus values:

 import numpy as np
 from scipy.special import gamma, gammaln
 print np.log(gamma(-0.5))
 print gammaln(-0.5)

 Returns nan in the first case (expected) and 1.26551212348 in the second
 (totally meaningless value).

Ticket URL: <http://scipy.org/scipy/scipy/ticket/737>
SciPy <http://www.scipy.org/>
SciPy is open-source software for mathematics, science, and engineering.

More information about the Scipy-tickets mailing list