Preprint
Article

This version is not peer-reviewed.

Efficient Application of the Voigt Functions in the Fourier Transform

Submitted:

04 April 2025

Posted:

07 April 2025

You are already at the latest version

Abstract
In this work, we develop a method of rational approximation of the Fourier transform (FT) based on the real and imaginary parts of the complex error function \[ w(z) = e^{-z^2}(1 - {\rm{erf}}(-iz)) = K(x,y) + iL(x,y), \quad z = x + iy, \] where $K(x,y)$ and $L(x,y)$ are known as the Voigt and imaginary Voigt functions, respectively. In contrast to our previous rational approximation of the FT, the expansion coefficients in this method are not dependent on values of a sampled function. As a set of the Voigt/complex error function values remains the same, this approach provides rapid computation. Mathematica codes with some examples are presented.
Keywords: 
;  ;  ;  

1. Introduction

The forward and inverse Fourier transforms (FTs) can be defined in a symmetric form as [1,2]
F f ( t ) ( ν ) = f ( t ) e 2 π i ν t d t = f ^ ( ν )
and
F 1 f ^ ( ν ) ( t ) = f ^ ( ν ) e 2 π i ν t d ν = f ( t ) ,
respectively. In this work we will consider only the forward FT (1) since due to symmetric form the approximations for the inverse FT (2) can be readily obtained from the forward FT by change of the variables.
There are relations between a function f ( t ) and its even f e v e n ( t ) and odd f o d d ( t ) components. In particular, the even and odd functions can be readily generated by using the following relations
f e v e n ( t ) = f ( t ) + f ( t ) 2
and
f o d d ( t ) = f ( t ) f ( t ) 2
such that
f ( t ) = f e v e n ( t ) + f o d d ( t ) .
Therefore, due to linearity of the FT we can also state that
f ^ ( ν ) = f ^ e v e n ( ν ) + f ^ o d d ( ν ) .
Using Euler’s identity
e i x = cos ( x ) + i sin ( x ) ,
we can express equation (1) as
F f ( t ) ( ν ) = f ( t ) cos ( 2 π ν t ) i sin ( 2 π ν t ) d t
Since an even function satisfies the condition
f e v e n ( t ) = f e v e n ( t ) ,
it follows that
f e v e n ( t ) cos ( 2 π ν t ) d t = 2 0 f e v e n ( t ) cos ( 2 π ν t ) d t
and
f e v e n ( t ) sin ( 2 π ν t ) d t = 0 .
Since an odd function satisfies the condition
f o d d ( t ) = f o d d ( t ) ,
we have
f o d d ( t ) cos ( 2 π ν t ) d t = 0
and
f o d d ( t ) sin ( 2 π ν t ) d t = 2 0 f o d d ( t ) sin ( 2 π ν t ) d t .
Consequently, from these relations and equations (5), (6) we get the following identities
F f e v e n ( t ) ( ν ) = 2 0 f e v e n ( t ) cos ( 2 π ν t ) d t = f ^ e v e n ( ν )
and
F f o d d ( t ) ( ν ) = 2 i 0 f o d d ( t ) sin ( 2 π ν t ) d t = f ^ o d d ( ν ) .
Equations (9) and (10) are of the primary importance since they will be used in derivation of the new approximation of the FT.
In our recent publication we developed a new methodology providing a rational approximation of the FT [3]. Specifically, the FT of a function f ( t ) can be approximated as a rational function consisting of low-order polynomials, 3 × 4 , in form
f ^ ( ν ) m = 1 M α m + β m ν 2 ν m + λ m ν 2 + ν 4 i γ m ν + θ m ν 3 κ m + λ m ν 2 + ν 4 = m = 1 M α m i γ m ν + β m ν 2 i θ m ν 3 κ m + λ m ν 2 + ν 4 ,
where expansion coefficients are given by
α m = 1 8 M π 4 n = N N f e v e n ( n h ) e n h σ μ m 2 + σ 2 σ cos ( n h μ m ) + μ m sin ( n h μ m ) , β m = 1 2 M π 2 n = N N f e v e n ( n h ) e n h σ σ cos ( n h μ m ) μ m sin ( n h μ m ) ,
γ m = 1 4 M π 3 n = N N f o d d ( n h ) e n h σ σ 2 μ m 2 cos ( n h μ m ) + 2 σ μ m sin ( n h μ m ) , θ m = 1 M π n = N N f o d d ( n h ) e n h σ cos ( n h μ m ) , κ m = 1 16 π 4 μ m 2 + σ 2 2 , λ m = 1 2 π 2 σ 2 μ m 2 μ m = π ( m 1 / 2 ) M h .
Some examples of rational approximation (11) of the FT are shown in our work [3] and can be visualized by running a provided Matlab code 1.
There are many methods for rational approximations such as Padé approximation [4,5], minimax approximation [6,7], Remez algorithm [8,9] and so on. However, to the best of our knowledge, a method of rational approximation that we developed in [3] is new and has been reported in scientific literature.
It should be noted that in our previous publication [10], we de facto applied a rational approximation of the FT. Therefore, a new method of rational approximation, described in our paper [3], is just a generalization of a sampling and integration technique that we proposed earlier in [10] to derive rapid and high-accuracy rational approximations of the complex error function.
The small order polynomials 3 × 4 in quotients of rational approximation (11) may be advantageous for numerical analysis with any kind of computations including matrix manipulations, integrations and differentiations. However, the rational approximation (11) requires re-computation of the four expansion coefficients α m , β m , γ m , θ m every time when the sampled function f ( t ) changes. In this work, we propose a new method of rational approximation of the FT based on a sum of the real and imaginary parts of the complex error function [11,12,13]. Such a representation of rational approximation of the FT does not require re-computation when shape of the sampled function f ( t ) changes.

