Where are the math functions?
Tim Rowe
digitig at cix.co.uk
Wed Jun 14 17:32:00 EDT 2000
In article <owen-97F32C.10015712062000 at news.u.washington.edu>,
owen at astro.washington.edu (Russell E. Owen) wrote:
> In article <slrn8k8dfv.tu.hzhu at mars.localdomain>,
> hzhu at users.sourceforge.net wrote:
>
> >I'm quite puzzled by not being able to find most of the common special
> >functions, such as (incomplete) gamma, beta and bessel and erf.
> >
> >This arrises from effort to provide statistical functions for the MatPy
> >package. Many stat functions require incomplete gamma/beta and some
> >variants.
> >...
>
> The random module (which is available on all platforms) offers beta and
> gamma functions. I can't comment on incomplete gamma, bessel and erf. I
> found the information about the random module in "Python Essential
> Reference" by David Beazley; the index lists beta and gamma, but not
> the others.
No it doesn't. It includes the beta and gamma /distributions/. These are
related to, but not the same as, the beta and gamma /functions/.
When I wanted the gamma function I just ported code from Numerical Recipes
in C, which only took a couple of minutes (longer to test, but I'd have
spent that time if I'd just typed in the C). Probably still be a copyright
violation to post it, though :-(
More information about the Python-list
mailing list