Ticket #199 (closed defect)

Opened 10 years ago

Last modified 10 years ago

Bug in gamma-inc implementation and documentation

Reported by: williams Owned by: williams
Priority: major Milestone:
Component: williams/science.plt Keywords:
Cc: noelwelsh@… Version: (3 5)
Racket Version: 4.2.1


Noel Welsh send the following:

The gamma-inc function in the science collection has an error:

In gamma-inc-impl.ss it reads:

(define (gamma-inc-F-CF a x)

(define nmax 5000)
(define small (exp double-epsilon 3))

That last function call should be expt, not exp.

The documentation for gamma-inc states

"Computes the normalized incomplete gamma function"

but the equation below that line corresponds to the *un*normalised
function. I compared the corrected function against Matlab and believe
it is correctly implementing the unnormalised function.

Change History

Changed 10 years ago by williams

  • status changed from new to accepted

Changed 10 years ago by williams

  • status changed from accepted to closed

Fixed and released to PLaneT in version 3.6.

Note: See TracTickets for help on using tickets.