wolftype / versor

Versor Geometric Algebra Library
wolftype.github.io/versor/devel/html/
291 stars 47 forks source link

Rotor type only is correct for at maximum 3 dimensions #22

Open porky11 opened 7 years ago

porky11 commented 7 years ago

for heigher dimeinsions, rotors just cover simple rotors (products of vectors), not products of bivectors, as they should (for example in 4d, there is no pseudoscalar in the rotor type) This isn't a problem in code, when using auto, but if you want to create a 4d object, that has a rotation:

struct object {
    vector pos;
    rotor rot;
}
wolftype commented 7 years ago

This is an interesting point. While one could define such a type: using Rotor_ = decltype ( Bivector() * Bivector()) I can see it being useful to have a GeneralRotor type built-in, in addition to the scalar + bivector Rotor. I'd rather not change the meaning of Rotor itself -- that is, I'd rather keep them simple. The question is what to call the product of Bivectors version. Perhaps GeneralRotor. Thoughts?

porky11 commented 7 years ago

Problem: The Product of bivectors is not a general rotor for arbitrary dimensions. I'd prefer to call the general rotor Rotor, because that's what rotors are normally called. The simple rotors may be called SimpleRotor for efficiency reasons, but in such case, using auto type seems more useful. I don't think, this would cause problems. But GeneralRotor also sounds ok. Having arbitrary subalgebras may also be useful (even grade (which are rotors) or other factors) if possible.