2. Preliminaries

The complex error function, also commonly known as the Faddeeva function, can be defined as [13,14]
w ( z ) = e z 2 1 + 2 i π 0 z e t 2 d t ,
where z = x + i y . Comparing equation (12) with definition of the error function [11]
erf ( z ) = 2 π 0 z e t 2 d t
one can see that the complex error function can be expressed as [11,15]
w ( z ) = e z 2 1 erf ( i z ) .
Therefore, the complex error function w ( z ) can be considered as a reformulation of the error function erf ( z ) .
Complex error function satisfies the following relation
w ( z ) = 2 e z 2 w ( z ) .
It can be shown that the complex error function is a solution of the following differential equation
w ( z ) + 2 z w ( z ) = 2 i π ,
with initial condition
w ( 0 ) = 1 .
The complex error function w ( z ) is closely related to the complex probability function [12,13]
W ( z ) = i π e t 2 z t d t .
There is a direct relationship between these two functions. In particular, both functions are equal to each other on the upper half of the complex plane [12,13]
w ( z ) = W ( z ) , Im [ z ] > 0 .
Separating the real and imaginary parts of the complex probability function (15) as
W ( z ) = K ( x , y ) + i L ( x , y ) ,
results in
K ( x , y ) = y π e t 2 y 2 + ( x t ) 2 d t
and
L ( x , y ) = 1 π e t 2 ( x t ) y 2 + ( x t ) 2 d t ,
respectively.
The real part K ( x , y ) of the complex probability function is known as the Voigt function that is widely used in Atmospheric Physics to describe absorption and emission of atmospheric molecules [16,17,18].
The imaginary part L ( x , y ) is also used in various fields of Physics and Engineering [19,20]. It does not have a specific name. However, following Zaghloul and Ali [15], for the convenience we will also refer to the function L ( x , y ) as the imaginary Voigt function.
It is not difficult to show that substituting the following identity [12]
y y 2 + ( x t ) 2 = 0 e y q cos ( x t ) q d q , y > 0 ,
into equation (16), we obtain [12,21]
K ( x , y ) = 1 π e t 2 y y 2 + ( x t ) 2 d t = 1 π 0 e t 2 e y q cos ( x t ) q d t d q = 1 π 0 e y q e t 2 cos ( x t ) q d t d q
and since
e t 2 cos ( x t ) q d t = π e q 2 / 4 cos ( q x ) ,
we can write
K ( x , y ) = 1 π 0 e t 2 / 4 y t cos ( x t ) d t , y > 0 .
Similarly, substituting the identity
x t y 2 + ( x t ) 2 = 0 e y q sin ( q ( x t ) ) d q , y > 0 ,
into equation (17) we get [21]
L ( x , y ) = 1 π e t 2 x t y 2 + ( x t ) 2 d t = 1 π 0 e t 2 e y q sin ( x t ) q d t d q = 1 π 0 e y q e t 2 sin ( x t ) q d t d q
and since
e t 2 sin ( x t ) q d t = π e q 2 / 4 sin ( q x ) ,
we have
L ( x , y ) = 1 π 0 e t 2 / 4 y t sin ( x t ) d t , y > 0 .
Sum of the equations above in terms of the real and imaginary parts yields [21]
K ( x , y ) + i L ( x , y ) = 1 π 0 e t 2 / 4 y t cos ( x t ) + i sin ( x t ) d t = 1 π 0 e t 2 / 4 y t e i x t d t = 1 π 0 e t 2 / 4 e ( y i x ) t d t = e ( y i x ) 2 1 erf ( y i x ) .
We can see now that this equation is consistent with equation (13) of the complex error function w ( z ) .

3. Results and Discussion

3.1. Methodology

