By: nobody ( Nobody/Anonymous )
Error in Quaternion to AxisAngle
I think that you have an error in you Quaternion to AxisAngle derivation... Your code is right, but in the derivation, you are not doing the samething as in the proof! :-(
I think the bug came from the page AxisAngle to Quaternion... where the code is wrong (at least, if you look at your definition of quaternions)!! You should have ('multiply s' instead of 'divide by s'):
double s = Math.sin(a1.angle/2);
x = a1.x * s; y = a1.y * s; z = a1.z * s; w = Math.cos(a1.angle/2);
By: martinbaker ( Martin Baker )
RE: Error in Quaternion to AxisAngle
Thank you very much for letting me know about this, I have corrected it as you suggested.
|Correspondence about this page|
Book Shop - Further reading.
Where I can, I have put links to Amazon for books that are relevant to the subject, click on the appropriate country flag to get more details of the book or to buy it from them.
This site may have errors. Don't use for critical systems.