comnum.cyclic_autocorrelation#
- comnum.cyclic_autocorrelation(x, alpha, *, lag=0, fs=1.0)#
The cyclic autocorrelation
R^α(τ) = mean x[n+τ] x*[n] e^{-j2π α n/f_s}.- Parameters:
- Returns:
the cyclic autocorrelation.
- Return type:
- Raises:
ValueError – for an input that is not an array of numbers of the expected shape.
Examples
>>> import comnum, numpy as np >>> x = np.ones(100, dtype=complex) >>> abs(comnum.cyclic_autocorrelation(x, 0.0, lag=0, fs=1.0)) 1.0