11.07.2015 Views

Cryptography - Sage

Cryptography - Sage

Cryptography - Sage

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

In order to understand naturally occurring languages, we consider the models for finitelanguages X consisting of strings of fixed finite length N together with a probability functionP which models the natural language. In what follows, for two strings x and y wedenote their concatenation by xy.Exercise 4.1 Show that N is the maximum entropy for a probability function on bit stringsof length N.Solution.None provided.Exercise 4.2 Show that the rate of a uniform probability space is 1 and that this is themaximal value for any probability space.Solution.None provided.Exercise 4.3 For a given cryptosystem, show that the definitionP (y) = ∑ K∈KP (K) ∑ P (x).x∈ME K (x)=ydetermines a probability function on the ciphertext space. Then verify the equalities:P (y) = ∑ x∈MP (x, y), and P (x) = ∑ y∈CP (x, y).Solution.None provided.Exercise 4.4 Consider the language of 1-character strings over {A, B, C, D} with associatedprobabilities 1/3, 1/12, 1/4, and 1/3. What is its corresponding entropy?Solution.The entropy of the language iswhich is approximately 1.855.13 log 2(3) + 1 12 log 2(12) + 1 4 log 2(4) + 1 3 log 2(3)= 2 3 log 2(3) + 1 12 (2 + log 2(3)) + 1 2 = 2 3 + 3 4 log 2(3),Exercise 4.5 Consider the language X 2 of all strings of length 2 in {A, B, C, D} defined bythe probability function of Exercise 1 and 2-character independence: P (xy) = P (x)P (y).What is the entropy of this language?112 Appendix C. Solutions to Exercises

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!