[SciPy-user] special.erf underflow

Arnd Baecker baecker at physik.tu-dresden.de
Thu May 8 09:26:01 EDT 2003


Hi,

is there a way to prevent the error message in the
following example

In [32]: import scipy
In [33]: scipy.special.erf(300)

erfc underflow error
Out[33]: 1.0


((On the one hand it is nice to be informed about
that - on the other hand the result -1.0 is just the one I would
expect. Eg. for exp one just gets
In [34]: scipy.special.exp(-10000)
Out[34]: 0.0
Acutally for exp this is better than Numeric's exp which
gives a math range error in this case:
In [35]: Numeric.exp(-1000)
OverflowError: math range error
))

Arnd



More information about the SciPy-User mailing list