| LIB "bimodules.lib";
ring r = 0,(x,s),dp;
def R = nc_algebra(1,s); setring R; //1st shift algebra
def Re = envelope(R); setring Re; //basering is now R^{env} = R (X) R^{opp}
poly f = X*S*x^2+5*x*S*X+S*X; f;
==> x2SX+x2S+5xSX+SX
ideal I = CompDecomp(f);
print(matrix(I)); // what means that f = (x2+5x+1)*SX + x2*S
==> x2SX+5xSX+SX,x2S
poly p = x*S+X^2*S+2*s+x*X^2*s+5*x*s; p;
==> xsX2+5xs+xS+2s+SX2+2SX+S
ideal Q = CompDecomp(p);
print(matrix(Q));
==> xsX2,5xs+2s,xS+S,SX2,2SX
|