Total Harmonic Distortion or THD is a measurement of the harmonic distortion in a signal which is a measure of the quality of signal.
Mathematically its defined as the the ratio of the sum of the power of all harmonic components to the power of the fundamental frequency