Let $X, Y \in \text{Random}(\mathcal{X})$ each be a D5723: Simple random variable such that
Let $\log_a$ be the D866: Standard real logarithm function in base $a \in (0, \infty) \setminus \{ 1 \}$.
(i) | \begin{equation} \forall \, x \in \mathcal{X} : p(x) : = \mathbb{P}(X = x) \end{equation} |
(ii) | \begin{equation} \forall \, x \in \mathcal{X} : q(x) : = \mathbb{P}(Y = x) \end{equation} |
Then
\begin{equation}
\sum_{x \in \mathcal{X}} p(x) \log_a \frac{p(x)}{q(x)}
= - \sum_{x \in \mathcal{X}} p(x) \log_a \frac{q(x)}{p(x)}
\end{equation}