mirror of
https://github.com/python/cpython.git
synced 2025-10-17 12:18:23 +00:00
Merge for issue #26114
This commit is contained in:
commit
2f1a0b6ad5
1 changed files with 2 additions and 3 deletions
|
@ -400,9 +400,8 @@ m_lgamma(double x)
|
||||||
Implementations of the error function erf(x) and the complementary error
|
Implementations of the error function erf(x) and the complementary error
|
||||||
function erfc(x).
|
function erfc(x).
|
||||||
|
|
||||||
Method: following 'Numerical Recipes' by Flannery, Press et. al. (2nd ed.,
|
Method: we use a series approximation for erf for small x, and a continued
|
||||||
Cambridge University Press), we use a series approximation for erf for
|
fraction approximation for erfc(x) for larger x;
|
||||||
small x, and a continued fraction approximation for erfc(x) for larger x;
|
|
||||||
combined with the relations erf(-x) = -erf(x) and erfc(x) = 1.0 - erf(x),
|
combined with the relations erf(-x) = -erf(x) and erfc(x) = 1.0 - erf(x),
|
||||||
this gives us erf(x) and erfc(x) for all x.
|
this gives us erf(x) and erfc(x) for all x.
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue