ADS
Algorithms and Data Structures
Loading...
Searching...
No Matches
ADS::PlaceHash Concept Reference

a hash \( H \) that maps a key straight to a place of a table of \( m = 2^d \) places by h.place( k , m ), as the multiplicative hashing of section 5.1.1 of Morin's book and the tabulation hashing of its section 5.2.3 do with the \( d \) most significant bits of a product or of a XOR [see MultiplicativeHash in UniversalHashing.h and TabulationHash in RandomHashing.h]; the tables use it in place of \( h( k ) \bmod m \), whose low bits are the worst ones of a product More...

#include <ADS/dictionary/TableSize.h>

Concept definition

template< class H , class K >
concept PlaceHash = requires( const H & h , const K & k , std::size_t m )
{
{ h.place( k , m ) } -> std::convertible_to< std::size_t >;
}
a hash that maps a key straight to a place of a table of places by h.place( k , m ),...
Definition TableSize.h:96

Detailed description

a hash \( H \) that maps a key straight to a place of a table of \( m = 2^d \) places by h.place( k , m ), as the multiplicative hashing of section 5.1.1 of Morin's book and the tabulation hashing of its section 5.2.3 do with the \( d \) most significant bits of a product or of a XOR [see MultiplicativeHash in UniversalHashing.h and TabulationHash in RandomHashing.h]; the tables use it in place of \( h( k ) \bmod m \), whose low bits are the worst ones of a product