Avoid singularaties in Rotation Matrix