Consider the rectangular function (solitary rectangular function) that can be defined as
f r ( t ) = 1 , 1 / 2 < t < 1 / 2 , 1 / 2 , t = 1 , 0 , otherwise .
This function can be expressed by the following limit
f r ( t ) = lim k 1 2 t 2 k + 1 .
Consequently, we can approximate the rectangular function by taking sufficiently large value of the parameter k.
Figure 1 shows the rectangular function and its approximation at k = 35 by dashed red and light blue colors, respectively. As we can see, at k = 35 equation (21) approximates the rectangular function reasonably well. Therefore, we can use the following approximation
f r ( t ) 1 ( 2 t ) 70 + 1
and apply it to perform numerically the FT.
Figure 1. Rectangular and sawtooth functions and their approximations. Rectangular and sawtooth functions are shown by dashed red and solid black lines. Even 1 / 2 t 70 + 1 and odd t / 2 t 70 + 1 functions are shown by blue and green curves.
Figure 1. Rectangular and sawtooth functions and their approximations. Rectangular and sawtooth functions are shown by dashed red and solid black lines. Even 1 / 2 t 70 + 1 and odd t / 2 t 70 + 1 functions are shown by blue and green curves.
Preprints 154868 g001
Previously, we have used the following sampling function
s ( t ) = h c π e t c 2 ,
where h and c are small fitting parameters, for high-accuracy approximation of the complex error function [22]. Thus, applying this sampling function over the points n h to approximation (22), the rectangular function can be approximated as
f r ( t ) n = N N s ( t n h ) f r ( n h ) = h c π n = N N e ( t n h c ) 2 f r ( n h ) = h c π n = N N e 2 n h c 2 t e t c 2 e n h c 2 f r ( n h )
Figure 2 shows the approximations of the rectangular function at different fitting parameters h and c. Specifically, the green curve corresponds to h = 0.065 , c = 0.035 and N = 25 , the red curve corresponds to h = 0.05 , c = 0.03 and N = 25 while the light blue curve corresponds to h = 0.02 , c = 0.025 and N = 25 . The rectangular function is also shown by black dashed curve.
Since the rectangular function f r ( t ) is even, we can use equation (9) for the FT. Thus, the substitution of approximation (23) into equation (9) leads to
f ^ r ( ν ) 2 h c π n = N N e t c 2 + 2 n h c 2 t e n h c 2 f r ( n h ) cos ( 2 π ν t ) d t = 2 h π n = N N e t 2 + 2 n h c t e n h c 2 f r ( n h ) cos ( 2 π ν c t ) d t = h π n = N N e t 2 4 + n h c t e n h c 2 f r ( n h ) cos ( π ν c t ) d t .
Comparing now approximation above with equation (19), one can see that the FT of the rectangular function (21) can be expressed in terms of the Voigt function
f ^ r ( ν ) = h m = N N e n h c 2 f r ( n h ) K π ν c , n h c .
As a simplest example for an odd function, we can consider the sawtooth function (solitary sawtooth function)
f s ( t ) = t f r ( t ) = t , 1 / 2 < t < 1 / 2 , 1 / 4 , t = 1 , 0 , otherwise .
Since this function can be express though the following limit
f s ( t ) = t lim k 1 ( 2 t ) 2 k + 1 ,
we can approximate it by multiplying t with equation (22) as follows
f s ( t ) t 1 ( 2 t ) 70 + 1 .
Figure 1 shows the sawtooth function (25) and its approximation (26) by black and light green curves, respectively.
Applying the sampling function over the points n h to approximation (26), we obtain
f s ( t ) n = N N s ( t n h ) f s ( n h ) = h c π n = N N e ( t n h c ) 2 f s ( n h ) = h c π n = N N e 2 n h c 2 t e t c 2 e n h c 2 f s ( n h ) .
Consequently, the FT of the sawtooth function (25) can be approximated as
f ^ s ( ν ) 2 i h c π n = N N e t c 2 + 2 n h c 2 t e n h c 2 f s ( n h ) sin ( 2 π ν t ) d t = 2 i h π n = N N e t 2 + 2 n h c t e n h c 2 f s ( n h ) sin ( 2 π ν c t ) d t = i h π n = N N e t 2 4 + n h c t e n h c 2 f s ( n h ) sin ( π ν c t ) d t .
Comparing this equation with the imaginary Voigt function (20), we can rearrange equation above as
f ^ s ( ν ) i h m = N N e n h c 2 f s ( n h ) L π ν c , n h c .
The applied methodology for the FTs of the rectangular and sawtooth functions (24) and (27) can be generalized to any even or odd functions as
f ^ e v e n ( ν ) h m = N N e n h c 2 f e v e n ( n h ) K π ν c , n h c
and
f ^ o d d ( ν ) i h m = N N e n h c 2 f o d d ( n h ) L π ν c , n h c .
Due to symmetric properties of the even and odd functions (see equations (7) and (8)), the number of the summation terms in these approximations can be reduced by a factor of two.
Let us rearrange equation (28) in the following form
f ^ e v e n ( ν ) h f e v e n ( 0 ) K ( π ν c , 0 ) + m = 1 N e n h c 2 f e v e n ( n h ) K π ν c , n h c + m = N 1 e n h c 2 f e v e n ( n h ) K π ν c , n h c .
Change of summation index as
m = N 1 e n h c 2 f e v e n ( n h ) K π ν c , n h c = m = 1 N e n h c 2 f e v e n ( n h ) K π ν c , n h c
leads to
f ^ e v e n ( ν ) h f e v e n ( 0 ) K ( π ν c , 0 ) + m = 1 N e n h c 2 f e v e n ( n h ) K π ν c , n h c + m = 1 N e n h c 2 f e v e n ( n h ) K π ν c , n h c .
Since according to equation (7)
e n h c 2 = e n h c 2 ,
f e v e n ( n h ) = f e v e n ( n h ) ,
and since
K ( x , 0 ) = e x 2 K ( π ν c , 0 ) = e ( π ν c ) 2 ,
we can write
f ^ e v e n ( ν ) h f e v e n ( 0 ) e ( π ν c ) 2 + m = 1 N e n h c 2 f e v e n ( n h ) V k π ν c , n h c ,
where
V k π ν c , n h c = K π ν c , n h c + K π ν c , n h c
Equation (29) can be expanded as
f ^ o d d ( ν ) i h f o d d ( 0 ) L ( π ν c , 0 ) + m = 1 N e n h c 2 f o d d ( n h ) L π ν c , n h c + m = N 1 e n h c 2 f o d d ( n h ) L π ν c , n h c
Taking into consideration that
m = N 1 e n h c 2 f o d d ( n h ) L π ν c , n h c = m = 1 N e n h c 2 f o d d ( n h ) L π ν c , n h c
such that according to (8)
f o d d ( n h ) = f o d d ( n h )
and since
L ( π ν c , 0 ) = 0 ,
we can recast equation (32) as given by
f ^ o d d ( ν ) i h m = 1 N e n h c 2 f o d d ( n h ) L π ν c , n h c + m = 1 N e n h c 2 f o d d ( n h ) L π ν c , n h c
or
f ^ o d d ( ν ) i h [ f o d d ( 0 ) L ( π ν c , 0 ) + m = 1 N e n h c 2 f o d d ( n h ) L π ν c , n h c L π ν c , n h c ]
or
f ^ o d d ( ν ) i h m = 1 N e n h c 2 f o d d ( n h ) V π ν c , n h c ,
where
V π ν c , n h c = L π ν c , n h c L π ν c , n h c .
At first glance the FT formulas (30) and (33) may appear computationally costly as they require user defined (external) function files. However, unlike equation (11), the expansion coefficients V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) , shown by equations (31) and (34), respectively, do not require re-computations every time when we change the sampled function f ( t ) to any other function. This gives a significant advantage. Since the values V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) remain always the same regardless the shape of the sampled function, these values can be precomputed in form of the look-up tables. Such implementation makes computation rapid as the required values V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) can be instantly picked up from the computer memory during computation of the FT. Furthermore, many algorithms, based on rational approximations, have been developed for rapid and high-accuracy computation of the Voigt/complex error function [23,24,25,26,27,28,29,30,31,32,33]. Therefore, the proposed technique can also be used as an alternative for rational approximation (11) of the FT.

