Discrete Total Harmonic Distortion
Purpose
Calculate total harmonic distortion (THD) of input signal
Library
Control / Discrete
Description
This block calculates the total harmonic distortion of a periodic input signal based on discrete samples. The sample time and the number of samples can be specified. The THD is defined as:
where is the RMS value of the
th harmonic of the input signal and
is
its overall RMS value. The fundamental frequency
of the running window is
Parameters
- Sample time
- The time interval between samples. See also the Discrete-Periodic sample time type in section Sample Times.
- Number of samples
- The number of samples used to calculate the THD.