Unstable behavior in vector_vector_rotation

Issue #3 closed
Matthew Spellings created an issue

When given two vectors that are opposite each other, vector_vector_rotation fails due to the degeneracy of that operation. I think people typically check whether the dot product is close to +- 1 and use a special case for that.

>>> import rowan
>>> rowan.vector_vector_rotation((0, 0, 1), (0, 0, -1))
array([6.123234e-17,          nan,          nan,          nan])

Comments (2)

  1. Log in to comment