3.2. Numerical Results

The FT of the rectangular function can be readily found by integration as
f ^ r ( ν ) = f r ( t ) e 2 π i ν t d t = 1 / 2 1 / 2 e 2 π i ν t d t = sinc ( π ν ) ,
where
sinc ( x ) = sin ( x ) x , x 0 , 1 , x = 0 ,
is the sinc function [34,35]. Similarly, we can find the FT of the sawtooth function as follows
f ^ s ( ν ) = f s ( t ) e 2 π i ν t d t = t f r ( t ) e 2 π i ν t d t = 1 / 2 1 / 2 t e 2 π i ν t d t = i π ν cos ( π ν ) sin ( π ν ) 2 π 2 ν 2 ,
We can use these analytical results for comparison with numerical FTs computed by using equations (30) and (33).
Figure 3 shows numerical FTs of rectangular and the sawtooth functions by light green and magenta curves, respectively. Equations (35) and (36) are also shown by dashed black curves.
Figure 4 illustrates the absolute differences Δ r and Δ s between equations (35), (36) and numerical FT approximations (30) and (33) at h = 0.02 , c = 0.025 and N = 25 by blue and red curves, respectively. As we can see, despite abrupt behavior of the rectangular and sawtooth functions f r ( t ) and f s ( t ) at t 1 , 2 = ± 1 / 2 and t 1 , 2 = ± 1 / 4 , the FT approximations (24) and (27) can provide reasonable accuracies.
The accuracy of the FT can be significantly better for the well-behaved functions. As an example, consider a function
g ( t ) = e ( 6 π t ) 2 sin ( 32 t ) e 7 π t 2 .
The first term of this function is even
g e v e n ( t ) = g ( t ) + g ( t ) 2 = e ( 6 π t ) 2
while its second term is odd
g o d d ( t ) = g ( t ) g ( t ) 2 = sin ( 32 t ) e ( 7 π t ) 2 .
Figure 5 shows the functions g ( t ) , g e v e n ( t ) and g o d d ( t ) by blue, red and green colors, respectively.
The FTs of even and odd components (38) and (39) can be obtained analytically. In particular, substituting equations (38) and (39) into FT formulas (9) and (10) yields
g ^ e v e n ( ν ) = e ν 6 2 6 π
and
g ^ o d d ( ν ) = i 1 14 π e 16 + π ν 7 π 2 e 64 ν 49 π 1 .
Figure 6 depicts the absolute errors Δ e v e n and Δ o d d between equations (40), (41) and corresponding FT approximations (30) and (33) at h = 0.004 , c = 0.0045 and N = 30 by blue and red colors, respectively. As we can see, the absolute errors do not exceed 0.00035 and 0.0005 for the functions and g ^ e v e n ( ν ) and g ^ o d d ( ν ) , respectively, over the wide interval of ν .

3.3. Trigonometric Forms

As it has been mentioned above, the equations (28), (29) and their variations (30), (33) can be used to implement a rational approximation of the FT. We can also show how to represent these equations in trigonometric forms.
The real part of equation (14) gives
K ( x , y ) = 2 e x 2 + y 2 cos ( 2 x y ) K ( x , y )
Therefore, equation (31) can be further simplified as
V k π ν c , n h c = K π ν c , n h c + 2 e ( π ν c ) 2 + n h c cos π ν c , n h c K π ν c , n h c = 2 e ( π ν c ) 2 + n h c cos π ν c , n h c .
leading to
f ^ e v e n ( ν ) h e π ν c 2 f e v e n ( 0 ) + 2 m = 1 N f e v e n ( n h ) cos ( 2 π ν n h )
in accordance with equation (30).
The imaginary part of equation (14) provides
L ( x , y ) = 2 e x 2 + y 2 sin ( 2 x y ) + L ( x , y )
Substituting this equation into approximation (34) yields
V π ν c , n h c = L π ν c , n h c 2 e ( π ν c ) 2 + n h c 2 sin ( 2 π ν n h ) L π ν c , n h c = 2 e ( π ν c ) 2 + n h c 2 sin ( 2 π ν n h ) .
This results in
f ^ o d d ( ν ) 2 i h e ( π ν c ) 2 m = 1 N f o d d ( n h ) sin ( 2 π ν n h )
according to equation (33).
As we can see, equations (42) and (43) represent trigonometric versions of the equations (30) and (33), respectively. Despite trigonometric representations, equations (42) and (43) do not have any advantage over equations (30) and (33) in computational speed since all required values V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) can be precomputed and saved in a computer memory in form of the look-up tables.
Combining equations (3), (4), (5), (42) and (43) together, we obtain
f ^ ( ν ) h e ( π ν c ) 2 [ f ( 0 ) + m = 1 N f ( n h ) + f ( n h ) cos ( 2 π ν n h ) i f ( n h ) f ( n h ) sin ( 2 π ν n h ) ]
or
f ^ ( ν ) h e ( π ν c ) 2 f ( 0 ) + m = 1 N f ( n h ) e 2 π i ν n h + f ( n h ) e 2 π i ν n h .
We can see that equation (44) resembles the discrete Fourier transfer (DFT) [1,2]. However, unlike the DFT, equation (44) provides non-periodic output due to exponential multiplier e ( π ν c ) 2 acting like the Hamming window that sometimes may be introduced to eliminate periodicity in time or frequency domains. Remarkably, this exponential multiplier in equation (44) was not introduced but appeared naturally in derivation.
Examples of the numerical FTs based on equations (30) and (33) can be validated by running the Mathematica codes, shown in the next section.

4. Mathematica Codes

4.1. Complex Error Function

To compute the complex error function w ( z ) , we can use, for example, the algorithm provided in our work [29]. To cover the entire complex plane with high accuracy of computation, we used only three approximations. We will use four cells to define each equation and to distribute them accordingly on the complex plane.
The first cell below is to define Equation (7) from [29].
Clear[a0, b0, c0, \[CapitalOmega], w1];
(* Fitting parameters *)
H = 0.25; \[Stigma] = 2.75; M = 25; maxN = 23;
(* Expansion coefficients, 1st set *)
a0[m_] := a0[m] = ((Sqrt[Pi]*(m - 1/2))/(2*M^2*H))*
  Sum[E^(\[Stigma]^2/4 - n^2*H^2)*Sin[(Pi*(m - 1/2)*
    (n*H + \[Stigma]/2))/(M*H)], {n, -maxN, maxN}];
b0[m_] := b0[m] = (-(I/(M*Sqrt[Pi])))*
  Sum[E^(\[Stigma]^2/4 - n^2*H^2)*Cos[(Pi*(m - 1/2)*
    (n*H + \[Stigma]/2))/(M*H)], {n, -maxN, maxN}];
c0[m_] := c0[m] = (Pi*(m - 1/2))/(2*M*H);
(* Equation (7) from Ref. [29] *)
\[CapitalOmega][z_] := \[CapitalOmega][z] = Sum[(a0[m] + b0[m]*z)/
  (c0[m]^2 - z^2), {m, 1, M - 2}];
w1[z_] := \[CapitalOmega][z + I*(\[Stigma]/2)];
The second cell is required to instantiate Equation (8) from [29].
Clear[a1, b1, c1, d1, w2];
(* Expansion coefficients, 2nd set *)
a1[m_] := a1[m] = b0[m]*(((Pi*(m - 1/2))/(2*M*H))^2 -
  (\[Stigma]/2)^2) + I*a0[m]*\[Stigma];
b1[m_] := b1[m] = b0[m];
c1[m_] := c1[m] = (((Pi*(m - 1/2))/(2*M*H))^2 +
  (\[Stigma]/2)^2)^2;
d1[m_] := d1[m] = 2*((Pi*(m - 1/2))/(2*M*H))^2 -
  \[Stigma]^2/2;
(* Equation (8) from Ref. [29] *)
w2[z_] := E^(-z^2) + z*Sum[(a1[m] - b1[m]*z^2)/
  (c1[m] - d1[m]*z^2 + z^4), {m, 1, M - 2}];
This third cell is required to define Equation (9) from [29].
Clear[w3];
(* Equation (9) from Ref. [29] *)
w3[z_] := I/(Sqrt[Pi]*(z - 1/(2*(z - 1/(z - 3/
  (2*(z - 2/(z - 5/(2*(z - 3/(z - 7/(2*(z - 4/
    (z - 9/(2*(z - 5/(z - 11/(2*z))))))))))))))))));
