pwtools.signal.cauchy

pwtools.signal.cauchy(M, std=1.0, sym=True)

Lorentz window (same as Cauchy function). Function skeleton stolen from scipy.signal.windows.gaussian().

The Lorentz function is

\[L(x) = \frac{\Gamma}{(x-x_0)^2 + \Gamma^2}\]

Here \(x_0 = 0\) and std = \(\Gamma\). Some definitions use \(1/2\,\Gamma\) instead of \(\Gamma\), but without 1/2 we get comparable peak width to Gaussians when using this window in convolutions, thus scipy.signal.gaussian(M, std=5) is similar to lorentz(M, std=5).

Parameters:
  • M (int) – number of points

  • std (float) – spread parameter \(\Gamma\)

  • sym (bool)

Returns:

w

Return type:

(M,)