Random functions family
-
Hi, Would you give me an example of FAMILIES of functions that I could use in a Hashtable? Notice that I need a FAMILY of functions (that means it should depend on some random constants previously defined) It should go from {0, K} to {0, m} Im trying f(x) = (a*x + b) % prime % m where prime is larger than x, a is between 1 and prime-1, and b is between 0 and prime-1 But its not good enough.. Dunno why though
-
Hi, Would you give me an example of FAMILIES of functions that I could use in a Hashtable? Notice that I need a FAMILY of functions (that means it should depend on some random constants previously defined) It should go from {0, K} to {0, m} Im trying f(x) = (a*x + b) % prime % m where prime is larger than x, a is between 1 and prime-1, and b is between 0 and prime-1 But its not good enough.. Dunno why though
Quake2Player wrote:
Would you give me an example of FAMILIES of functions that I could use in a Hashtable?
Example: SHA family[^]. This family and additional hash function implementations can be found here[^]. Also you can find some different hash function implementations here[^]. Regards, Nuri Ismail