Universal enveloping algebra over the complex numbers
In the documentation there is an example of defining the universal enveloping algebra of a lie algebra L, with the multiplication being *. However, this works only over the field of rationals QQ. How would one instead do this over the field of complex numbers CC?
L = LieAlgebra(QQ, {('e','h'): {'e':-2}, ('f','h'): {'f':2},
('e','f'): {'h':1}}, names='e,f,h')
e,f,h = L.lie_algebra_generators()
L.bracket(h, e)
2*e
elt = h*e; elt
e*h + 2*e
Our setting for free modules does not not like inexact coefficient rings. Try using
SR
orQQbar
or some number field or whatever precise ring you need as coefficients.Would it be possible for you to elaborate? When I try to use QQbar I get the error "TypeError: Illegal initializer for algebraic number". While using SR I get the error "AttributeError: 'LieAlgebraWithStructureCoefficients_with_category' object has no attribute 'lift'".
Indeed. Some things need to be fixed.
Can you do anything with
L.pbw_basis()
?Thanks that works, L.pbw_basis() works with QQbar.