voigt - Voigt's function, convolution of Gaussian and Lorentzian
#include <cerf.h>
double voigt ( double x, double sigma, double gamma );
The function voigt returns Voigt's convolution
voigt(x,sigma,gamma) = integral G(t,sigma) L(x-t,gamma) dt
of a Gaussian
G(x,sigma) = 1/sqrt(2*pi)/|sigma| * exp(-x^2/2/sigma^2)
and a Lorentzian
L(x,gamma) = |gamma| / pi / ( x^2 + gamma^2 ),
with the integral extending from -infinity to +infinity.
If sigma=0, L(x,gamma) is returned. Conversely, if gamma=0, G(x,sigma) is returned.
If sigma=gamma=0, the return value is Inf for x=0, and 0 for all other x. It is advisable to test input arguments to exclude this irregular case.
Formula (7.4.13) in Abramowitz & Stegun (1964) relates Voigt's convolution integral to Faddeeva's function w_of_z, upon which this implementation is based:
voigt(x,sigma,gamma) = Re[w(z)] / sqrt(2*pi) / |sigma|
with
z = (x+i*|gamma|) / sqrt(2) / |sigma|.
voigt_hwhm(3)
Related complex error functions: w_of_z(3), dawson(3), cerf(3), erfcx(3), erfi(3).
Homepage: http://apps.jcns.fz-juelich.de/libcerf
Joachim Wuttke <j.wuttke@fz-juelich.de>, Forschungszentrum Juelich, based on the w_of_z implementation by Steven G. Johnson, http://math.mit.edu/~stevenj, Massachusetts Institute of Technology.
Please report bugs to the authors.
Copyright (c) 2013 Forschungszentrum Juelich GmbH
Software: MIT License.
This documentation: Creative Commons Attribution Share Alike.