erfInverse

Evaluates the real inverse error function erf1(x).

Synopsis

erfInverse (x)

Required Arguments

float x (Input)
Point at which the inverse error function is to be evaluated. It must be between −1 and 1.

Return Value

The value of the inverse error function erf1(x).

Description

The inverse error function erf1(x) is such that x=erf(y), where

erf(y)=2πy0et2dt

The inverse error function is defined only for 1<x<1.

../../_images/Fig9-3.png

Figure 9.10 — Plot of erf1(x)

Example

Evaluate the inverse error function at x=1/2.

from __future__ import print_function
from numpy import *
from pyimsl.math.erfInverse import erfInverse

x = 0.5
ans = erfInverse(x)
print("Inverse erf(%f) = %f" % (x, ans))

Output

Inverse erf(0.500000) = 0.476936

Warning Errors

IMSL_LARGE_ABS_ARG_WARN The answer is less accurate than half precision because |x| large.

Fatal Errors

IMSL_REAL_OUT_OF_RANGE The inverse error function is defined only for −1 < x < 1.