nerdamer
nerdamer copied to clipboard
7-dimensional cross products
Right now, the cross function returns 0 for all non-three-dimensional vectors. The cross product is defined for 0-dimensional vectors (returns the zero vector), 1-dimensional vectors (returns the zero vector), 3-dimensional vectors (returns a 3-dimensional vector) and 7-dimensional vectors (returns a 7-dimensional vector). The 7-dimensional cross product is missing.
Any examples for this one?
@Happypig375 Suggestions? Examples? Anything?
Ref: https://en.wikipedia.org/wiki/Seven-dimensional_cross_product
- Set an setting for the basis vector (product of [1, 0, 0, 0, 0, 0, 0] and [0, 1, 0, 0, 0, 0, 0, 0] Something like a setting called BASIS_VECTOR, like [0, 0, 1, 0, 0, 0, 0]
- Generate multiplication table
Now if BASIS_VECTOR is [0, 0, 1, 0, 0, 0, 0], cross([0, 1, 0, 0, 0, 0, 0],[0, 0, 0, 0, 0, 0, 1]) => [0, 0, 0, 0, -1, 0, 0]