clifford.MultiVector

class clifford.MultiVector(layout, value=None, string=None)

An element of the algebra

Parameters:
  • layout (instance of clifford.Layout) – the layout of the algebra
  • value (sequence of length layout.gaDims) – the coefficients of the base blades

Notes

The following operators are overloaded as follows:

    • : geometric product
  • ^ : outer product

  • : inner product
  • ~ : reversion

  • ||: abs value, this is sqrt(abs(~M*M))

sequence method

  • M(N) : grade or subspace projection
  • M[N] : blade projection

Attributes

blades_list ordered list of blades present in this MV
even Even part of this mulivector
odd Odd part of this mulivector

Methods

__init__ Constructor.
adjoint Adjoint / reversion _ ~M –> M (any one of several conflicting notations) ~(N * M) –> ~M * ~N adjoint() –> MultiVector
anticommutator Returns the anti-commutator product of two multivectors.
basis Finds a vector basis of this subspace.
clean Sets coefficients whose absolute value is < eps to exactly 0.
commutator Returns the commutator product of two multivectors.
conjugate Returns the Clifford conjugate (reversion and grade involution).
dual Returns the dual of the multivector against the given subspace I.
gradeInvol Returns the grade involution of the multivector.
grades Return the grades contained in the multivector.
inv Return right-inverse using a computational linear algebra method proposed by Christian Perwass.
invPS Returns the inverse of the pseudoscalar of the algebra.
isBlade Returns true if multivector is a blade.
isScalar Returns true iff self is a scalar.
join Returns the join of two blades.
lc Returns the left-contraction of two multivectors.
leftInv Return left-inverse using a computational linear algebra method proposed by Christian Perwass.
leftLaInv Return left-inverse using a computational linear algebra method proposed by Christian Perwass.
mag2 Magnitude (modulus) squared 2 |M| mag2() –> PyFloat | PyInt
meet Returns the meet of two blades.
normal Return the (mostly) normalized multivector.
normalInv Returns the inverse of itself if M*~M == |M|**2.-1 M = ~M / (M * ~M) normalInv() –> MultiVector.
project Projects the multivector onto the subspace represented by this blade.
pseudoScalar Returns a MultiVector that is the pseudoscalar of this space.
rightInv Return right-inverse using a computational linear algebra method proposed by Christian Perwass.
rightLaInv Return right-inverse using a computational linear algebra method proposed by Christian Perwass.
round Rounds all coefficients according to Python’s rounding rules.
x Returns the commutator product of two multivectors.