math.erfc OverflowError

geremy condra debatem1 at gmail.com
Sat Jun 12 19:56:28 EDT 2010


On Sat, Jun 12, 2010 at 4:40 PM, Robert Kern <robert.kern at gmail.com> wrote:
> On 2010-06-12 17:49 , geremy condra wrote:
>>
>> In Python3.2, calling math.erfc with a value in [-27.2, -30) raises
>> an OverflowError: math range error. This is inconsistent with the
>> erfc function from scipy (scipy.special.erfc) as well as with the C99
>> function by the same name, both of which return 2. I suspect that
>> this is the result of the cutoff for the use of the continuing fraction
>> approximation of erfc beginning when abs(x)>  30, but I'm not sure.
>> Is this desired behavior or should I file a bug report?
>
> Bug, I think.
>
> --
> Robert Kern

Bug filed, http://bugs.python.org/issue8986.

Geremy Condra



More information about the Python-list mailing list