# Approximating binomials with normals

If I have two random variables with a binomial distribution, such as:

\begin{aligned} X &\sim \text{Binom}\left(K, a\right) \\ Y &\sim \text{Binom}\left(K, b\right), \end{aligned}

what is the expection

$$\mathbb{E}\left[|bX-aY|\right]?$$

For a large enough $K$, let’s use the CLT and approximate $X$ and $Y$ with $X_p$ and $Y_p$, respectively:

\begin{align} X_p &\sim \mathcal{N}\left(Ka, Ka(1-a)\right)\\ Y_p &\sim \mathcal{N}\left(Kb, Kb(1-b)\right). \end{align}

Let’s take as an example $K=200, a=0.2, b=0.7$. As illustrated below:

This implies that $bX-aY$ has a distribution $\mathcal{N}\left(0, \sigma^2\right)$, whith $\sigma^2$:

$$\sigma^2 = Kab(a+b-2ab).$$

We can then calcualte the expectation as:

$$\mathbb{E}\left[bX-aY\right] = \sqrt{\frac{2}{\pi}\sigma}=\sqrt{\frac{2Kab}{\pi}(a+b-2ab)}.$$