Power series for the half width
of the Voigt function, rederived
Abstract.
The Voigt function is the convolution of a Gaussian and a Lorentzian. We rederive power series for its half width at half maximum for the limiting cases of near-Gaussian and near-Lorentzian line shapes. We thereby provide independent verification and slight corrections of the expansion coefficients reported by Wang et al (2022). Results are used in our implementation of function voigt_hwhm in the open-source library libcerf.
Key words and phrases:
Voigt function, Faddeeva function, Maclaurin series, asymptotic series, high-precision computation2005 Mathematics Subject Classification:
33C15, 41A58, 33-04j.wuttke@fz-juelich.de, ORCID 0000-0002-4028-1447
1. Introduction
The Voigt [8] function is the convolution of a Gaussian and a Lorentzian [5, 7.19.1]. It is frequently used to describe peak shapes in spectroscopy and diffraction. In such applications, it is customary to characterize peaks by their full or half width at half maximum (fwhm, hwhm).
Much work has been devoted to numerical approximations of the Voigt function and its half width. For most applications, considering experimental uncertainties, quite simple approximations would do. Nonetheless, for internal consistency and reproducibility of data analyses, to facilitate numerical differentiation (e.g., in fitting routines), and out of pure mathematical interest, it is worthwhile to push approximations to ever better accuracy.
The Voigt function can be expressed through the Faddeeva function, which is closely related to the complex error function. Therefore, our open-source complex error function library libcerf [4] also provides functions voigt and voigt_hwhm. Earlier versions of libcerf computed voigt_hwhm very directly by bisection on function values of voigt. Starting with release 3.3, a completely new implementation of voigt_hwhm uses series expansions for the near-Gaussian and near-Lorentzian limiting cases, and piecewise Chebyshev interpolation [10] in between. Near machine accuracy is achieved in each region. This paper documents the two series expansions.
The same series have recently been studied by Wang et al [9]. Here, we rederive them in different ways and thereby provide independent verification and slight corrections for the coefficients tabulated in [9]. For the near-Gaussian case, our derivation (Section 3) is more compact, as we use complex notation and represent the Voigt function through the Faddeeva function instead of decomposing it as in [9, Eq 9]. For the near-Lorentzian case, Wang et al chose a pragmatic method: numerical differentiation, followed by rounding to integer numerators [9, Appendix B]. Here (Section 4), we derive a fully algebraic recursion.
2. Foundations
2.1. Voigt function
The Voigt function
| (1) |
is the convolution of a normalized Gaussian with standard deviation
| (2) |
and a normalized Lorentzian with half width
| (3) |
As and are even functions of and , so is . Therefore in the following we will only consider . Otherwise said, we will simply write and instead of their absolute values.
2.2. Half width
Function is the half width at half maximum of the Voigt function. It is implicitly defined by
| (4) |
Or, introduce the reduced Voigt function
| (5) |
and its inverse function with respect to the first argument, such that
| (6) |
Then we have simply
| (7) |
2.3. Scaling
For real , the Voigt function scales as
| (8) |
The reduced Voigt function scales accordingly as
| (9) |
and its inverse as
| (10) |
This implies for the half width
| (11) |
The homogeneity of degree 1 implies that we only need to study a function of one real variable or .
2.4. Relation to the Faddeeva function
Given the error function
| (12) |
the complementary error function
| (13) | ||||
| (14) |
and the underflow-compensated complementary error function
| (15) |
the Faddeeva function is [5, 7.2.3]
| (16) | ||||
| (17) | ||||
| (18) | ||||
| (19) | ||||
| (20) |
Another integral representation, valid for , is [5, 7.7.2]
| (21) |
Let us define and so that
| (22) |
The real part of Eq. 21 is
| (23) |
which is essentially Voigt’s convolution integral Eq. 1. Divide , , and by to find
| (24) |
Accordingly, the Voigt half width is implicitly defined by a functional equation that involves the real part of Faddeeva’s function,
| (25) |
3. Near-Gaussian case
3.1. Case
3.2. Rescaled function
We now consider the case of a relatively small Lorentzian width, . Thanks to the scaling property Eq. 11, the half width of the Voigt function can be computed as
| (28) |
For later convenience, we introduce the reduced variable
| (29) |
so that
| (30) |
We define the function
| (31) |
and the constant
| (32) |
so that can be obtained via Eq. 30 and
| (33) |
Below, we will determine a series expansion for , so that we can ultimately compute the Voigt width using
| (34) |
3.3. Power series in and
In Eq. 25, choose and . then use Eq. 30 and Eq. 33 to obtain an implicit equation for ,
| (35) |
On the right-hand side, use the Maclaurin expansion of [5, 7.6.3] to obtain
| (36) |
On the left-hand side of Eq. 35, use the Taylor expansion
| (37) |
with coefficients
| (38) |
given by the recursion [5, 7.10.3] [7, Eq 10]
| (39) |
with starting values and .
3.4. Recursive solution
To solve Eq. 40 numerically, function shall be expressed as a power series in . Since by construction Eq. 31, the power series starts with the linear term,
| (41) |
Per Eq. 31, the are real for ; only for there is an imaginary part, per the definition Eq. 31, so that
| (42) |
With notation from [3], write for the coefficient of in the power series representing . For the series Eq. 41, . Define
| (43) |
and apply the operator to both sides of Eq. 40:
| (44) |
for all .
Equations Eqs. 44, 43 and 41 fully determine the in terms of the , which are given by the recursion Eq. 39. We resolve said equations in two steps. First, we solve Eq. 44 for . For , we recall Eq. 42 to obtain
| (45) |
For ,
| (46) |
Second, we use Eq. 41 to obtain the for :
| (47) |
Finally, we note that the coefficients of Eq. 41 are . This completes our derivation of a power series for the half width .
3.5. Implementation
A Python script near_gauss.py used to generate coefficients is preserved in subdirectory dev/voigt of the libcerf source repository. The script uses the arbitrary-precision math library mpmath [6] with a fixed internal precision, checked against a computation with some more digits. It turns out that an internal precision of 40 decimal digits is needed to compute for with 32 reliable decimal digits. The program executes within a fraction of a second.
The recursive forward computation of according to Eq. 39 would be divergent if had a positive imaginary part [7]. In our case, is real so that we are at the margin of numerical instability. Indeed, our computations show that up to only the last few decimal digits get incorrect. Nonetheless, our script validates each against a non-recursive computation, derived in the Appendix.
3.6. Results
Resulting coefficients up to are reported in Table 1 with 32 digits precision. Up to , they fully agree with [9, Table A1]. Then, suddenly, the agreement drops to 12 digits for , and further decreases to 7 digits for . Given that our algorithm is simpler than the one of [9] and that we cross-checked our results with different internal accuracies we are confident that all digits reported in Table 1 are correct.
4. Near-Lorentzian case
4.1. Case
For a pure Lorentzian, , the half width is just .
4.2. Rescaled function
We now consider the case of a relatively small Gaussian width, . Thanks to the scaling property Eq. 11, the half width of the Voigt function can be computed as
| (50) |
For later convenience, we introduce a reduced variable
| (51) |
and a real function
| (52) |
that is to be determined so that we ultimately obtain the Voigt half width as
| (53) |
In this notation, the implicit definition Eq. 25 of can be written as
| (54) |
which needs to be resolved for .
For large , the Faddeeva function can be computed from its asymptotic expansion [1, p. 14]
| (55) |
with the abbreviation
| (56) |
The remainder is no larger than the first term omitted from the sum. Drop the explicit notation of truncation, and apply Eq. 55 to Eq. 54,
| (57) |
Factor out , and drop a common factor :
| (58) |
Binomial expansion:
| (59) |
As , , are all real, the only complex quantity here is the imaginary unit .
4.3. Solution
We seek a solution in form of a power series
| (64) |
As in Section 3.4, write for the coefficient of in a power series representing . Apply the operator to Eq. 62:
| (65) |
Define
| (66) |
Restrict the sums to non-zero terms, using the fact that per Eq. 64 has no term:
| (67) |
The only linear occurrence of is in the term, with prefactor . Isolating that contribution gives the recurrence
| (68) |
The recurrence starts from
| (69) |
Coefficients with can be computed by another recursion, as in Eq. 47 of Section 3.4,
| (70) |
While the coefficients in Eq. 68 are integers, the are rational numbers with denominators that are powers of 2. Therefore the must also be rational numbers, and their denominators powers of 2.
4.4. Implementation
A Python script near_lorentz.py used to generate coefficients is preserved in subdirectory dev/voigt of the libcerf source repository. The script employs the Python library Fraction to compute exact rational numbers using long-integer arithmetics.
4.5. Results
The expansion coefficients are reported in Table 2. The ratio of consecutive coefficients is shown as versus in Figure 1, which indicates that the grow faster than a power law. In consequence, Eq. 64 is an asymptotic series, as was noted by Wang et al [9], and was to be expected from the asymptotic expansion Eq. 55 used for .

Wang et al expanded squared half widths in a series [9, Eq A30] that reads in our notation
| (71) |
They computed rational numbers by approximating floating-point numbers obtained from numerical differentiation [9, Eq A31]. For odd , they found , consistent with our Eqs. 53 and 64. To validate their results for even , we recompute as
| (72) |
We define so that we are left with a self-convolution
| (73) |
With rational arithmetics based on our as shown in Table 2, we confirm the of [9, Table A2] except for their , which is too large by ; the correct result is .
Appendix. Closed expression for
As the recursion Eq. 39 is marginally unstable, it may be preferable to compute from a closed expression, or at least use the direct computation as a cross-check. With Eqs. 38 and 17,
| (74) |
With [5, 7.18.4], [2, 2.23], and with the notation [5, 7.18.2] for the iterated integral of erfc,
| (75) |
With [5, 7.18.11],
| (76) |
The parabolic cylinder function [5, Chapter 12] is provided by mpmath as the function pcfu. Internally, mpmath computes it by means of hypergeometric functions.
References
- [1] V.N. Faddeyeva, N.M. Terent’ev, Tables of Values of the Function for Complex Argument, Pergamon, Oxford (1961).
-
[2]
W. Gautschi,
Efficient computation of the complex error function,
SIAM J. Numer. Anal. 7 (1970), pp. 187–198.
https://doi.org/10.1137/0707012
- [3] R.L. Graham, D.E. Knuth, O. Patashnik, Concrete Mathematics, 1989, Addison–Wesley, Reading.
-
[4]
S.G. Johnson, J. Wuttke (2013–2025),
libcerf, a numeric library providing complex error functions,
https://jugit.fz-juelich.de/mlz/libcerf
-
[5]
NIST Digital Library of Mathematical Functions,
http://dlmf.nist.gov
-
[6]
The mpmath development team (2023),
mpmath: a Python library for arbitrary-precision floating-point arithmetic (version 1.3.0),
https://mpmath.org
-
[7]
I. Thompson,
Algorithm 1046: An Improved Recurrence Method for the Scaled Complex Error Function,
ACM Trans. Math. Software, 50 (2024), no. 20 (18 pages).
https://doi.org/10.1145/3688799
-
[8]
W. Voigt,
Über das Gesetz der Intensitätsverteilung innerhalb der Linien eines Gasspektrums,
Sitzungsber. Bayer. Akad. Wiss. Math.-Naturwiss. Kl., 25 (1912), pp. 603–620. https://publikationen.badw.de/de/003395768
-
[9]
Y. Wang, B. Zhou, R. Zhao, B. Wang, Q. Liu, M. Dai,
Super-Accuracy Calculation for the Half Width of a Voigt Profile,
Mathematics, 10 (2022), no. 210 (14 pages).
https://doi.org/10.3390/math10020210
- [10] J. Wuttke, A. Kleinsorge, Algorithm 1xxx: Code generation for piecewise Chebyshev approximation, submitted to ACM TOMS.








