WOFZ

The Faddeeva function is a complex-valued special function used in Voigt profiles, plasma dispersion, and complex error-function formulations.

w(z)=e^{-z^2}\,\mathrm{erfc}(-iz)

For a real scalar input, this wrapper returns a one-row array containing real and imaginary parts as [[real, imag]].

Excel Usage

=WOFZ(z)
  • z (float, required): Real argument for the Faddeeva function (dimensionless).

Returns (list[list]): One-row array containing real and imaginary parts as [[real, imag]].

Example 1: Faddeeva function at zero

Inputs:

z
0

Excel formula:

=WOFZ(0)

Expected output:

Result
1 0
Example 2: Faddeeva function at one half

Inputs:

z
0.5

Excel formula:

=WOFZ(0.5)

Expected output:

Result
0.778801 0.478925
Example 3: Faddeeva function at one

Inputs:

z
1

Excel formula:

=WOFZ(1)

Expected output:

Result
0.367879 0.607158
Example 4: Faddeeva function at two

Inputs:

z
2

Excel formula:

=WOFZ(2)

Expected output:

Result
0.0183156 0.340026

Python Code

from scipy.special import wofz as scipy_wofz

def wofz(z):
    """
    Compute the Faddeeva function and return real and imaginary parts.

    See: https://docs.scipy.org/doc/scipy/reference/generated/scipy.special.wofz.html

    This example function is provided as-is without any representation of accuracy.

    Args:
        z (float): Real argument for the Faddeeva function (dimensionless).

    Returns:
        list[list]: One-row array containing real and imaginary parts as [[real, imag]].
    """
    try:
        z = float(z)
        result = scipy_wofz(z)
        return [[float(result.real), float(result.imag)]]
    except Exception as e:
        return f"Error: {str(e)}"

Online Calculator

Real argument for the Faddeeva function (dimensionless).