Import linear hashes from tommyhash.

The original algorithm version can be found here:
http://tommyds.sourceforge.net/