From octave-sources-request at bevo dot che dot wisc dot edu Thu Apr 9 13:03:09 1998 Subject: Re: sanity test for gammai From: Jim Van Zandt To: Ted dot Harding at nessie dot mcc dot ac dot uk cc: jrv at vanzandt dot mv dot com, octave-sources@bevo.che.wisc.edu Date: Thu, 09 Apr 1998 14:01:42 -0400 In message , Ted Harding writ es: > ...in 2.0.11 the computed value of gammai(x,a) is simply the integral > of (t^(a-1))*exp(-t), not (as defined in A&S) of > (t^(a-1))*exp(-t)/gamma(a) and also contrary to what "help gammai" > says... > > One can live with either interpretation of gammai, but it should be made > definite which it is supposed to be. > ... > Octave-2.0.11 gives > > octave:130> gammai(6,100) > ans = 120.00 [ = 5! ]. > > > In octave-1.1.1 I get > > octave:6> gammai(6,100) > ans = 1 > > so there has been a change along the line Actually I prefer the new definition of gammai(a,x), which corresponds to \gamma(a,x) in A&S (whereas the old definition corresponded to P(a,x) in A&S). I agree that we could live with either. However, there's another issue. I believe gammainc now differs from the function with that name in MatLab. Can anyone confirm this? If so, I think it's a bug. - Jim Van Zandt