Working kld and entropy, now needs testing