Skip to content

.is_versor() method in class Mv of module mv.py uses an incorrect algorithm #533

@Greg1950

Description

@Greg1950

The multivector method .is_versor() purports to follow the test on p. 533 of Leo Dorst's Geometric Algebra for Computer Science. But:

  1. Dorst's test itself, as it appears in GACS, is incorrect, as shown by a simple counterexample.
  2. The algorithm used in .is_versor() does not faithfully implement Dorst's test.
  3. The algorithm used in .is_versor() has a simple counterexample.

I have devised four conditions satisfied by versors which, if satisfied, also imply that a multivector is a versor. I am currently checking with Dorst as to his opinion, but I'm pretty confident in my reasoning.

Let V be a multivector, and let V.rev() and V.g_invol() be its reverse and grade involute. Let x be a generic 1-vector. Then V will be a versor if and only if it meets each of the following conditions:

  1. V * V.rev() and V.rev() * V are both scalars.
  2. V * V.rev() is not zero.
  3. V.g_invol() * V.rev() is a scalar.
  4. V.g_invol() * x * V.rev() is a vector.

The counterexamples, if anyone's interested, are these:

  • To Dorst's test as it appears in GACS: Let V = 1 + I where I = e0 e1 e2 e3 is the unit pseudoscalar of the spacetime algebra G(1,3). Then V meets the conditions described by GACS, but the geometric product V (reverse of V) is not a scalar, showing that V cannot be a versor.
  • To the algorithm currently used in .is_versor(): Let V = e1 + e2 e3 in the algebra G(3,0) of Euclidean 3-space. Then V passes the test in .is_versor(), but V cannot be a versor as it is a mixture of odd and even grades.

I will post further after hearing back from Dorst. In the meanwhile, I have a proposed rewrite of the .is_versor() method that I am testing. Once my testing is satisfied, I'll post my rewrite here.

Greg Grunberg
[email protected]
2025 March 04

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions