Checking for errors.
$$ log \left (\frac {W} {W_{max}} \right) = -H log \left (\frac {h} {\frac {N} {2}} \right ) - T log \left (\frac {T} {\frac {N} {2}} \right ) /$$
$$ \alpha = \frac {(H - T)} {N} /$$
$$ H = \left (\frac {N} {2} \right ) (1 + \alpha ) /$$
$$ T = \left (\frac {N} {2} \right ) (1 - \alpha) /$$
$$ \frac {W} {W_{max}} = e^{-N \alpha ^{2}} /$$
$$ ln \left (\frac {W} {W_{max}} \right ) = - \left (\frac {N} {2} \right ) (1 + \alpha) ln (1 + \alpha) - \left (\frac {N} {2} \right ) (1 - \alpha) ln (1 - \alpha) /$$
$$ ln \left (\frac {W} {W_{max}} \right ) = - \left (\frac {N} {2} \right) (1 + \alpha) ln (1 - \alpha ^{2}) + N \alpha ln (1 - \alpha) /$$
$$ W = frac\ {N!} {\prod_{n} a_{n}!} /$$
$$ P_{dc} = \frac {W_dc} {\sum_{n} W_{n}} /$$