1 | /////////////////////////////////////////////////////////////////////////////// |
---|
2 | version="$Id: gkdim.lib,v 1.4 2004-08-13 12:39:35 levandov Exp $"; |
---|
3 | category="Noncommutative"; |
---|
4 | info=" |
---|
5 | LIBRARY: GKdim.lib Procedures for calculating the Gelfand-Kirillov dimension |
---|
6 | AUTHORS: Lobillo, F.J., jlobillo@ugr.es |
---|
7 | @* Rabelo, C., crabelo@ugr.es |
---|
8 | |
---|
9 | SUPPORT: Metodos algebraicos y efectivos en grupos cuanticos, BFM2001-3141, MCYT, Jose Gomez-Torrecillas (Main researcher). |
---|
10 | |
---|
11 | |
---|
12 | PROCEDURES: |
---|
13 | GKdim(M); Gelfand-Kirillov dimension computation of the factor module basering^n/M where M is a left submodule of basering^n |
---|
14 | "; |
---|
15 | |
---|
16 | /////////////////////////////////////////////////////////////////////////////// |
---|
17 | |
---|
18 | static proc idGKdim(ideal I) |
---|
19 | // This procedure computes the Gelfand-Kirillov dimension of R/I using |
---|
20 | // the dim procedure. |
---|
21 | { |
---|
22 | if (attrib(I,"isSB")<>1) |
---|
23 | { |
---|
24 | I=std(I); |
---|
25 | } |
---|
26 | int i; |
---|
27 | for (i=1; i<=size(I); i++) |
---|
28 | { |
---|
29 | I[i]=leadmonom(I[i]); |
---|
30 | } |
---|
31 | |
---|
32 | def oldring=basering; |
---|
33 | string newringstring="ring newring=("+charstr(basering)+"),("+varstr(basering)+"),("+ordstr(basering)+")"; |
---|
34 | execute (newringstring); |
---|
35 | setring newring; |
---|
36 | ideal J=imap(oldring,I); |
---|
37 | int d=dim(std(J)); |
---|
38 | setring oldring; |
---|
39 | if (d==-1) {d++;} // The GK-dimension of a finite dimensional module is zero |
---|
40 | return (d); |
---|
41 | } |
---|
42 | |
---|
43 | /////////////////////////////////////////////////////////////////////////////// |
---|
44 | |
---|
45 | proc GKdim(list L) |
---|
46 | "USAGE: GKdim(L); L is an ideal or a module |
---|
47 | RETURN: int, the Gelfand-Kirillov dimension of R^n/L |
---|
48 | EXAMPLE: example GKdim; shows examples |
---|
49 | "{ |
---|
50 | def M=L[1]; |
---|
51 | if (typeof(M)=="ideal") |
---|
52 | { |
---|
53 | int d=idGKdim(M); |
---|
54 | } |
---|
55 | else |
---|
56 | { |
---|
57 | if (typeof(M)=="module") |
---|
58 | { |
---|
59 | M=std(M); |
---|
60 | int d=0; |
---|
61 | int n=ncols(M); // Num of vectors defining M |
---|
62 | int m=nrows(M); // The rank of the free module where M is imbedded |
---|
63 | int i,j; |
---|
64 | for (j=1; j<=n; j++) |
---|
65 | { |
---|
66 | M[j]=leadmonom(M[j]); // Only consider the leader monomial of each vector |
---|
67 | } |
---|
68 | intmat v[1][m]; // v will be the dimension of each stable subset |
---|
69 | ideal I; |
---|
70 | for (i=1; i<=m; i++) |
---|
71 | { |
---|
72 | I=0; |
---|
73 | for (j=1; j<=n; j++) |
---|
74 | { // Extract each row like an ideal |
---|
75 | I=I,M[i,j]; |
---|
76 | } |
---|
77 | v[1,i]=idGKdim(I); |
---|
78 | if (v[1,i]>d) {d=v[1,i];} |
---|
79 | } |
---|
80 | } |
---|
81 | else |
---|
82 | { |
---|
83 | string d="Error: The input must be an ideal or a module."; |
---|
84 | } |
---|
85 | } |
---|
86 | return (d); |
---|
87 | } |
---|
88 | example |
---|
89 | { |
---|
90 | "EXAMPLE:";echo=2; |
---|
91 | ring r = 0,(x,y,z),Dp; |
---|
92 | matrix C[3][3]=0,1,1,0,0,-1,0,0,0; |
---|
93 | matrix D[3][3]=0,0,0,0,0,x; |
---|
94 | ncalgebra(C,D); |
---|
95 | r; |
---|
96 | ideal I=x; |
---|
97 | GKdim(I); |
---|
98 | ideal J=x2,y; |
---|
99 | GKdim(J); |
---|
100 | module M=[x2,y,1],[x,y2,0]; |
---|
101 | GKdim(M); |
---|
102 | } |
---|
103 | |
---|
104 | /////////////////////////////////////////////////////////////////////////////// |
---|