Git Product home page Git Product logo

Comments (2)

moble avatar moble commented on September 15, 2024

I strenuously object to using "conventional" names for identifying any conventions, because even the names are ambiguous, uninformative, and very easy to misinterpret. My advice, as always, is to understand the relationships between different quantities, which is what I actually try to document. For example, see the docstrings of as_rotation_matrix and from_rotation_matrix, which specify that the rotation matrix m acts in the same way as the quaternion q such that

m @ v.vec == q * v * q.conjugate()

Or the docstring of rotate_vectors, which specifies that a quaternion R acts on a vector v to produce a new vector as

vprime = R * v * R.conjugate()

But the meaning of that relationship depends on what R represents: a change of basis or a physical rotation. Therefore, fundamentally and unavoidably, the way you think of those relationships — and how you name them — is up to you.

Moreover, most of this package doesn't actually deal with rotations. In fact, off the top of my head, those are the only three functions that actually deal with applying rotations per se. The Euler-angle functions, for example, only produce quaternions from a set of angles; they don't apply any quaternions. And again in those cases, all I do is document the relationship between those angles and the quaternion. And of course, that's another example where people have repeatedly asked me to identify the convention with names including "active" and "passive" — though with completely different meaning to your usages above.

IMO, using names like these only misleads, and makes the complete and utter mess of conventions combinatorically worse.

from quaternion.

scottshambaugh avatar scottshambaugh commented on September 15, 2024

Point taken on the mathematical definitions being the source of truth, but for all the verbiage about Euler angles being bad some language on anticipating this (IMO rather more insidious) footgun would be much appreciated. I'll also note that the Shuster convention talked about in those papers changes the definition of quaternion multiplication itself, so that i * j = -k rather than +k. I don't see the multiplication definition called out in the docs right now.
(discussed a bit previously in #96)

from quaternion.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.