Relation between current distortion factor and THD with DC current (source code)

= Relation between current distortion factor and THD with DC current
{title2=$D_I=[1+\mathrm{THD}_I^2+(I_0/I_1)^2]^{-1/2}$}

The <relation between current distortion factor and THD with DC current> accounts for the mean component omitted from the usual fundamental-normalized <total harmonic distortion>. For a periodic <electric current>, let $I_0$ be its signed <DC component>, $I_1>0$ the fundamental RMS magnitude, and $I_n$ the RMS magnitudes of higher <harmonic components>. The <Parseval identity> gives
$$
I_{\rm rms}^2=I_0^2+I_1^2+\sum_{n\ge2}I_n^2.
$$
Define $\mathrm{THD}_I=\sqrt{\sum_{n\ge2}I_n^2}/I_1$ and <current distortion factor> $D_I=I_1/I_{\rm rms}$. Division by $I_1^2$ proves
$$
\boxed{D_I=\left[1+\mathrm{THD}_I^2+(I_0/I_1)^2\right]^{-1/2}.}
$$
The <root mean square> in this expression includes the mean, while the stated <total harmonic distortion> excludes it. An instrument reporting AC-only RMS or a differently normalized distortion quantity requires a correspondingly different conversion.

For an original example, take $I_1=4\,\mathrm A$, $I_0=3\,\mathrm A$ and combined higher-harmonic RMS magnitude $2\,\mathrm A$. Then $\mathrm{THD}_I=0.5$, $I_{\rm rms}=\sqrt{29}\,\mathrm A$ and $D_I=4/\sqrt{29}\approx0.7428$. Neglecting the <DC component> would instead predict $1/\sqrt{1.25}\approx0.8944$. In the same conductor <electrical resistance> $R$, the actual heating is $29R$, while that omission would predict $20R$.

For a zero-mean sinusoidal supply of $100\,\mathrm V$ RMS and an in-phase fundamental current, the example absorbs $400\,\mathrm W$. Its <apparent power> is approximately $538.52\,\mathrm{VA}$, so total <power factor> is $0.7428$ despite a <displacement power factor> of one. The <DC component> carries no average power from that particular zero-mean supply, but it still increases mean-square <electric current>. If the supply itself has a <DC component>, its contribution $V_0I_0$ must be included through the <harmonic active power sum>.

As $I_1$ tends to zero the defining <current distortion factor> can tend to zero, but fundamental-normalized <total harmonic distortion> is undefined at $I_1=0$. Do not evaluate the boxed relation there by silently dividing by zero. The manufacturer's documentation also uses differing labels for distortion ratios, reinforcing the need to state the defining normalization.<Power Quality Considerations by Schneider Electric>[Power Quality Metrics, Distortion Factor]{ref}<Overview of Functions: Harmonic Measurements by Schneider Electric>[Quality Indicators, Distortion Factor]{ref}