/* Inverse of the error function {erf()} */ /* Last edited on 2023-12-15 04:09:49 by stolfi */ #ifndef erfinv_H #define erfinv_H #define _GNU_SOURCE #include #include #include double erfinv(double y); /* Functional inverse of the error function {erf}, namely such that {erf(erfinv(y)) = y} for {y} in {[-1_1]}, apart from roundoff errors which may be significant near the ends of that range. Also {erfinv(erf(x)) = x} for any {x}, apart from roundoff errors which may be significant for {x} far from 0. */ #endif