Good way to hash a float vector?
I am well aware of all the problems involved in comparing floats. This is exactly the reason for this question. I'm looking to create a fast hash table for values that are 3D vectors (3 floats - x,y,z). It can be assumed that the length of the vector is always 1.0 ( sqrt(x*x+y*y+z*z) is 1.0) Essentially this means that I'm looking for a hash function that takes values that are almost equal to the same unsigned int value and a corresponding equality operator that is true if the hash values are equal (not not necessarily only if they are equal) Edit - False positives (i.e. vectors that are