Jump to content

Documentation/Calc Functions/ERF

From The Document Foundation Wiki


Function name:

ERF

Category:

Add-in

Summary:

Calculates values of the error function, also known as the Gauss error function, between specified limits.

Syntax:

ERF(LowerLimit[; UpperLimit])

Returns:

Returns a real number in the range -1 < x < 1, which is the value of the error function between the specified limits.

Arguments:

LowerLimit is a real number, or a reference to a cell containing that number, which in the two argument version of the function is the lower limit of the integral that defines the error function. In the single argument version of the function, the integral is performed between 0 and LowerLimit.

UpperLimit is a real number, or a reference to a cell containing that number, which in the two argument version of the function is the upper limit of the integral that defines the error function.

  • If either LowerLimit or UpperLimit is non-numeric, then ERF reports a #VALUE! error.
  • ERF takes account of reversing the limits of the integral, for example if UpperLimit < LowerLimit.

Additional details:

The formula for the single argument version of ERF is:

Equation for ERF function (single-argument)
Equation for ERF function (single-argument)

The following figure shows a plot of this formula.

Plot for ERF function (single argument)
Plot for ERF function (single argument)

The two argument version of the function uses the relation:

ERF(a; b) = ERF(b) - ERF(a)

More information can be found at Wikipedia’s Error function page.

Examples:

Formula Description Returns
=ERF(0.5) Here the function calculates the error function with limits of 0 and 0.5, returning the value 0.52050 (to five decimal places). 0.52050
=ERF(0; 0.5) Here the function again calculates the error function with limits of 0 and 0.5, returning the value 0.52050 (to five decimal places). 0.52050
=ERF(D1; D2) where cells D1 and D2 contain the values 0.5 and 0 respectively. Here the function calculates the error function with limits of 0.5 and 0, returning the value -0.52050 (to five decimal places). −0.52050
=ERF(−1) Here the function calculates the error function with limits of 0 and -1, returning the value -0.84270 (to five decimal places). −0.84270

Related LibreOffice functions:

ERFC

ERF.PRECISE

ERFC.PRECISE

ODF standard:

Section 6.16.27, part 2

Related (or similar) Excel functions:

ERF