Calculates the normalization of a vector.