Once these three equations are instantiated, we need to distribute them correspondingly on the complex plane. The forth cell below contains code to accomplish this task.
Clear[wUp, w];
(* Complex error function for upper complex plane *)
wUp[z_] := If[Abs[z] > 8, w3[z],
  If[Im[z] > 0.05*Abs[Re[z]], w1[z], w2[z]]];
(* Complex error function for entire complex plane *)
w[z_] := If[Im[z] >= 0, wUp[z],
  Conjugate[2*E^-Conjugate[z]^2 - wUp[Conjugate[z]]]];
Now the code for computation of the complex error function is ready to use.
It should be noted that another Mathematica code for high-accuracy computation of the complex error function can be downloaded from [33]. This code was written by Jan Mangaldan on the bases of three rational approximations described in our publication [30].

4.2. Fourier Transform

The Mathematica codes below consist of six cells. The code shown in the first cell below defines the Voigt function K ( x , y ) and imaginary Voigt function L ( x , y ) , the rectangular function f r ( t ) and the sawtooth function f s ( t ) .
Clear[K,L,fr,fs];
(* Defining K(x,y) and L(x,y) functions *)
K[x_, y_] := Re[w[x + I*y]];
L[x_, y_] := Im[w[x + I*y]];
(* Rectangular function *)
fr[t_] := 1/((2*t)^(2*35) + 1);
(* Sawtooth function *)
fs[t_] := t*fr[t];
The second cell below generates two look-up tables for the values V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) . It also generates a list of grid-points for the parameter ν .
Clear[lookUpTab1, lookUpTab2, nuList];
(* Parameters for computation *)
h = 0.02; c = 0.025; nMax = 25;
(* Computing two look-up tables *)
lookUpTab1 = Table[{K[Pi*\[Nu]*c, (n*h)/c] +
  K[Pi*\[Nu]*c, ((-n)*h)/c]}, {n, 1, nMax},
    {\[Nu], -2*Pi, 2*Pi, 0.1}];
lookUpTab2 = Table[{L[Pi*\[Nu]*c, (n*h)/c] -
  L[Pi*\[Nu]*c, ((-n)*h)/c]}, {n, 1, nMax},
    {\[Nu], -2*Pi, 2*Pi, 0.1}];
nuList = Table[\[Nu], {\[Nu], -2*Pi, 2*Pi, 0.1}];
The code in the following third cell is needed to format two look-up table with values V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) for plotting the graphs. It is also required to join V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) values together with corresponding values of the parameter ν .
Clear[ftList1, ftList2];
(* Main computations by using look up tables *)
ftList1 = Flatten[h*(fr[0]/E^(Pi*nuList*c)^2 +
  Sum[(fr[n*h]*lookUpTab1[[n]])/E^((n*h)/c)^2, {n, 1, nMax}])];
ftList2 = Flatten[h*Sum[(fs[n*h]*lookUpTab2[[n]])/E^((n*h)/c)^2,
  {n, 1, nMax}]];
(* Arranging FT data lists *)
ftList1 = Table[{nuList[[n]], ftList1[[n]]}, {n, 1, Length[nuList]}];
ftList2 = Table[{nuList[[n]], ftList2[[n]]}, {n, 1, Length[nuList]}];
The code in next forth cell is required to generate the references in accordance with equations (35) and (36).
Clear[ftRef1, ftRef2];
(* FT references *)
ftRef1 = Table[{\[Nu], Sinc[Pi*\[Nu]]}, {\[Nu], -2*Pi, 2*Pi, 0.1}];
ftRef2 = Table[{\[Nu], (Pi*\[Nu]*Cos[Pi*\[Nu]] - Sin[Pi*\[Nu]])/(2*
  Pi^2*\[Nu]^2)}, {\[Nu], -2*Pi, 2*Pi, 0.1}];
The code in the fifth cell below produces the graph shown in the Fig. 3.
(* Plotting the graphs from the data lists *)
ListPlot[{ftList1, ftRef1, ftList2, ftRef2}, PlotRange -> All,
  Joined -> True, PlotStyle -> {{Lighter[Green, 0], Thickness[0.005]},
    {Black, Dashed, Thickness[0.0025]}, {Lighter[Magenta, 0.5],
Thickness[0.005]}, {Black, Dashed, Thickness[0.0025]}},
  PlotRange -> {{-2*Pi, 2*Pi}, {-0.3, 1.1}},
    AxesLabel -> {"\[Nu]", None}]
Lastly, the code in following sixth cell applies the derived formula (44) to generate the same Fig. 3 without Voigt functions.
(* Plotting the graphs by using the FT formula (42) *)
f[t_] := fr[t] + fs[t];
ft[\[Nu]_] := (h*(f[0] + Sum[f[n*h]/E^(2*Pi*I*\[Nu]*n*h) +
  f[(-n)*h]*E^(2*Pi*I*\[Nu]*n*h), {n, 1, nMax}]))/
    E^(Pi*\[Nu]*c)^2;
Plot[{Re[ft[\[Nu]]], Sinc[Pi*\[Nu]], Im[ft[\[Nu]]],
  (Pi*\[Nu]*Cos[Pi*\[Nu]] - Sin[Pi*\[Nu]])/(2*(Pi*\[Nu])^2)},
    {\[Nu], -2*Pi, 2*Pi}, PlotRange -> All, PlotStyle ->
      {{Lighter[Green, 0], Thickness[0.005]}, {Black, Dashed,
Thickness[0.0025]}, {Lighter[Magenta, 0.5],
  Thickness[0.005]},{Black, Dashed, Thickness[0.0025]}},
    PlotRange -> {{-2*Pi, 2*Pi}, {-0.3, 1.1}},
      AxesLabel -> {"\[Nu]", None}]
