pystran.rotation module#
Define rotation utilities.
- pystran.rotation.rotate(i, j, v, angleindegrees)[source]#
Rotate a 3D vector
v
by an angle about the unit vector defined by jointsi
andj
.- Parameters:
i – First joint.
j – Second joint.
v – Vector to be rotated. Can be supplied as a list, tuple, or array.
angleindegrees – Angle in degrees. Positive when counterclockwise about the vector
j["coordinates"] - i["coordinates"]
.
- Returns:
Rotated vector
v
.- Return type:
array