Generating a certain list of non-commuting polynomials with Sage
I have a set of variables x1,...,xn and y1,...,ym for n,m>=1.
Now I can build all quadratic monomials of the form xiyj and yjxi (but we do not have xiyj=yjxi as we calcualte in the non-commutative polynomial ring). But something like xixj is not allowed as after an xi there must come an yj and after an yi there must come an xi.
Now I want with Sage the list of all possible relations of the form w1±w2±w3⋯ such that all wi are different quadratic relations that all start either with a xi or a yj.
For example for n=2 and m=1, possible relations are (I hope I did not forget any relation) : x1y1,x1y1−x2y2,x1y2+x2y2,x2y1,y1x1,y1x2,y1x1−y1x2,y1x1+y1x2.
I am not sure how to do this in an easy way with Sage, but maybe someone knows a simple trick.
Thanks for any help.
Please provide a code defining xi and yj.
I omitted a formal definition because it is a bit complicated. A formal definition would be to take the connected quiver Q with two points 1 and 2 and arrows xi from 1 to 2 and arrows yi from 2 to 1. Then one would have restrictions in the post. One can also work over a non-commutative polynomial ring with the relations xixj=0 and yiyj=0. I am not sure whether there is code to work with quivers like this in sage.
For this purpose one could also define xi and yj just as strings probably or formal non-commutative variables in sage to get the needed output. I might use the output mainly to continue to work in GAP, where quivers are available.
I understand that you want to work in a ring R where the addition is commutative biut the multiplication is not ; that is :
∀x,y∈R2, x+y=y+x
∃x,y∈R2, x⋅y≠y⋅x
Is that right ?
Also : do you consider quadratic monomials such as x2,x∈R ?
Your example lists only moinomials and binomials, whereas your definition would also accept trinomials such as x1y1+x2y1+y1x1 (etc...) and quadrinomials such as x1y1+x2y1+y1x1+y1x2 (etc).
Could you either :
clarify your definition, or
complete your example ?
Thanks !