Skip to main content

erfc

Function erfc 

Source
pub fn erfc(x: f64) -> f64
Expand description

Complementary error function erfc(x) = 1 − erf(x).

Uses the everywhere-positive series erf(x) = 2/√π · e^{−x²} · Σ 2ⁿ x^{2n+1} / (1·3·…·(2n+1)) for |x| < 2 and the Laplace continued fraction (modified Lentz) for |x| ≥ 2, where the series would lose relative precision in the tail.