We present efficient algorithms for multi-precision and multi-accuracy calculation of error functions and the Dawson integral, all with complex arguments. These algorithms achieve exceptional accuracies, ranging from 26 significant digits (SD) up to 30 SD depending on the function. In addition to the Faddeyeva or Faddeeva function, w(z) or the scaled complementary error function, erfcx(z) = w(iz), the list of functions considered include the error function, erf(z), complementary error function, erfc(z), imaginary error function, erfi(z), and the Dawson integral Daw(z).
These algorithms are integrated into a modern Fortran module confirming the claimed accuracies and superior efficiency compared to other competitive codes in the literature. Additionally, we highlight an observation regarding the built-in “Erfc_Scaled(x)” function included in a widely used Fortran compiler, which exhibits a significant decline in accuracy when employed in quadruple precision arithmetic.