implemented entropy calculation

normalization constant of the discrete variational variable
converges to 1 for the test case, and for the real data it
is close to zero, making the entropy diverge. why is this?