# How to generate Cayley table?

Given positive, negative and zero number, how to generate a Cayley table?

This is how you would do it with Grassmann.jl v0.8

``````julia> using Grassmann

julia> cayley(S"+++")
v     vβ      vβ    vβ    vββ     vββ    vββ   vβββ
vβ     1v     vββ   vββ    1vβ     1vβ   vβββ   1vββ
vβ  -1vββ      1v   vββ   -1vβ  -1vβββ    1vβ  -1vββ
vβ  -1vββ   -1vββ    1v   vβββ    -1vβ   -1vβ   1vββ
vββ   -1vβ     1vβ  vβββ    -1v   -1vββ   1vββ   -1vβ
vββ   -1vβ  -1vβββ   1vβ   1vββ     -1v  -1vββ    1vβ
vββ   vβββ    -1vβ   1vβ  -1vββ    1vββ    -1v   -1vβ
vβββ   1vββ   -1vββ  1vββ   -1vβ     1vβ   -1vβ    -1v
``````

Where `cayley(::Signature)` takes any `Signature` as an argument (e.g. `S"+++"` or `S"-+++"`).

1 Like

Thanks, but how to do this without a library in arbitrary language? What is algorithm?

Whatβs the difference between v and 1v? And what does other cases of 1-prefixing mean?

Consider \{t_j\}_{j=1}^{2^n} = \{1, v_1, v_2, \dots, v_n, v_{12}, \dots, v_{12\dots n} \}, then t_{j,k} := t_jt_k (geometric product).

A prefix of one means multiplication by the integer 1, which is an identity operation, so v = 1v.

I donβt understand.

How to know the result of t_jt_k?

Itβs the geometric product of t_j and t_k, the definition of which depends on the choice of metric tensor.