Another attempt at matrix hashing.