Changeset 4b56a8 in git for Singular/LIB/invar.lib
- Timestamp:
- Feb 6, 2020, 2:27:22 PM (4 years ago)
- Branches:
- (u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', '38dfc5131670d387a89455159ed1e071997eec94')
- Children:
- 092919835ebabc072adc7c0c118f96741838874a
- Parents:
- 48d798e6fa161513a1be9c743406d7c43a479b9d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/invar.lib
r48d798e r4b56a8 12 12 torusrep(list m) representation of a torus given by the weights m[1],m[2],... 13 13 finiterep(<list>) representation of a by a list of matrices 14 prod(l) gives the product of all entries of list l15 monsum(n,d) sum of all monomials in x(1),x(2),...,x(n) of degree d16 14 sympower(m,d) computes the d-th symmetric power of a representation m 17 15 invar(m) computes the invariant ring of the representation m. … … 54 52 } 55 53 example 56 { "> SL(3);"; 57 SL(3); 58 "> group;"; 59 Invar::group; 60 "> groupideal;"; 61 groupideal; 62 "> print(SLrep);"; 63 print(SLrep); 54 {"EXAMPLE:"; echo=2; 55 SL(3); 56 Invar::group; 57 groupideal; 58 print(SLrep); 64 59 } 65 60 … … 67 62 // prod(<list>) just gives the product of all entries of <list>. 68 63 //////////////////////////////////////////////////////////////////////////////// 69 proc prod(list #)64 static proc prod(list #) 70 65 "USAGE: prod(<list>) 71 66 RETURN: the product of all entries of <list>" … … 77 72 // monsum(n,d) is the sum of all monomials in x(1),x(2),...,x(n) of degree d 78 73 //////////////////////////////////////////////////////////////////////////////// 79 proc monsum(int n,int d)74 static proc monsum(int n,int d) 80 75 "USAGE: monsum(n,d) 81 76 RETURNS: the sum of all monomials in x(1),x(2),...,x(n) of degree d" … … 123 118 } 124 119 example 125 { "> SL(2);"; 126 SL(2); 127 "> print(SLrep);"; 128 print(SLrep); 129 "> print(sympower(SLrep,3));"; 130 print(sympower(SLrep,3)); // doesn't work in the example 131 // environment. Bug in Singular?? 132 // We'll have to cheat: 133 //"g(1)^3, 3*g(1)^2*g(2), 3*g(1)*g(2)^2, g(2)^3,"; 134 //"g(1)^2*g(3),3*g(1)^2*g(4)-2*g(1), 3*g(1)*g(2)*g(4)-1*g(2),g(2)^2*g(4),"; 135 //"g(1)*g(3)^2,3*g(1)*g(3)*g(4)-1*g(3),3*g(1)*g(4)^2-2*g(4), g(2)*g(4)^2,"; 136 //"g(3)^3, 3*g(3)^2*g(4), 3*g(3)*g(4)^2, g(4)^3"; 120 { "EXAMPLE:"; echo=2; 121 SL(2); 122 print(SLrep); 123 print(sympower(SLrep,3)); 137 124 } 138 125 … … 151 138 The base ring will be set to 'polyring' which is a global 152 139 variable representing the polynomial ring on which the group acts. 153 The variable 'representation' will be set to the input m." 140 The variable 'representation' will be set to the input m. 141 EXAMPLE: example invar; shows an example 142 " 154 143 { 155 144 int n=nrows(m); … … 188 177 print(invring); 189 178 } 179 example 180 { "EXAMPLE:"; echo=2; 181 SL(2); // Take the group SL_2 182 matrix m=dsum(SLrep,SLrep,SLrep,SLrep); 183 // 4 copies of the standard representation 184 invar(m); // empirical evidence for FFT 185 reynolds(x(1)*x(4)); // The reynolds operator is computed using 186 // the Omega process. 187 } 188 190 189 191 190 //////////////////////////////////////////////////////////////////////////////// … … 294 293 } 295 294 example 296 { "> torus(3);"; 297 torus(3); 298 "> group;"; 299 Invar::group; 300 "> groupideal;"; 301 groupideal; 295 {"EXAMPLE:"; echo=2; 296 torus(3); 297 Invar::group; 298 groupideal; 302 299 } 303 300 … … 312 309 RETURNS: torusrep(m) gives a matrix with entries in 'group'. This matrix 313 310 represents the action of the torus with weights 314 m[1],m[2],...,m[size(m)]" 311 m[1],m[2],...,m[size(m)] 312 EXAMPLE: example torusreynolds; shows an example 313 " 315 314 { int r=size(m[1]); 316 315 int n=size(m); … … 329 328 return(mm); 330 329 } 330 example 331 { "EXAMPLE:"; echo=2; 332 torus(1); // Take the 1-dimensional torus, the multiplicative group. 333 list weights=-2,-3,7; // 3-dimensial action with weights -2,-3,7 334 matrix m=torusrep(weights);// compute the matrix of the representation 335 invar(m); // compute the invariant ring 336 } 331 337 332 338 //////////////////////////////////////////////////////////////////////////////// … … 366 372 int i=prime(n-1); 367 373 while(i<>2) 368 {if (n%i==0) {f=f*(z**(n /i)-1);};374 {if (n%i==0) {f=f*(z**(n div i)-1);}; 369 375 i=prime(i-1);}; 370 if (n%2==0) {f=f*(z**(n /2)-1);};371 h=h/ GCD(f,h);376 if (n%2==0) {f=f*(z**(n div 2)-1);}; 377 h=h/gcd(f,h); 372 378 return(h/leadcoef(h)); 373 379 } … … 383 389 groupideal of type <ideal> 384 390 reynolds of type <proc> 385 The basering will be set to 'group'." 391 The basering will be set to 'group'. 392 EXAMPLE: example finite; shows an example 393 " 386 394 { ring group=0,(g(1),g(2)),dp(2); 387 395 export group; … … 395 403 // 'finitereynolds' 396 404 } 405 example 406 {"EXAMPLE:"; echo=2; 407 finite(6); // The symmetric group S_3 408 matrix id=unitmat(3); // identity matrix 409 matrix m3[3][3]=0,1,0,0,0,1,1,0,0; // corresponds with (1 2 3) 410 matrix m2[3][3]=0,1,0,1,0,0,0,0,1; // corresponds with (1 2) 411 list a=id,m3,m3*m3,m2,m2*m3,m2*m3*m3; // all elements of S_3 412 matrix rep=finiterep(a); // compute matrix of standard repr. 413 invar(rep); // compute the invariant ring 414 } 415 397 416 398 417 //////////////////////////////////////////////////////////////////////////////// … … 406 425 RETURNS: finiterep(m) gives a matrix with coefficients in the ring 'group' 407 426 which represents the action of the finite group where the elements 408 of the finite group act as m[1],m[2],...m[size(m)]." 427 of the finite group act as m[1],m[2],...m[size(m)]. 428 EXAMPLE: example finiterep; shows an example 429 " 409 430 { int l=size(m); 410 431 int n=nrows(m[1]); … … 420 441 return(finiterep); 421 442 } 422 443 example 444 {"EXAMPLE:"; echo=2; 445 finite(6); // The symmetric group S_3 446 matrix id=unitmat(3); // identity matrix 447 matrix m3[3][3]=0,1,0,0,0,1,1,0,0; // corresponds with (1 2 3) 448 matrix m2[3][3]=0,1,0,1,0,0,0,0,1; // corresponds with (1 2) 449 list a=id,m3,m3*m3,m2,m2*m3,m2*m3*m3; // all elements of S_3 450 matrix rep=finiterep(a); // compute matrix of standard repr. 451 invar(rep); // compute the invariant ring 452 } 453
Note: See TracChangeset
for help on using the changeset viewer.