rms

typhoon.test.IEC61000.rms(samples, nominal_grid_freq, reference_split=None)

Measures the root-mean-square (RMS) value for input samples according to the IEC 61000-4-30 standard.

Parameters:
  • samples (pandas.DataFrame or pandas.Series) – Samples from the signals in which RMS values should be measured, organized in columns.

  • nominal_grid_freq (float) – This method is applied only to grids with a nominal frequency of 50.0 Hz or 60.0 Hz in accordance with the IEC 61000-4-30 standard.

  • reference_split (list) – Optional and None by default. List of the indices to split the sample in windows. If None, the samples will be split according to the zero-crossings of the voltage signal.

Returns:

rms_values – The RMS values for each signal.

Return type:

pandas.DataFrame

Raises:

ValueError – When the nominal_grid_freq is different from 50 Hz or 60 Hz:

Examples

>>> from typhoon.test.signals import pandas_sine
>>> from typhoon.test.IEC61000 import rms
>>> grid_freq = 60
>>> signal = pandas_sine(frequency=grid_freq)
>>> rms_signal = rms(signal, grid_freq)