logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

voigt - Voigt's function, convolution of Gaussian and Lorentzian

Authors

       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.

Copying

       Copyright (c) 2013 Forschungszentrum Juelich GmbH

       Software: MIT License.

       This documentation: Creative Commons Attribution Share Alike.

perl v5.38.2                                       2024-04-22                                           voigt(3)

Description

       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.

Name

       voigt - Voigt's function, convolution of Gaussian and Lorentzian

References

       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|.

See Also

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

Synopsis

#include<cerf.h>

       doublevoigt(doublex,doublesigma,doublegamma);

See Also