Iterated integral complementary error function#

Check implementation of the iterated integral complementary error function.

import matplotlib.pyplot as plt
import numpy as np

from bruggeman.general import ierfc

Implementation:

Iterated integral complementary error function

Compare to figure 3 in Olsthoorn, (2006).

z = np.linspace(0, 3, 51)
ierfc_min1 = ierfc(z, -1)
ierfc0 = ierfc(z, 0)
plt.figure(figsize=(10, 3))
plt.plot(z, ierfc_min1, ls="dashed", label="ierfc(z, -1)", lw=1.0, color="k")
plt.plot(z, ierfc0, ls="solid", label="ierfc(z, 0)", lw=1.0, color="k")
for n in range(1, 8):
    plt.plot(
        z, ierfc(z, n) / ierfc(0, n), label=f"ierfc(z, {n}) / ierfc(0, {n})", lw=1.0
    )
plt.legend()
plt.grid()
../_images/86866ed3aaba3b1a98846ebf986ec338df3b7a42e99953f6573935488d46932e.png