[This page is auto-generated; please prefer to read the articleβs PDF Form.]
Consider a π-Universal class β of H functions, mapping U to β€m. Say we are given a set S of n keys from U. Are there any functions in β which give no collision for all keys in S? We will refer to such functions as βCollision-Freeβ for S. So, these functions map the n distinct keys to n distinct values of β€m. Such a function would exist only if |β€m|β₯|S|, i.e. m β₯ n.
The deο¬nition of π-Universal class provides an upper bound of πH on the number of functions where any key pair would collide. We can form key pairs from S. Thus, the maximum number of functions where any of these pairs can collide is:
| (1) |
Note that this is only an upper-bound and can even exceed the available functions count of H. The subset of functions where a pair collides may overlap with the subset of functions where some other pair collides. Since above we simply added maximum size of each such subset (i.e. πH), once for each pair, this upper bound may be loose.
Based on (1), the minimum number of functions in β which must be collision-free for S, if πH β€ H:
|
So, the minimum proportion of such functions in β:
| (2) |
Although (2) need not provide a tight lower bound on the proportion of functions which are collision-free for a given set of n keys, it can still be useful. It relates the lower-bound Ξ± to π, and it may be possible to adjust the parameters of the universal class to achieve certain π. For example, for a 1βm-Universal class, π = 1βm can be modiο¬ed by simply modifying the table-size m.
Suppose we want to ensure the lower bound Ξ± is at least 1/2; so at least half of the functions in β are collision-free for a given set of n keys. Then (2) gives:
| (3) |
For any 1βm-Universal class, (3) becomes:
|
And for 2βm-Universal class, (3) becomes:
|
To make Ξ± at least f β (0,1), we need:
|
Theorem 1. Given π-Universal class β and any set of n keys, the proportion of functions in β which are collision-free for those keys is at least f β (0,1) if:
|
Corollary 2. Given π-Universal class β with π = 1βm, and any set of n keys, at least half of the functions in β are collision-free for those keys if: m β₯ n(n β 1). For π = 2βm, this condition is: m β₯ 2n(n β 1).
Copyright © 2021 Nitin Verma. All rights reserved.