The set of linear polynomials in L.cache.mbRing, see mbRing, gives a representation of the elements in the Lie algebra L. The function defLie gives back the standard output and indexFormLie goes in the other direction.
i1 : L = lieAlgebra{a,b}
o1 = L
o1 : LieAlgebra
|
i2 : b3 = basisLie 3
o2 = {(a b a), (b b a)}
o2 : List
|
i3 : Q = L.cache.mbRing o3 = Q o3 : PolynomialRing |
i4 : gens Q
o4 = {mb , mb , mb , mb , mb }
{1, 0} {1, 1} {2, 0} {3, 0} {3, 1}
o4 : List
|
i5 : c3 = indexFormLie b3
o5 = {mb , mb }
{3, 0} {3, 1}
o5 : List
|
i6 : defLie indexFormLie a a b o6 = - (a b a) o6 : L |
i7 : defLie mb_{3,0}
o7 = (a b a)
o7 : L
|
i8 : defLie (mb_{3,0}+2*mb_{3,1})
o8 = (a b a) + 2 (b b a)
o8 : L
|
i9 : indexFormLie oo
o9 = mb + 2mb
{3, 0} {3, 1}
o9 : Q
|