Abstract

We present an algorithm for constructing a perfect word hash function for n integers that takes O(n4log⁡n) time. This time is independent of size of the integers or the number of bits in the integers. We call it a word hash function because we require that the hash function can hash multiple integers packed in a word in constant time. Previous algorithms for constructing a perfect word hash function have time dependent on the number of the bits in integers. Although an O(n(log⁡log⁡n)2) time algorithm is known for constructing a perfect hash function, the hash function constructed is not a word hash function and it cannot hash multiple integers packed in one word in constant time. The property of word hashing is indispensable in the current best deterministic and randomized algorithms for integer sorting. Our result is achieved via an algorithm of O(n2log2⁡n) time that computes the shift distances for integers of Ω(n2log⁡n) bits. These shift distances can then be used to pack the extracted bits of each integer to O(n) bits. Perfect word hash function constructed with our method using these shift distances allows a batch of mn integers with m integers packed in a word to be hashed in O(n) time.

Full Text
Paper version not known

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.