next up previous
Next: Up: Previous:

Universal Hashing

Any fixed hash function will have $\Theta(n)$ worst case time.

*
Choose hash function randomly, independent of the keys to be stored.
*
Choice at run time prevents worst case behavior on multiple runs.



Suppose we want the hash function to uniformly distribute hash values over the hash table of size m.

Given h(x), we want P(h(x) = h(y)) = 1/m.


next up previous
Next: Up: Previous: