Wave polarization

pyspedas.twavpol(tvarname, prefix='', nopfft=-1, steplength=-1, bin_freq=-1)

Apply wavpol to a pytplot variable.

Creates multiple pytplot variables: ‘_powspec’,’_degpol’, ‘_waveangle’, ‘_elliptict’, ‘_helict’, ‘_pspec3_x’, ‘_pspec3_y’, ‘_pspec3_z’

Parameters:
  • tvarname (string) – Name of pytplot variable.

  • prefix (string, optional) – Prefix for pytplot variables created.

  • nopfft (int, optional) – Number of points in FFT. The default is 256.

  • steplength (int, optional) – The amount of overlap between successive FFT intervals. The default is -1 which means nopfft/2.

  • bin_freq (int, optional) – Number of bins in frequency domain. The default is 3.

Returns:

result – Returns 1 if completed successfully. Returns 0 if it encountered problems and exited.

Return type:

bool

pyspedas.analysis.twavpol.wavpol(ct, bx, by, bz, nopfft=256, steplength=-1, bin_freq=3)

Perform polarisation analysis of Bx, By, Bz time series data.

Parameters:
  • ct (list of float) – Time.

  • bx (list of float) – Bx field.

  • by (list of float) – By field.

  • bz (list of float) – Bz field.

  • nopfft (int, optional) – Number of points in FFT. The default is 256.

  • steplength (int, optional) – The amount of overlap between successive FFT intervals. The default is -1 which means nopfft/2.

  • bin_freq (int, optional) – Number of bins in frequency domain. The default is 3.

Returns:

  • result (tuple with 9 items)

  • timeline (list of float) – Times.

  • freqline (list of float) – Frequencies.

  • powspec (2-dim array of float) – Wave power.

  • degpol (2-dim array of float) – Degree of Polarisation.

  • waveangle (2-dim array of float) – Wavenormal Angle.

  • elliptict (2-dim array of float) – Ellipticity.

  • helict (2-dim array of float) – Helicity.

  • pspec3 (3-dim array of float) – Power spectra.

  • err_flag (bool) – Error flag. The default is 0. Returns 1 if there are large number of batches and aborts.