1 | /////////////////////////////////////////////////////////////////////////////// |
---|
2 | version="$Id$"; |
---|
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 | PROCEDURES: |
---|
12 | GKdim(M); Gelfand-Kirillov dimension computation of the factor-module, whose presentation is given by the matrix M. |
---|
13 | "; |
---|
14 | |
---|
15 | /////////////////////////////////////////////////////////////////////////////////// |
---|
16 | static proc idGKdim(ideal I) |
---|
17 | "USAGE: idGKdim(I), I is a left ideal |
---|
18 | RETURN: int, the Gelfand-Kirillov dimension of the R/I |
---|
19 | NOTE: uses the dim procedure, if the factor-module is zero, -1 is returned |
---|
20 | " |
---|
21 | { |
---|
22 | if (attrib(I,"isSB")<>1) |
---|
23 | { |
---|
24 | I=std(I); |
---|
25 | } |
---|
26 | |
---|
27 | int d = dim(I); |
---|
28 | // if (d==-1) {d++;} // The GK-dimension of a finite dimensional module is zero |
---|
29 | // levandov: but for consistency, GKdim(std(1)) == -1, |
---|
30 | // mimicking the behaviour of dim() procedure. |
---|
31 | return (d); |
---|
32 | } |
---|
33 | |
---|
34 | /////////////////////////////////////////////////////////////////////////////// |
---|
35 | proc GKdim(list L) |
---|
36 | "USAGE: GKdim(L); L is a left ideal/module/matrix |
---|
37 | RETURN: int |
---|
38 | PURPOSE: compute the Gelfand-Kirillov dimension of the factor-module, whose presentation is given by L, e.g. R^r/L |
---|
39 | NOTE: if the factor-module is zero, -1 is returned |
---|
40 | EXAMPLE: example GKdim; shows examples |
---|
41 | " |
---|
42 | { |
---|
43 | def M = L[1]; |
---|
44 | int d = -1; |
---|
45 | if (typeof(M)=="ideal") |
---|
46 | { |
---|
47 | d=idGKdim(M); |
---|
48 | } |
---|
49 | else |
---|
50 | { |
---|
51 | if (typeof(M)=="matrix") |
---|
52 | { |
---|
53 | module N = module(M); |
---|
54 | kill M; |
---|
55 | module M = N; |
---|
56 | } |
---|
57 | if (typeof(M)=="module") |
---|
58 | { |
---|
59 | if (attrib(M,"isSB")<>1) |
---|
60 | { |
---|
61 | M=std(M); |
---|
62 | } |
---|
63 | int n = ncols(M); // Num of vectors defining M |
---|
64 | int m = nrows(M); // The rank of the free module where M is imbedded |
---|
65 | int i,j; |
---|
66 | for (j=1; j<=n; j++) |
---|
67 | { |
---|
68 | M[j] = leadmonom(M[j]); // Only consider the leader monomial of each vector |
---|
69 | } |
---|
70 | intmat v[1][m]; // v will be the dimension of each stable subset |
---|
71 | ideal I; |
---|
72 | for (i=1; i<=m; i++) |
---|
73 | { |
---|
74 | I=0; |
---|
75 | for (j=1; j<=n; j++) |
---|
76 | { // Extract each row like an ideal .LV: ???? |
---|
77 | I=I, M[i,j]; |
---|
78 | } |
---|
79 | v[1,i] = idGKdim(I); |
---|
80 | if (v[1,i]>d) { d = v[1,i]; } |
---|
81 | } |
---|
82 | } |
---|
83 | else |
---|
84 | { |
---|
85 | ERROR("The input must be an ideal, a module or a matrix."); |
---|
86 | } |
---|
87 | } |
---|
88 | return (d); |
---|
89 | } |
---|
90 | example |
---|
91 | { |
---|
92 | "EXAMPLE:";echo=2; |
---|
93 | ring R = 0,(x,y,z),Dp; |
---|
94 | matrix C[3][3]=0,1,1,0,0,-1,0,0,0; |
---|
95 | matrix D[3][3]=0,0,0,0,0,x; |
---|
96 | def r = nc_algebra(C,D); setring r; |
---|
97 | r; |
---|
98 | ideal I=x; |
---|
99 | GKdim(I); |
---|
100 | ideal J=x2,y; |
---|
101 | GKdim(J); |
---|
102 | module M=[x2,y,1],[x,y2,0]; |
---|
103 | GKdim(M); |
---|
104 | ideal A = x,y,z; |
---|
105 | GKdim(A); |
---|
106 | ideal B = 1; |
---|
107 | GKdim(B); |
---|
108 | GKdim(ideal(0)) == nvars(basering); // should be true, i.e., evaluated to 1 |
---|
109 | } |
---|
110 | /////////////////////////////////////////////////////////////////////////////// |
---|
111 | proc gkdim(list L) |
---|
112 | { |
---|
113 | return(GKdim(L)); |
---|
114 | } |
---|
115 | /////////////////////////////////////////////////////////////////////////////// |
---|