The codes shown in this section can be copy-pasted directly to the Mathematica notebook.

5. Conclusions

An alternative method of rational approximation of the FT based on the real and imaginary parts of the complex error function (12) is developed. Unlike the rational approximation (11) of the FT, the expansion coefficients V k ( π ν c , n h / c ) and V ( π ν c , n h / c ) in this method do not depend on values of the sampled function f ( t ) . Since the values of the Voigt functions remain always the same, this approach can be used for rapid computation with help of look-up tables. We also show that this rational approximation of the FT can also be rearranged in a trigonometric form (44) with an exponential multiplier e ( π ν c ) 2 acting like the Hamming window that removes periodicity.

Author Contributions

Sanjar M. Abrarov wrote the manuscript and developed the codes. Rajinder K. Jagpal and Rehan Siddiqui and Brendan M. Quine performed data analysis and verifications. All authors reviewed and approved the manuscript.

Funding

This research received no external funding.

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
FT Fourier transform
DFT Discrete Fourier transform

References

  1. Hansen, E.W. ; Fourier Transforms: Principles and Applications; John Wiley & Sons, Hoboken, 2014.
  2. Bracewell, R.N. ; The Fourier Transform and Its Applications; 3rd Edition, McGraw-Hill, New York, 2000.
  3. Abrarov, S.M.; Siddiqui, R.; Jagpal, R.K.; Quine, B.M. A rational approximation of the Fourier Transform by integration with exponential decay multiplier. Appl. Math. 2021, 12, 947–962. [Google Scholar] [CrossRef]
  4. Baker Jr., G. A.; Gammel, J.L; Wills, J.G. An investigation of the applicability of the Padé approximant method. J. Math. Anal. Appl. 1961, 2, 405–418. [Google Scholar] [CrossRef]
  5. Brezenski, C. Extrapolation algorithms and Padé approximations. Appl. Numer. Math. 1996, 20, 299–318. [Google Scholar] [CrossRef]
  6. Filip, S.-I.; Nakatsukasa, Y.; Trefethen, L.N.; Beckermann, B. Rational minimax approximation via adaptive barycentric representations. SIAM J. Sci. Comput. 2018, 40, A2427–A2455. [Google Scholar] [CrossRef]
  7. Nakatsukasa, Y.; Trefethen, L.N. An algorithm for real and complex rational minimax approximation. SIAM J. Sci. Comput. 3157. [Google Scholar] [CrossRef]
  8. Pachón, R.; Trefethen, L.N. Barycentric-Remez algorithms for best polynomialap proximation in the chebfun system. BIT Numer. Math. 2009, 49, 721–741. [Google Scholar] [CrossRef]
  9. Hofreither, C. An algorithm for best rational approximation based on barycentric rational interpolation. Numer. Algor. 2021, 88, 365–388. [Google Scholar] [CrossRef]
  10. Abrarov, S.M.; Quine, B.M. Sampling by incomplete cosine expansion of the sinc function: application to the Voigt/complex error function. Appl. Math. Comput. 2015, 258, 425–435. [Google Scholar] [CrossRef]
  11. Abramowitz, M.; Stegun, I. ; Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical tables; 9th Ed. Dover, New York, 1972.
  12. Armstrong, B.H.; Nicholls, B.W. Emission, Absorption and Transfer of Radiation in Heated Atmospheres. Pergamon Press, New York, 1972.
  13. Schreier, F. The Voigt and complex error function: a comparison of computational methods. J. Quant. Spectrosc. Radiat. Transfer. 1992, 48, 743–762. [Google Scholar] [CrossRef]
  14. Armstrong, B.H. Spectrum line profiles: the Voigt function. J. Quant. Spectrosc. Radiat. Transfer. 1967, 61–88. [Google Scholar] [CrossRef]
  15. Zaghloul, M.R.; Ali, A.N. Algorithm 916: Computing the Faddeyeva and Voigt functions. ACM Trans. Math. Soft. 2012, 38, 1–22. [Google Scholar] [CrossRef]
  16. Berk, A.; Hawes, F. Validation of MODTRAN®6 and its line-by-line algorithm. J. Quant. Spectrosc. Radiat. Transfer. 2017, 203, 542–556. [Google Scholar] [CrossRef]
  17. Pliutau, D.; Roslyakov, K. Bytran -|- spectral calculations for portable devices using the HITRAN database. Earth Sci. Inf. 2017, 10, 395404. [Google Scholar] [CrossRef]
  18. Pliutau, D. Combined “Abrarov/Quine-Schreier-Kuntz (AQSK)” algorithm for the calculation of the Voigt function. J. Quant. Spectrosc. Radiat. Transfer. 2021, 272. [Google Scholar] [CrossRef]
  19. Balazs, N.L.; Tobias, I. Semiclassical dispersion theory of lasers. Phil. Trans. Royal Soc. A. 1969, 264, 1–29. [Google Scholar] [CrossRef]
  20. Chan, L.K.P. Equation of atomic resonance for solid-state optics. Appl. Opt. 1986, 25, 1728–1730. [Google Scholar] [CrossRef]
  21. Srivastava, H.M.; Miller, E.A. A unified presentation of the Voigt function. Astrophys. Space Sci. 1987, 135, 111–118. [Google Scholar] [CrossRef]
  22. Abrarov, S.M.; Quine, B.M. A new application of the Fourier transform for rational approximation of the complex error function. J. Math. Research, 2016, 8, 14–23. [Google Scholar] [CrossRef]
  23. Humlíček, J. An efficient method for evaluation of the complex probability function: The Voigt function and its derivatives. J. Quant. Spectrosc. Radiat. Transfer. 1979, 2, 309–313. [Google Scholar] [CrossRef]
  24. Weideman, J.A.C. Computation of the complex error function. SIAM J. Numer. Anal. 1994, 31, 1497–1518. [Google Scholar] [CrossRef]
  25. Wells, R.J. Rapid approximation to the Voigt/Faddeeva function and its derivatives. J. Quant. Spectrosc. Radiat. Transfer. 1999, 62, 29–48. [Google Scholar] [CrossRef]
  26. Letchworth, K.L.; Benner, D.C. Rapid and accurate calculation of the Voigt function. J. Quant. Spectrosc. Radiat. Transfer. 2007, 107, 173–192. [Google Scholar] [CrossRef]
  27. Schreier, F. Optimized implementations of rational approximations for the Voigt and complex error function. J. Quant. Spectrosc. Radiat. Transfer. 2011, 112, 1010–1025. [Google Scholar] [CrossRef]
  28. Schreier, F. The Voigt and complex error function: Humlíček’s rational approximation generalized. Month. Not. Roy. Astron. Soc. 2018, 479, 3068–3075. [Google Scholar] [CrossRef]
  29. Abrarov, S.M.; Quine, B.M.; Jagpal, R.K. A sampling-based approximation of the complex error function and its implementation without poles. Appl. Numer. Math. 2018, 129, 181–191. [Google Scholar] [CrossRef]
  30. Abrarov, S.M.; Quine, B.M. A rational approximation of the Dawson’s integral for efficient computation of the complex error function. Appl. Math. Comput. 2018, 321, 526–543. [Google Scholar] [CrossRef]
  31. Al Azah, M.; Chandler-Wilde, S.N. Computation of the complex error function using modified trapezoidal rules. SIAM J. Numer. Anal. 2021, 59, 2346–2367. [Google Scholar] [CrossRef]
  32. Thompson, I. Algorithm 1046: an improved recurrence method for the scaled complex error function. ACM Trans. Math. Soft. 2024, 50, 1–18. [Google Scholar] [CrossRef]
  33. J. Mangaldan, Evaluate the Faddeeva function. Available online: https://tinyurl.com/2bmf9m4f (accessed on March 21, 2025).
  34. Kac, M. ; Statistical independence in probability, analysis and number theory; Washington, DC: Mathecal Association of America, 1959. [Google Scholar]
  35. Gearhart, W.B.; Shultz, H.S. The function sin(x)/x. College Math. J. 1990, 21, 90–99. [Google Scholar] [CrossRef]
