API

GeometricAlgebra.:⋅Function
x ⋅ y

Inner product of x with y. This product is in general non-associative, and is conventinally executed right to left in absence of parenthesis. For example, A ⋅ B ⋅ C == A ⋅ (B ⋅ C), and in most cases, A ⋅ B ⋅ C ≠ (A ⋅ B) ⋅ C.

source
GeometricAlgebra.@basisMacro
@basis <signature> [prefix=v, export_symbols=true, export_metadata=true, export_pseudoscalar=true, modname=GeneratedGA]

Create a module modname, fill it with all unit blade symbols from a geometric algebra with a given signature prefixed with prefix, and import it with using. The exported variables depend on the options export_symbols and export_metadata. If export_symbols is true, then all unit blade symbols are exported. If export_metadata is true, then the following symbols are exported:

  • N: the dimension of the algebra
  • TABLE: the table containing precomputed values for blade products
  • SIGNATURE: the signature used to build the algebra
  • MultivectorArray: a concrete multivector array representation, with 2^N coefficients.

If export_pseudoscalar is true, then the alias I = v₁...ₙ will be exported.

Examples

To obtain the unit blades of 𝒢(ℝ³) the geometric algebra over the 3-dimensional vector space ℝ³, you just have to specify a positive signature with "+++":

julia> @basis "+++" # v is the default prefix

To bind the blades to variables with different prefix than the default v, just add the prefix after the signature:

julia> @basis "+++" prefix=g # assigned variables will be g, g1, g12...
source