Convolution operator

class qef.operators.convolve.Convolve(resolution, model, **kws)[source]

Bases: lmfit.model.CompositeModel

Convolution between model and resolution.

It is assumed that the resolution FWHM is energy independent. Non-symmetric energy ranges are allowed (when the range of negative values is different than that of positive values).

The convolution requires multiplication by the X-spacing to preserve normalization

eval(params=None, **kwargs)[source]

TODO: docstring in public method.

qef.operators.convolve.convolve(model, resolution)[source]

Convolution of resolution with model data.

It is assumed that the resolution FWHM is energy independent. We multiply by spacing \(dx\) of independent variable \(x\).

\[(model \otimes resolution)[n] = dx * \sum_m model[m] * resolution[m-n]\]
Parameters:
  • model (numpy.ndarray) – model data
  • resolution (numpy.ndarray) – resolution data
Returns:

Return type:

numpy.ndarray