# Calculations in quotient of a free algebra

I want to define (the algebra part of) Sweedler's four-dimensional Hopf algebra, which is freely generated by $x,y$ and subject to the relations $$x^2 = 1, \qquad y^2 = 0, \qquad x\cdot y = - y\cdot x~ ,$$ but I don't see how to do it.

I have tried the following:

sage: A.<x,y> = FreeAlgebra(QQbar)
sage: I = A*[x*x - 1, y*y, x*y + y*x]*A
sage: H.<x,y> = A.quo(I)
sage: H
Quotient of Free Algebra on 2 generators (x, y) over Algebraic Field by the ideal (-1 + x^2, y^2, x*y + y*x)


But then I get

sage: H.one() == H(x*x)
False


So is this currently possibly using a different method?

Thanks

edit retag close merge delete

Sort by » oldest newest most voted

This is definitely a bug, thanks for reporting ! This is now trac ticket 24808.

more

I know now that we can do the following:

sage: A = FreeAlgebra(QQbar, 3, "a")
sage: F = A.monoid()
sage: M = MatrixSpace(QQbar,4)
sage: x, y, xy = F.gens()
sage: mons = [F(1), x, y, xy]
sage: mats = [
....:        M([ 0, 1, 0, 0,   1, 0, 0, 0,   0, 0, 0, -1,   0, 0, -1, 0 ]),
....:        M([ 0, 0, 1, 0,   0, 0, 0, 1,   0, 0, 0, 0,   0, 0, 0, 0]),
....:        M([ 0, 0, 0, 1,   0, 0, 1, 0,   0, 0, 0, 0,   0, 0, 0, 0 ])
....: ]
sage: H.<x,y,xy> = FreeAlgebraQuotient(A,mons,mats); H
Free algebra quotient on 3 generators ('x', 'y', 'xy') and dimension 4 over Algebraic Field


And we can verify

sage: x^2
1
sage: y^2
0
sage: x*y
xy
sage: y*x
-xy


Note: We cannot take tensor products, but that is not what I originally asked for, so.

more