Question

Topic: Discrete Mathematics and its Applications" Chapter 9:Equivalence Relations and Partial Orderings.

9. hash function H : {0,1) → {0,1) maps a bit string of length n to a bit string of length k. Hash functions are used to give a short label to a long string. The set of all collisions with a given string s defines an equivalence class for a given hash function H, that is: (a) What is the average cardinality of the equivalence classes [s]H in terms of n and k, where n > k? (b) What is the probability for any two random bit strings from s,te { 0, 1 }n that

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Answer to (a):

The number different binary string of length n = 2n and the number different binary string of length k = 2k

So we need to map 2n strings to 2k strings.

When n > k, then each of 2k strings will be mapped on average by 2n/2k strings out of 2n strings.

Therefore, the average cardinality of the equivalence class [s]H = 2n/2k = 2n-k

Answer to (b):

The number of equivalence class = 2k

So the probability of a random string t \epsilon \{0,1\}^n to be a member of a particular equivalence class = 1/2k = 2-k

Therefore, the probability for any two random strings s,t \epsilon \{0,1\}^n such that [s]H = [t]H= 2-k

NB: Hope it helps to get your answer. Let me know any concern.

Add a comment
Know the answer?
Add Answer to:
Topic: Discrete Mathematics and its Applications" Chapter 9:Equivalence Relations and Partial Orderings. 9. hash function H...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 0. Introduction. This involves designing a perfect hash function for a small set of strings. It...

    0. Introduction. This involves designing a perfect hash function for a small set of strings. It demonstrates that if the set of possible keys is small, then a perfect hash function need not be hard to design, or hard to understand. 1. Theory. A hash table is an array that associates keys with values. A hash function takes a key as its argument, and returns an index in the array. The object that appears at the index is the key’s...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT