Math Functions

math.erf()

Compute the Gaussian error function, used in normal-distribution calculations.

Formal Syntax & Structure

python syntaxpython
math.erf(x, /)

Parameters & Attributes

NameTypeDescription
xreal numberInput real value.

Return Value

float

Floating-point result; finite precision and domain restrictions apply.

Working Example

Example Snippetpython
import mathprint(math.erf(0))
Python Reference