Shannon entropy - use to calculate the bit needed to encode a symbol

AI Thread Summary
To encode a symbol in binary, 3 bits are needed for 6 symbols, totaling 18 bits for the phrase "We are." However, since not all 8 possible symbols are used, less than 3 bits on average can be utilized for encoding. The encoding of specific symbols, like "W," is flexible and can be represented in various ways, as long as a corresponding table is provided. Resources for further reading on this topic can be found in textbooks and numerous online platforms. Understanding Shannon entropy is crucial for optimizing the bit usage in encoding symbols.
Outrageous
Messages
373
Reaction score
0
To encode a symbol in binary form, I need 3 bits ,and I have 6 symbols.
So I need 6*3=18 bits to encode "We are" into binary form. As shown in http://www.shannonentropy.netmark.pl/calculate
My question: 3 bits to encode one then I have to use 16 bits, _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _.
How to encode"W" into _ _ _ ? The _ _ _ is filled by 1 or 0 .
3 bits is calculated from entropy And what is that relate to the entropy? Please help. Really appreciate.
 
Physics news on Phys.org
You need less than 3 bits on average, as you do not use all 8 symbols you could encode with 3 bits. For example, you can choose one symbol and encode it with just two bits (this "blocks" two 3-bit-strings).

How to encode"W" into _ _ _ ?
That is completely your choice. Pick anything you like, just provide a table where you describe the encoded symbols.

I moved your thread to our homework section.
 
mfb said:
You need less than 3 bits on average, as you do not use all 8 symbols you could encode with 3 bits. For example, you can choose one symbol and encode it with just two bits (this "blocks" two 3-bit-strings).

That is completely your choice. Pick anything you like, just provide a table where you describe the encoded symbols.

I moved your thread to our homework section.
Thanks. Can you please give me some simple links to read? Please
 
I don't have links, but every textbook and a lot of websites should cover that.
 
Back
Top