1
Matlab code can be copy-pasted from this link: arXiv:2001.07533
Figure 2. The rectangular function (dashed black curve) and its approximations by sampling at h = 0.065 , c = 0.035 , N = 25 (green curve), h = 0.05 , c = 0.03 , N = 25 (red curve) and h = 0.02 , c = 0.025 , N = 25 (light blue curve).
Figure 2. The rectangular function (dashed black curve) and its approximations by sampling at h = 0.065 , c = 0.035 , N = 25 (green curve), h = 0.05 , c = 0.03 , N = 25 (red curve) and h = 0.02 , c = 0.025 , N = 25 (light blue curve).
Preprints 154868 g002
Figure 3. Fourier transforms of the rectangular and sawtooth functions (dashed black curves) and their approximations (green and magenta curves, respectively).
Figure 3. Fourier transforms of the rectangular and sawtooth functions (dashed black curves) and their approximations (green and magenta curves, respectively).
Preprints 154868 g003
Figure 4. Absolute differences between equations (35), (36) and their approximations. Blue curve corresponds to equation (35), red curve corresponds to equation (36)).
Figure 4. Absolute differences between equations (35), (36) and their approximations. Blue curve corresponds to equation (35), red curve corresponds to equation (36)).
Preprints 154868 g004
Figure 5. Equation (37) and its even and odd components (blue, red and green curves, respectively).
Figure 5. Equation (37) and its even and odd components (blue, red and green curves, respectively).
Preprints 154868 g005
Figure 6. Absolute differences between equations (30), (33) and their approximations. Blue curve corresponds to equation (30), red curve corresponds to equation (33).
Figure 6. Absolute differences between equations (30), (33) and their approximations. Blue curve corresponds to equation (30), red curve corresponds to equation (33).
Preprints 154868 g006
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.
Prerpints.org logo

Preprints.org is a free preprint server supported by MDPI in Basel, Switzerland.

Subscribe

Disclaimer

Terms of Use

Privacy Policy

Privacy Settings

© 2025 MDPI (Basel, Switzerland) unless otherwise stated