|
7.6.4 Example of use of LETTERPLACE
The input monomials must be given in a letterplace notation. We recommend
first to define a commutative ring
in SINGULAR and equip it with
a degree well-ordering. Then, decide what should be the degree bound d and
run the procedure makeLetterplaceRing(d)
from the library freegb.lib .
This procedure creates a letterplace algebra with an induced ordering.
In this algebra, define an ideal I in the letterplace encoding and run the procedure
system("freegb",I,d,n) , where
is the number of variables of
the original commutative ring. The output is given in the letterplace encoding.
Note that one can also use freeGBasis from freegb.lib in order to simplify technicalities.
We illustrate this approach with the following example:
| LIB "freegb.lib";
ring r = 0,(x,y,z),dp;
int d =4; // degree bound
def R = makeLetterplaceRing(d);
setring R;
ideal I = x(1)*y(2) + y(1)*z(2), x(1)*x(2) + x(1)*y(2) - y(1)*x(2) - y(1)*y(2);
option(redSB); option(redTail);
ideal J = system("freegb",I,d,nvars(r));
J;
==> J[1]=y(1)*z(2)*y(3)*y(4)-y(1)*z(2)*y(3)*z(4)+y(1)*z(2)*z(3)*y(4)-y(1)*z(2\
)*z(3)*z(4)
==> J[2]=y(1)*z(2)*y(3)*x(4)+y(1)*z(2)*y(3)*z(4)+y(1)*z(2)*z(3)*x(4)+y(1)*z(2\
)*z(3)*z(4)
==> J[3]=y(1)*y(2)*z(3)*y(4)-y(1)*y(2)*z(3)*z(4)+y(1)*z(2)*z(3)*y(4)-y(1)*z(2\
)*z(3)*z(4)
==> J[4]=y(1)*y(2)*z(3)*x(4)+y(1)*y(2)*z(3)*z(4)+y(1)*z(2)*z(3)*x(4)+y(1)*z(2\
)*z(3)*z(4)
==> J[5]=y(1)*y(2)*y(3)-y(1)*y(2)*z(3)+y(1)*z(2)*y(3)-y(1)*z(2)*z(3)
==> J[6]=y(1)*y(2)*x(3)+y(1)*y(2)*z(3)+y(1)*z(2)*x(3)+y(1)*z(2)*z(3)
==> J[7]=x(1)*y(2)+y(1)*z(2)
==> J[8]=x(1)*x(2)-y(1)*x(2)-y(1)*y(2)-y(1)*z(2)
// ----------------------------------
lp2lstr(J,r); // export an object called @code{@LN} to the ring r
setring r; // change to the ring r
lst2str(@LN,1); // output the string presentation
==> [1]:
==> y*z*y*y-y*z*y*z+y*z*z*y-y*z*z*z
==> [2]:
==> y*z*y*x+y*z*y*z+y*z*z*x+y*z*z*z
==> [3]:
==> y*y*z*y-y*y*z*z+y*z*z*y-y*z*z*z
==> [4]:
==> y*y*z*x+y*y*z*z+y*z*z*x+y*z*z*z
==> [5]:
==> y*y*y-y*y*z+y*z*y-y*z*z
==> [6]:
==> y*y*x+y*y*z+y*z*x+y*z*z
==> [7]:
==> x*y+y*z
==> [8]:
==> x*x-y*x-y*y-y*z
|
It is possible to convert the letterplace presentation of an ideal
to a list of strings with the help of procedures lp2lstr
and lst2str from the library freegb.lib . This is shown in the
second part of the example above.
There are various conversion routines in the library freegb.lib .
We work further on implementing more algorithms for
non-commutative ideals and modules over free associative algebra.
|