chickadee » bloom-filter » make-bloom-filter

make-bloom-filter M MDPS #!optional Kprocedure

Returns a bloom-filter object with M bits of discrimination and a set of hash functions built from the supplied MDPS, a (list-of message-digest-primitive) objects.

The number of hashes, K, is not necessarily the same as the number of message-digests. A hash (here) is defined as an unsigned 32 bit integer. Most message-digests return more 32 bits of hash. The actual length of the hash is divided into 32 bit blocks to get the individual hashes.

The argument K will restrict the actual number of hashes to the "first" K, no matter how many more the supplied message-digests create. First in the order of MDPS.