6 ms·
All triangles are 2d. Using atan2 to find the angle between 3d vectors would require projection onto an orthonormal basis. atan2 requires this even in 2d, we j
by jjaredsimpson 9y ago
All triangles are 2d. Using atan2 to find the angle between 3d vectors would require projection onto an orthonormal basis.
atan2 requires this even in 2d, we just assume the natural basis and assume the other vector is x hat.
Dot product avoids all this in any dimension.
- paulddraper 9y agoJust as atan2() returns 1 angle (XY), atan3() would return 2 angles (XY, XZ). I agree dot product is often better, for other reasons.
- jjaredsimpson 9y agoI don't follow what this hypothetical atan3 implements?