Dot product
Yup. The maximum dot product of any two vectors is the product of their magnitudes, and normalized vectors, of course, have magnitude 1.
How appropriate. You fight like a cow.
How appropriate. You fight like a cow.
quote:
Original post by Briskon
Is the maximum value of the dot product of two noramlized vectors 1?
In theory yes. But in practice it can give a result > 1 due to FP rounding errors, so if your code depends on it being <= it might fail. For example one common use for the inner product is to find the angle between two vectors, using
angle = acos(dot(vec1, vec2));
But this can crash depending on how the acos function handles values greater than 1.
John BlackburneProgrammer, The Pitbull Syndicate
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement