# Subtraction of two non-homogenous monomial in a non-commutative ring

asked 2013-10-07 04:11:34 -0500 This post is a wiki. Anyone with karma >750 is welcome to improve it.

Hi every one,

I have a problem for subtracting two non-homogenous monomial "xyyx-xyx" in a unital associative free algebra with two generators x&y.

The error which is appeared is "ArithmaticError : can only subtract the elements of the same degree".

I will apreciate some one who tell me what is the soloution.

Thanks

Abdolrasoul

edit retag close merge delete

Actually the problem is here:

F.<x,y> = FreeAlgebra(QQ, implementation='letterplace') I=F[xyx-2xy]*F J=F.quo(I)

And the eroor is :

ArithmaticError : can only subtract the elements of the same degree"

Sort by » oldest newest most voted

answered 2013-10-08 04:03:43 -0500 This post is a wiki. Anyone with karma >750 is welcome to improve it.

The docstring of FreeAlgebra says

By http://trac.sagemath.org/7797, we provide a different implementation of free algebras, based on Singular's "letterplace rings". Our letterplace wrapper allows for chosing positive integral degree weights for the generators of the free algebra. However, only (weighted) homogenous elements are supported. Of course, isomorphic algebras in different implementations are not identical:

If you drop the implementation='letterplace' option, the ArithmeticError disappears:

sage: F.<x,y> = FreeAlgebra(QQ)
sage: x*y*x + 2*x*y
2*x*y + x*y*x

more

But I need an unital associative free algebra and if I drop the "implementation= 'letterplace", it just give me free algebra.

Please use comments instead of "your answer". Maybe I am misunderstanding something, but how is the free algebra over QQ not unital?

Maybe I miss understood the definition of free algebra. When I put F.<x,y>=FreeAlgebra(QQ) "Sage" write me "Free Algebra en two generators x,y"" and when I write F.<x,y>=FreeAlgebra(QQ, implementation='letterplace') it gives me "Unital associative free algebra with two generators", but I think the both is the same, yes? Now, my problem is to construct a quotient of this algebra ba a non-homogenous ideal. Do you know, how can I do that?

See the example in the documentation by typing F.quo?