Easy Tutorial
❮ Python Conversion Binary Octal Hexadecimal Python Func Float ❯

Python math.erfc() Method

Python math Module

The math.erfc(x) method in Python returns the complementary error function at x.

The math.erfc(x) method accepts values between -inf and +inf and returns values between -1 and +1.

Python Version: 3.2

Syntax

The syntax for the math.erfc() method is as follows:

math.erfc(x)

Parameter:

Return Value

A floating-point value representing the complementary error function of a number.

Example

Here is an example of the complementary error function for different numbers:

Example

# Import math package
import math

# Print the complementary error function for different numbers
print(math.erfc(0.67))
print(math.erfc(1.34))
print(math.erfc(-6))

Output:

0.34337229769969496
0.05808628474163466
2.0

Python math Module

❮ Python Conversion Binary Octal Hexadecimal Python Func Float ❯