pysrw.lib.srwlib.srwl_wfr_cmd

Contents

pysrw.lib.srwlib.srwl_wfr_cmd#

pysrw.lib.srwlib.srwl_wfr_cmd(_csd, _n_modes, _awfr=None, _alg=None)[source]#

Perform Coherent Mode Decomposition (CMD) of (4D) Cross-Spectral Density / Mutual Intensity data. :param _csd: Cross-Spectral Density / Mutual Intensity described by SRWLStokes object with complex 4D data array :param _n_modes: maximum number of coherent modes to be produced by the decomposition :param _awfr: optional average Wavefront that can be used if quadratic phase terms have to be treated during the decomposition :param _alg: algorithm to be used for solving the CMD Eigenvalue problem; among those currently supported are: ‘PM’ - Primme (requires a dedicated ‘primme’ module to be installed); ‘SP’ - SciPy; ‘SPS’ - SciPy Sparse (the latter two available in SciPy package) :return: list of Coherent Modes (objects of SRWLWfr type) produced by the decomposition