# \(\text{erfInv}\)¶

You can use the \(\text{erfInv}\) function to calculate the inverse error function.

You can use the `\erfinv`

backslash command to insert this function.

The following variants of this function are available:

\(\text{real } \text{erfInv} \left ( \text{<value>} \right )\)

Where \(\text{<value>}\) represents any basic type. Note that this
function is currently only defined for real values. A run-time error will will
be generated or `NaN`

will be returned for values with a non-zero imaginary
component.

Note that run-time type conversion allows the result of this function to be assigned to any basic type provided the returned value is compatible with that type. The compiler will also select appropriate variants of the function if the return type can be determined at compile time based on the supplied parameters.

The \(\text{erfInv}\) uses Newton-Raphson method (first derivative) to solve for the inverse of the \(\text{erf}\) function. The implementation includes code to allow convergence with input values with magnitude very close to 1.0.