Convolution is an extension of CompositeFunction which performs convolution of its members using either the Fast Fourier Transform (symmetric domain) or the direct formula (asymmetric domain).
Here is the first member function and is the second member. A Convolution must have exactly two member functions. The members can be composite if necessary. Interval is the fitting interval.
if similar to , the function is evaluated by first transforming and to the Fourier domain, multiplying the transforms, then transforming back to the original domain. The GSL FFT routines are used to do the actual transformations.
It should be noted that the two functions ( and ) are evaluated on different intervals. is computed on while is computed on , where .
In the following example a Convolution is convolved with a box function:
Note that the box function is defined on interval [-5, 5]:
If and differ, the convolution is performed with the direct formula. is computed on and is computed on . This setting guarantees that overlaps completely in the domain when performing the convolution.
In the following example a QENS signal is fitted to a two-Lorentzian model, convolved with the experimental resolution, in the asymmetric energy range .
Name | Type | Default | Description |
---|---|---|---|
FixResolution | |||
NumDeriv |
Categories: FitFunctions | General
C++ source: Convolution.cpp (last modified: 2016-05-10)
C++ header: Convolution.h (last modified: 2016-05-09)