The Shannon Entropy of a text T containing a set of characters C is defined as: where and f req(c) is the number of times c appears in T .
mE is the Shannon entropy divided by the text length, len(T ).