Probability of message A, p1=0.4
Probability of message A, p2=0.3
Probability of message A, p3=0.3
Total messsages L=100
Total information
Itotal=p1Llog2p11+p2Llog2p21+p3Llog2p31
=(0.4)(100)log20.41+(0.3)(100)log20.31+(0.3)(100)log20.31
=40×1.32+30×1.735+30×1.735
=52.8+52.06+52.06=156.92 bits
Entropy =LItotal=100156.92=1.5692bits
Comments
Leave a comment