(Solved) : 5 5 Let E1 E2 Two Independent Flips Fair Coin Find Entropy H E1 Joint Entropy H E1 E2 H E Q44085297 . . .
5. [5] Let E1 and E2 be two independent flips of a fair coin.Find the entropy H(E1) and joint entropy H(E1,E2). Why isH(E1,E2)=H(E1)+H(E2)?
1. Consider modifying the experiment in 5 above so that either1) the coin is loaded OR 2) you only flip a second time when thefirst flip is heads, when tails you assign the value of the flip E2to be tails. Which modification of the experiment (1 or 2) willmake it so that H(E1,E2) < H(E1)+H(E2) ? Will one of them makeit so H(E1,E2) > H(E1)+H(E2) ?
2. Let X be a random variable that takes on integer values. Theprobability is ½ that X will be in the range [0,24-1] with allvalues in that range being equally likely. The rest of the time, itwill be in the range [24,28-1], again with uniform probability.What is the entropy H(X)? (Estimation is OK).
3. A bag contains 7 red balls, 2 green balls, and 1 blackball.
a. You choose 2 balls from the bag with replacement (i.e. you putthe first ball back in and shake before drawing the second). Whatis the entropy of the experiment?
b. You choose 2 balls from the bag without replacement (i.e. youkeep the first ball while drawing the second). How is youruncertainty affected now that you know the color of the first ballbefore drawing the second? What is the entropy of this newexperiment given the first ball you choose is red?
4. Write a small program that loads in a text file of any sizeand then prints the frequency (as a percentage) of each character(‘a’..’z’). All characters should be made lowercase for countingpurposes. Ignore punctuation, spaces, etc. Output should be sortedin decreasing frequency order (e, t, a, o, etc.) and look somethinglike:
‘e’ – 13.27%
‘t’ – 9.11%
‘a’ – 8.47%
‘o’ – 7.32%
…
‘q’ – 0.01%
‘z’ – 0.00%
Attach a printout of your code to your submission. Also, attach aprintout of your code applied to THIS HANDOUT (ie: submit ascreenshot of your results after analyzing the HW1 document). Youmay want to copy/paste the contents of this file into Notepad tocreate a text file your program can read.
use C++ language Program
Use C++ language program
Expert Answer
Answer to 5. [5] Let E1 and E2 be two independent flips of a fair coin. Find the entropy H(E1) and joint entropy H(E1,E2). Why is …
OR