Changeset c99fd4 in git
- Timestamp:
- Oct 6, 2008, 7:04:28 PM (15 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', '00e2e9c41af3fde1273eb3633f4c0c7c3db2579d')
- Children:
- 886b0dae50b58b9f8b0863c63abf2f0ddacf9a26
- Parents:
- 100025a806c37776e35dd4b839e192304f203af8
- Location:
- Singular/LIB
- Files:
-
- 14 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/algebra.lib
r100025 rc99fd4 1 1 /////////////////////////////////////////////////////////////////////////////// 2 version="$Id: algebra.lib,v 1.1 6 2008-07-02 09:42:59Singular Exp $";2 version="$Id: algebra.lib,v 1.17 2008-10-06 17:04:26 Singular Exp $"; 3 3 category="Commutative Algebra"; 4 4 info=" … … 395 395 ideal A = imap(R2,A); 396 396 A = std(A); 397 ideal ker = nselect(A,1 ,n);397 ideal ker = nselect(A,1..n); 398 398 setring R2; 399 399 if ( defined(Q)==voice ) … … 717 717 def bsr = basering; 718 718 // ------- checking whether phi is injective by computing the kernel ------- 719 ideal ker = nselect(A,1 ,n);719 ideal ker = nselect(A,1..n); 720 720 t = size(ker); 721 721 setring pr; -
Singular/LIB/bfct.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: bfct.lib,v 1. 4 2008-10-01 17:44:37 levandovExp $";2 version="$Id: bfct.lib,v 1.5 2008-10-06 17:04:26 Singular Exp $"; 3 3 category="Noncommutative"; 4 4 info=" … … 994 994 setring DDh; 995 995 dbprint(ppl, "the initial ideal:", string(matrix(inF))); 996 inF = nselect(inF,3 ,2*n+4);996 inF = nselect(inF,3..2*n+4); 997 997 inF = nselect(inF,1); 998 998 dbprint(ppl, "generators containing only s:", string(matrix(inF))); -
Singular/LIB/dmod.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: dmod.lib,v 1.3 0 2008-08-07 20:14:21 levandovExp $";2 version="$Id: dmod.lib,v 1.31 2008-10-06 17:04:26 Singular Exp $"; 3 3 category="Noncommutative"; 4 4 info=" … … 880 880 dbprint(ppl-1, K); 881 881 ideal M = engine(K,eng); 882 ideal K2 = nselect(M,1 ,Nnew-1);882 ideal K2 = nselect(M,1..Nnew-1); 883 883 kill K,M; 884 884 dbprint(ppl,"// -2-3- _x,_Dx are eliminated in @R2"); … … 1109 1109 dbprint(ppl-1, K); 1110 1110 ideal M = engine(K,eng); 1111 ideal K2 = nselect(M,1 ,Nnew-1);1111 ideal K2 = nselect(M,1..Nnew-1); 1112 1112 kill K,M; 1113 1113 dbprint(ppl,"// -2-3- _x,_Dx are eliminated in @R2"); … … 1259 1259 ideal M = engine(J,eng); 1260 1260 int Nnew = nvars(@R2); 1261 ideal K2 = nselect(M,1 ,Nnew-1);1261 ideal K2 = nselect(M,1..Nnew-1); 1262 1262 int ppl = printlevel-voice+2; 1263 1263 dbprint(ppl,"// -1-1- _x,_Dx are eliminated in basering"); … … 1454 1454 ideal M = engine(J,eng); 1455 1455 int Nnew = nvars(@R2); 1456 ideal K2 = nselect(M,1 ,Nnew-1);1456 ideal K2 = nselect(M,1..Nnew-1); 1457 1457 dbprint(ppl,"// -2-0- _x,_Dx are eliminated in basering"); 1458 1458 dbprint(ppl-1, K2); … … 1760 1760 dbprint(ppl-1, K); 1761 1761 ideal M = engine(K,eng); 1762 ideal K2 = nselect(M,1 ,Nnew-1);1762 ideal K2 = nselect(M,1..Nnew-1); 1763 1763 kill K,M; 1764 1764 dbprint(ppl,"// -2-3- _x,_Dx are eliminated in @R2"); … … 2260 2260 dbprint(ppl-1, I); 2261 2261 ideal J = engine(I,eng); 2262 ideal K = nselect(J,1 ,P);2262 ideal K = nselect(J,1..P); 2263 2263 kill I,J; 2264 2264 dbprint(ppl,"// -1-3- all t(i) are eliminated"); … … 2345 2345 dbprint(ppl-1, K); 2346 2346 ideal M = engine(K,eng); 2347 ideal K2 = nselect(M,1 ,Nnew-P);2347 ideal K2 = nselect(M,1..Nnew-P); 2348 2348 kill K,M; 2349 2349 dbprint(ppl,"// -2-3- _x,_Dx are eliminated in @R2"); … … 2581 2581 dbprint(ppl-1, I); 2582 2582 ideal J = engine(I,eng); 2583 ideal K = nselect(J,1 ,2);2583 ideal K = nselect(J,1..2); 2584 2584 dbprint(ppl,"// -1-3- u,v are eliminated"); 2585 2585 dbprint(ppl-1, K); // K is without u,v … … 2653 2653 dbprint(ppl-1, K); 2654 2654 ideal M = engine(K,eng); 2655 ideal K2 = nselect(M,1 ,2);2655 ideal K2 = nselect(M,1..2); 2656 2656 dbprint(ppl,"// -2-3- t,Dt are eliminated"); 2657 2657 dbprint(ppl-1, K2); … … 2722 2722 dbprint(ppl-1, K); 2723 2723 ideal M = engine(K,eng); 2724 ideal K3 = nselect(M,1 ,Nnew-1);2724 ideal K3 = nselect(M,1..Nnew-1); 2725 2725 dbprint(ppl,"// -3-3- _x,_Dx are eliminated in @R3"); 2726 2726 dbprint(ppl-1, K3); … … 2959 2959 dbprint(ppl-1, I); 2960 2960 ideal J = engine(I,eng); 2961 ideal K = nselect(J,1 ,2);2961 ideal K = nselect(J,1..2); 2962 2962 dbprint(ppl,"// -1-3- u,v are eliminated"); 2963 2963 dbprint(ppl-1, K); // K is without u,v … … 3031 3031 dbprint(ppl-1, K); 3032 3032 ideal M = engine(K,eng); 3033 ideal K2 = nselect(M,1 ,2);3033 ideal K2 = nselect(M,1..2); 3034 3034 dbprint(ppl,"// -2-3- t,Dt are eliminated"); 3035 3035 dbprint(ppl-1, K2); … … 3464 3464 dbprint(ppl-1, I); 3465 3465 ideal J = engine(I,eng); 3466 ideal K = nselect(J,1 ,2);3466 ideal K = nselect(J,1..2); 3467 3467 dbprint(ppl,"// -1-3- t,Dt are eliminated"); 3468 3468 dbprint(ppl-1, K); // K is without t, Dt … … 3689 3689 dbprint(ppl-1, I); 3690 3690 ideal J = engine(I,eng); 3691 ideal K = nselect(J,1 ,2);3691 ideal K = nselect(J,1..2); 3692 3692 dbprint(ppl,"// -1-3- t,Dt are eliminated"); 3693 3693 dbprint(ppl-1, K); // K is without t, Dt … … 3861 3861 ideal M = engine(J,eng); 3862 3862 int Nnew = nvars(@R2); 3863 ideal K2 = nselect(M,1 ,Nnew-1);3863 ideal K2 = nselect(M,1..Nnew-1); 3864 3864 int ppl = printlevel-voice+2; 3865 3865 dbprint(ppl,"// -1-1- _x,_Dx are eliminated in basering"); … … 4116 4116 // dbprint(ppl,"// -1-2- starting the elimination of u,v in @R"); 4117 4117 // ideal J = engine(I,eng); 4118 // ideal K = nselect(J,1 ,2);4118 // ideal K = nselect(J,1..2); 4119 4119 // dbprint(ppl,"// -1-3- u,v are eliminated in @R"); 4120 4120 // dbprint(ppl-1,K); // without u,v: not yet our answer … … 4188 4188 // dbprint(ppl,"// -2-2- starting elimination for t,Dt in @R2"); 4189 4189 // ideal J = engine(K2,eng); 4190 // ideal K = nselect(J,1 ,2);4190 // ideal K = nselect(J,1..2); 4191 4191 // dbprint(ppl,"// -2-3- t,Dt are eliminated"); 4192 4192 // dbprint(ppl-1,K); … … 5029 5029 dbprint(ppl-1, J); 5030 5030 ideal G = engine(J,eng); 5031 ideal K = nselect(G,1 ,N-1);5031 ideal K = nselect(G,1..N-1); 5032 5032 kill J,G; 5033 5033 dbprint(ppl,"// -1-3- _x,_Dx are eliminated"); -
Singular/LIB/dmodapp.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: dmodapp.lib,v 1. 8 2008-10-01 17:44:38 levandovExp $";2 version="$Id: dmodapp.lib,v 1.9 2008-10-06 17:04:26 Singular Exp $"; 3 3 category="Noncommutative"; 4 4 info=" … … 852 852 ideal M = groebner(J); 853 853 int Nnew = nvars(@R2); 854 ideal K2 = nselect(M,1 ,Nnew-1);854 ideal K2 = nselect(M,1..Nnew-1); 855 855 int ppl = printlevel-voice+2; 856 856 dbprint(ppl,"// -1-1- _x,_Dx are eliminated in basering"); … … 1171 1171 dbprint(ppl-1,"// -1-2-1- result of the elimination of @t,@Dt in @R"); 1172 1172 dbprint(ppl-1, J);; 1173 ideal K = nselect(J,1 ,2);1173 ideal K = nselect(J,1..2); 1174 1174 dbprint(ppl,"// -1-3- @t,@Dt are eliminated"); 1175 1175 dbprint(ppl-1, K); // K is without t, Dt -
Singular/LIB/elim.lib
r100025 rc99fd4 1 // $Id: elim.lib,v 1.2 2 2008-04-22 17:20:51Singular Exp $1 // $Id: elim.lib,v 1.23 2008-10-06 17:04:26 Singular Exp $ 2 2 // (GMG, last modified 22.06.96) 3 3 /////////////////////////////////////////////////////////////////////////////// 4 version="$Id: elim.lib,v 1.2 2 2008-04-22 17:20:51Singular Exp $";4 version="$Id: elim.lib,v 1.23 2008-10-06 17:04:26 Singular Exp $"; 5 5 category="Commutative Algebra"; 6 6 info=" … … 9 9 PROCEDURES: 10 10 blowup0(j[,s1,s2]); create presentation of blownup ring of ideal j 11 elim(id, n,m); variable n..m eliminatedfrom id (ideal/module)11 elim(id,v); eliminate variables in v from id (ideal/module) 12 12 elim1(id,p); p=product of vars to be eliminated from id 13 nselect(id, n[,m]); select generators not containing nth [..mth] variable13 nselect(id,v); select generators not containing variables given by v 14 14 sat(id,j); saturated quotient of ideal/module id by ideal j 15 select(id,n[,m]); select generators containing all variables n...m 16 select1(id,n[,m]); select generators containing one variable n...m 15 select(id,v); select generators containing all variables given by v 16 select1(id,v); select generators containing one variable given by v 17 17 18 (parameters in square brackets [] are optional) 18 19 "; … … 188 189 /////////////////////////////////////////////////////////////////////////////// 189 190 190 proc elim (id, int n, int m)191 "USAGE: elim(id, n,m); id ideal/module, n,m integers192 RETURNS: ideal/module obtained from id by eliminating variables var(n) to var(m)191 proc elim (id, intvec va) 192 "USAGE: elim(id,v); id ideal/module, v intvec 193 RETURNS: ideal/module obtained from id by eliminating variables in v 193 194 NOTE: no special monomial ordering is required, result is a SB with 194 195 respect to ordering dp (resp. ls) if the first var not to be … … 201 202 //---- get variables to be eliminated and create string for new ordering ------ 202 203 int ii; poly vars=1; 203 for( ii= n; ii<=m; ii++ ) { vars=vars*var(ii); }204 for( ii=1; ii<=size(va); ii++ ) { vars=vars*var(va[ii]); } 204 205 if( attrib(basering,"global")) { string ordering = "),dp;"; } 205 206 else { string ordering = "),ls;"; } … … 221 222 ring r=0,(x,y,u,v,w),dp; 222 223 ideal i=x-u,y-u2,w-u3,v-x+y3; 223 elim(i,3 ,4);224 elim(i,3..4); 224 225 module m=i*gen(1)+i*gen(2); 225 m=elim(m,3 ,4);show(m);226 m=elim(m,3..4);show(m); 226 227 } 227 228 /////////////////////////////////////////////////////////////////////////////// … … 267 268 /////////////////////////////////////////////////////////////////////////////// 268 269 269 proc nselect (id , int n, list#)270 "USAGE: nselect(id, n[,m]); id a module or ideal, n, m integers271 RETURN: generators of id not containing the variable n [up to m]270 proc nselect (id_inp, intvec v) 271 "USAGE: nselect(id,v); id = module or ideal, v = intvec 272 RETURN: generators of id not containing the variables with index an entry of v 272 273 SEE ALSO: select, select1 273 274 EXAMPLE: example nselect; shows examples 274 "{ 275 int j,k; 276 if( size(#)==0 ) { #[1]=n; } 277 for( k=1; k<=ncols(id); k++ ) 278 { for( j=n; j<=#[1]; j++ ) 279 { if( size(id[k]/var(j))!=0) { id[k]=0; break; } 280 } 281 } 282 return(simplify(id,2)); 275 " 276 { 277 if (typeof(id_inp)!="ideal") { module id=module(id_inp); } 278 else { ideal id=id_inp; } 279 int j,k; 280 int n,m = size(v), ncols(id); 281 //listvar(id); 282 for( k=1; k<=m; k++ ) 283 { 284 for( j=1; j<=n; j++ ) 285 { 286 if( size(id[k]/var(v[j]))!=0 ) 287 { 288 id[k]=0; break; 289 } 290 } 291 } 292 //if(typeof(id)=="ideal") { return(simplify(id,2)); } 293 //return(simplify(module(id),2)); 294 id=(simplify(module(id),2)); 295 //listvar(id); 296 return(id); 297 //return(simplify(id,2)); 283 298 } 284 299 example … … 289 304 module m=i*(gen(1)+gen(2)); 290 305 show(m); 291 show(nselect(m,3 ,4));306 show(nselect(m,3..4)); 292 307 } 293 308 /////////////////////////////////////////////////////////////////////////////// … … 333 348 /////////////////////////////////////////////////////////////////////////////// 334 349 335 proc select (id, int n, list#)336 "USAGE: select(id,n[,m]); id ideal/module, n, m integers337 RETURN: generators of id containing the variable n [all variables up to m]350 proc select (id, intvec v) 351 "USAGE: select(id,n[,m]); id = ideal/module, v= intvec 352 RETURN: generators of id containing all variables with index an entry of v 338 353 NOTE: use 'select1' for selecting generators containing at least one of the 339 variables between n and m354 variables with index an entry of v 340 355 SEE ALSO: select1, nselect 341 356 EXAMPLE: example select; shows examples 342 357 "{ 343 if( size(#)==0 ) { #[1]=n; }344 358 int j,k; 345 for( k=1; k<=ncols(id); k++ ) 346 { for( j=n; j<=#[1]; j++ ) 347 { if( size(id[k]/var(j))==0) { id[k]=0; break; } 359 int n,m = size(v), ncols(id); 360 for( k=1; k<=m; k++ ) 361 { 362 for( j=1; j<=n; j++ ) 363 { 364 if( size(id[k]/var(v[j]))==0) 365 { 366 id[k]=0; break; 367 } 348 368 } 349 369 } … … 358 378 module m=i*(gen(1)+gen(2)); 359 379 m; 360 select(m,1 ,2);361 } 362 /////////////////////////////////////////////////////////////////////////////// 363 364 proc select1 (id, int n, list#)365 "USAGE: select1(id, n[,m]); id ideal/module, n, m integers366 RETURN: generators of id containing the variable n367 [at least one of the variables up to m]380 select(m,1..2); 381 } 382 /////////////////////////////////////////////////////////////////////////////// 383 384 proc select1 (id, intvec v) 385 "USAGE: select1(id,v); id = ideal/module, v = intvec 386 RETURN: generators of id containing at least one of the variables with 387 index an entry of v 368 388 NOTE: use 'select' for selecting generators containing all the 369 variables between n and m389 variables with index an entry of v 370 390 SEE ALSO: select, nselect 371 391 EXAMPLE: example select1; shows examples 372 392 "{ 373 if( size(#)==0 ) { #[1]=n; }374 393 int j,k; 394 int n,m = size(v), ncols(id); 375 395 execute (typeof(id)+" I;"); 376 for( k=1; k<=ncols(id); k++ ) 377 { for( j=n; j<=#[1]; j++ ) 378 { 379 if( size(subst(id[k],var(j),0)) != size(id[k]) ) 380 { I=I,id[k]; break; } 396 for( k=1; k<=m; k++ ) 397 { for( j=1; j<=n; j++ ) 398 { 399 if( size(subst(id[k],var(v[j]),0)) != size(id[k]) ) 400 { 401 I = I,id[k]; break; 402 } 381 403 } 382 404 } … … 391 413 module m=i*(gen(1)+gen(2)); 392 414 m; 393 select1(m,1 ,2);394 } 395 /////////////////////////////////////////////////////////////////////////////// 415 select1(m,1..2); 416 } 417 /////////////////////////////////////////////////////////////////////////////// -
Singular/LIB/equising.lib
r100025 rc99fd4 1 version="$Id: equising.lib,v 1.1 7 2006-07-18 15:48:12Singular Exp $";1 version="$Id: equising.lib,v 1.18 2008-10-06 17:04:26 Singular Exp $"; 2 2 category="Singularities"; 3 3 info=" … … 854 854 if (typ==1) // isEquising 855 855 { 856 if(ideal(nselect(J,1 ,no_b))<>0)856 if(ideal(nselect(J,1..no_b))<>0) 857 857 { 858 858 setring old_ring; … … 941 941 if (typ==1) // isEquising 942 942 { 943 if(ideal(nselect(J,1 ,no_b))<>0)943 if(ideal(nselect(J,1..no_b))<>0) 944 944 { 945 945 setring old_ring; … … 1062 1062 { 1063 1063 if (defined(artin_bd)) { J=jet(Jnew,artin_bd-1); } 1064 if(ideal(nselect(J,1 ,no_b))<>0)1064 if(ideal(nselect(J,1..no_b))<>0) 1065 1065 { 1066 1066 setring old_ring; … … 1077 1077 { 1078 1078 if (defined(artin_bd)) { J=jet(Jnew,artin_bd-1); } 1079 if(ideal(nselect(J,1 ,no_b))<>0)1079 if(ideal(nselect(J,1..no_b))<>0) 1080 1080 { 1081 1081 setring old_ring; … … 1121 1121 { 1122 1122 if (defined(artin_bd)) { J=jet(Jnew,artin_bd-1); } 1123 if(ideal(nselect(J,1 ,no_b))<>0)1123 if(ideal(nselect(J,1..no_b))<>0) 1124 1124 { 1125 1125 setring old_ring; … … 1173 1173 } 1174 1174 1175 Jtriv = nselect(Jtriv,1 ,no_b);1176 ideal J_no_b = nselect(J,1 ,no_b);1175 Jtriv = nselect(Jtriv,1..no_b); 1176 ideal J_no_b = nselect(J,1..no_b); 1177 1177 if (size(J) > size(J_no_b)) 1178 1178 { … … 1227 1227 option(redSB); 1228 1228 J=std(J); 1229 J=nselect(J,1 ,no_b);1229 J=nselect(J,1..no_b); 1230 1230 1231 1231 setring myRing; 1232 1232 // back to "myRing" 1233 1233 1234 J=nselect(J,1 ,no_b);1234 J=nselect(J,1..no_b); 1235 1235 Jnew=imap(QQ,J); 1236 1236 … … 1242 1242 { 1243 1243 J=std(J); 1244 J=nselect(J,1 ,no_b);1244 J=nselect(J,1..no_b); 1245 1245 if (defined(artin_bd)){ J=jet(J,artin_bd-1); } 1246 1246 } -
Singular/LIB/finvar.lib
r100025 rc99fd4 1 1 /////////////////////////////////////////////////////////////////////////////// 2 version="$Id: finvar.lib,v 1.7 6 2008-01-22 09:17:19Singular Exp $"2 version="$Id: finvar.lib,v 1.77 2008-10-06 17:04:27 Singular Exp $" 3 3 category="Invariant theory"; 4 4 info=" … … 7107 7107 } 7108 7108 7109 M=elim(module(M),1 ,n); // eliminating x(1..n), std-calculation7109 M=elim(module(M),1..n); // eliminating x(1..n), std-calculation 7110 7110 // is done internally - 7111 7111 M=homog(module(M),h); // homogenize for 'minbase' … … 7631 7631 { I[i]=I[i]-y(i); 7632 7632 } 7633 I=elim(I,1 ,n);7633 I=elim(I,1..n); 7634 7634 execute("ring "+newring+"=("+charstr(br)+"),(y(1..m)),dp(m);"); 7635 7635 execute("minpoly=number("+mp+");"); -
Singular/LIB/freegb.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: freegb.lib,v 1.1 1 2008-10-02 08:14:35Singular Exp $";2 version="$Id: freegb.lib,v 1.12 2008-10-06 17:04:27 Singular Exp $"; 3 3 category="Noncommutative"; 4 4 info=" … … 529 529 dbprint(ppl,J); 530 530 // 4. skip shifted elts 531 ideal K = select1(J,1 ,s); // s = size(OrigNames)531 ideal K = select1(J,1..s); // s = size(OrigNames) 532 532 dbprint(ppl,K); 533 533 dbprint(ppl, "done with GB"); … … 1188 1188 dbprint(ppl,J); 1189 1189 // 4. skip shifted elts 1190 ideal K = select1(J,1 ,s); // s = size(OrigNames)1190 ideal K = select1(J,1..s); // s = size(OrigNames) 1191 1191 dbprint(ppl,K); 1192 1192 dbprint(ppl, "done with GB"); -
Singular/LIB/mregular.lib
r100025 rc99fd4 1 1 // IB/PG/GMG, last modified: 15.10.2004 2 2 ////////////////////////////////////////////////////////////////////////////// 3 version = "$Id: mregular.lib,v 1. 8 2005-05-06 14:38:47 hannesExp $";3 version = "$Id: mregular.lib,v 1.9 2008-10-06 17:04:27 Singular Exp $"; 4 4 category="Commutative Algebra"; 5 5 info=" … … 91 91 //----- If the ideal i is not proper: 92 92 if ( d == -1 ) 93 94 95 93 { 94 dbprint(printlevel-voice+2, 95 "// The ideal i is (1)! 96 96 // Its Castelnuovo-Mumford regularity is:"); 97 98 97 return (0); 98 } 99 99 //----- If the ideal i is 0: 100 100 if ( size(I) == 0 ) 101 102 103 101 { 102 dbprint(printlevel-voice+2, 103 "// The ideal i is (0)! 104 104 // Its Castelnuovo-Mumford regularity is:"); 105 106 105 return (0); 106 } 107 107 //----- When the ideal i is 0-dimensional: 108 108 if ( d == 0 ) 109 110 111 112 113 114 115 116 117 109 { 110 H=maxdeg1(minbase(quotient(I,maxideal(1))))+1; 111 time=rtimer-time; 112 // Additional information: 113 dbprint(printlevel-voice+2, 114 "// Dimension of S/i : 0"); 115 dbprint(printlevel-voice+2, 116 "// Time for computing regularity: " + string(time) + " sec."); 117 dbprint(printlevel-voice+2, 118 118 "// The Castelnuovo-Mumford regularity of i coincides with its satiety, and 119 119 // with the regularity of the Hilbert function of S/i. Its value is:"); 120 121 120 return (H); 121 } 122 122 //----- Determine the situation: NT, or NP, or nothing. 123 123 //----- Choose the method depending on the situation, on the … … 125 125 //----- in order to get the mon. ideal of nested type associated to i 126 126 if ( e == 1 ) 127 { 128 ch=0; 129 } 127 { ch=0; } 130 128 NPtest=is_NP(I); 131 129 if ( NPtest == 1 ) 132 133 134 130 { 131 nesttest=is_nested(I); 132 } 135 133 if ( ch != 0 ) 136 { 134 { 135 if ( NPtest == 0 ) 136 { 137 N=d*n-d*(d-1)/2; 138 s = "ring rtr = (ch,t(1..N)),x(0..n),dp;"; 139 execute(s); 140 ideal chcoord,m,i,I; 141 poly P; 142 map phi; 143 i=imap(r1,i); 144 chcoord=select1(maxideal(1),1..(n-d+1)); 145 acc=0; 146 for ( ii = 1; ii<=d; ii++ ) 147 { 148 matrix trex[1][n-d+ii+1]=t((1+acc)..(n-d+ii+acc)),1; 149 m=select1(maxideal(1),1..(n-d+1+ii)); 150 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 151 { 152 P=P+trex[1,jj]*m[jj]; 153 } 154 chcoord[n-d+1+ii]=P; 155 P=0; 156 acc=acc+n-d+ii; 157 kill trex; 158 } 159 phi=rtr,chcoord; 160 I=simplify(lead(std(phi(i))),1); 161 setring r1; 162 I=imap(rtr,I); 163 attrib(I,"isSB",1); 164 } 165 else 166 { 167 if ( nesttest == 0 ) 168 { 169 N=d*(d-1)/2; 170 s = "ring rtr = (ch,t(1..N)),x(0..n),dp;"; 171 execute(s); 172 ideal chcoord,m,i,I; 173 poly P; 174 map phi; 175 i=imap(r1,i); 176 chcoord=select1(maxideal(1),1..(n-d+2)); 177 acc=0; 178 for ( ii = 1; ii<=d-1; ii++ ) 179 { 180 matrix trex[1][ii+1]=t((1+acc)..(ii+acc)),1; 181 m=select1(maxideal(1),(n-d+2)..(n-d+2+ii)); 182 for ( jj = 1; jj<=ii+1; jj++ ) 183 { 184 P=P+trex[1,jj]*m[jj]; 185 } 186 chcoord[n-d+2+ii]=P; 187 P=0; 188 acc=acc+ii; 189 kill trex; 190 } 191 phi=rtr,chcoord; 192 I=simplify(lead(std(phi(i))),1); 193 setring r1; 194 I=imap(rtr,I); 195 attrib(I,"isSB",1); 196 } 197 } 198 } 199 else 200 { 201 if ( NPtest == 0 ) 202 { 203 while ( nl < 30 ) 204 { 205 chcoord=select1(maxideal(1),1..(n-d+1)); 206 nl=nl+1; 207 for ( ii = 1; ii<=d; ii++ ) 208 { 209 ran=random(100,1,n-d+ii); 210 ran=intmat(ran,1,n-d+ii+1); 211 ran[1,n-d+ii+1]=1; 212 m=select1(maxideal(1),1..(n-d+1+ii)); 213 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 214 { 215 P=P+ran[1,jj]*m[jj]; 216 } 217 chcoord[n-d+1+ii]=P; 218 P=0; 219 } 220 phi=r1,chcoord; 221 dbprint(printlevel-voice+2,"// (1 random change of coord.)"); 222 I=simplify(lead(std(phi(i))),1); 223 attrib(I,"isSB",1); 224 NPtest=is_NP(I); 225 if ( NPtest == 1 ) 226 { 227 break; 228 } 229 } 137 230 if ( NPtest == 0 ) 138 { 139 N=d*n-d*(d-1)/2; 140 s = "ring rtr = (ch,t(1..N)),x(0..n),dp;"; 141 execute(s); 142 ideal chcoord,m,i,I; 143 poly P; 144 map phi; 145 i=imap(r1,i); 146 chcoord=select1(maxideal(1),1,(n-d+1)); 147 acc=0; 148 for ( ii = 1; ii<=d; ii++ ) 149 { 150 matrix trex[1][n-d+ii+1]=t((1+acc)..(n-d+ii+acc)),1; 151 m=select1(maxideal(1),1,(n-d+1+ii)); 152 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 153 { 154 P=P+trex[1,jj]*m[jj]; 155 } 156 chcoord[n-d+1+ii]=P; 157 P=0; 158 acc=acc+n-d+ii; 159 kill trex; 160 } 161 phi=rtr,chcoord; 162 I=simplify(lead(std(phi(i))),1); 163 setring r1; 164 I=imap(rtr,I); 165 attrib(I,"isSB",1); 166 } 167 else 168 { 169 if ( nesttest == 0 ) 170 { 171 N=d*(d-1)/2; 172 s = "ring rtr = (ch,t(1..N)),x(0..n),dp;"; 173 execute(s); 174 ideal chcoord,m,i,I; 175 poly P; 176 map phi; 177 i=imap(r1,i); 178 chcoord=select1(maxideal(1),1,(n-d+2)); 179 acc=0; 180 for ( ii = 1; ii<=d-1; ii++ ) 181 { 182 matrix trex[1][ii+1]=t((1+acc)..(ii+acc)),1; 183 m=select1(maxideal(1),(n-d+2),(n-d+2+ii)); 184 for ( jj = 1; jj<=ii+1; jj++ ) 185 { 186 P=P+trex[1,jj]*m[jj]; 187 } 188 chcoord[n-d+2+ii]=P; 189 P=0; 190 acc=acc+ii; 191 kill trex; 192 } 193 phi=rtr,chcoord; 194 I=simplify(lead(std(phi(i))),1); 195 setring r1; 196 I=imap(rtr,I); 197 attrib(I,"isSB",1); 198 } 199 } 200 } 201 else 202 { 203 if ( NPtest == 0 ) 204 { 205 while ( nl < 30 ) 206 { 207 chcoord=select1(maxideal(1),1,(n-d+1)); 208 nl=nl+1; 209 for ( ii = 1; ii<=d; ii++ ) 210 { 211 ran=random(100,1,n-d+ii); 212 ran=intmat(ran,1,n-d+ii+1); 213 ran[1,n-d+ii+1]=1; 214 m=select1(maxideal(1),1,(n-d+1+ii)); 215 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 216 { 217 P=P+ran[1,jj]*m[jj]; 218 } 219 chcoord[n-d+1+ii]=P; 220 P=0; 221 } 222 phi=r1,chcoord; 223 dbprint(printlevel-voice+2,"// (1 random change of coord.)"); 224 I=simplify(lead(std(phi(i))),1); 225 attrib(I,"isSB",1); 226 NPtest=is_NP(I); 227 if ( NPtest == 1 ) 228 { 229 break; 230 } 231 } 232 if ( NPtest == 0 ) 233 { 231 { 234 232 "// WARNING from proc regIdeal from lib mregular.lib: 235 233 // The procedure has entered in 30 loops and could not put the variables … … 237 235 // of coordinates may enter an infinite loop when the field is finite. 238 236 // Try removing this optional argument."; 239 return (-1); 240 } 241 i=phi(i); 242 nesttest=is_nested(I); 243 } 237 return (-1); 238 } 239 i=phi(i); 240 nesttest=is_nested(I); 241 } 242 if ( nesttest == 0 ) 243 { 244 while ( nl < 30 ) 245 { 246 chcoord=select1(maxideal(1),1..(n-d+2)); 247 nl=nl+1; 248 for ( ii = 1; ii<=d-1; ii++ ) 249 { 250 ran=random(100,1,ii); 251 ran=intmat(ran,1,ii+1); 252 ran[1,ii+1]=1; 253 m=select1(maxideal(1),(n-d+2)..(n-d+2+ii)); 254 for ( jj = 1; jj<=ii+1; jj++ ) 255 { 256 P=P+ran[1,jj]*m[jj]; 257 } 258 chcoord[n-d+2+ii]=P; 259 P=0; 260 } 261 phi=r1,chcoord; 262 dbprint(printlevel-voice+2,"// (1 random change of coord.)"); 263 I=simplify(lead(std(phi(i))),1); 264 attrib(I,"isSB",1); 265 nesttest=is_nested(I); 266 if ( nesttest == 1 ) 267 { 268 break; 269 } 270 } 244 271 if ( nesttest == 0 ) 245 { 246 while ( nl < 30 ) 247 { 248 chcoord=select1(maxideal(1),1,(n-d+2)); 249 nl=nl+1; 250 for ( ii = 1; ii<=d-1; ii++ ) 251 { 252 ran=random(100,1,ii); 253 ran=intmat(ran,1,ii+1); 254 ran[1,ii+1]=1; 255 m=select1(maxideal(1),(n-d+2),(n-d+2+ii)); 256 for ( jj = 1; jj<=ii+1; jj++ ) 257 { 258 P=P+ran[1,jj]*m[jj]; 259 } 260 chcoord[n-d+2+ii]=P; 261 P=0; 262 } 263 phi=r1,chcoord; 264 dbprint(printlevel-voice+2,"// (1 random change of coord.)"); 265 I=simplify(lead(std(phi(i))),1); 266 attrib(I,"isSB",1); 267 nesttest=is_nested(I); 268 if ( nesttest == 1 ) 269 { 270 break; 271 } 272 } 273 if ( nesttest == 0 ) 274 { 272 { 275 273 "// WARNING from proc regIdeal from lib mregular.lib: 276 274 // The procedure has entered in 30 loops and could not find a monomial … … 279 277 // infinite loop when the field is finite. 280 278 // Try removing this optional argument."; 281 return (-1);282 283 284 279 return (-1); 280 } 281 } 282 } 285 283 // 286 284 // At this stage, we have obtained a monomial ideal I of nested type … … 289 287 //----- When S/i is Cohen-Macaulay: 290 288 for ( ii = n-d+2; ii <= n+1; ii++ ) 291 292 293 289 { 290 K=K+select(I,ii); 291 } 294 292 if ( size(K) == 0 ) 295 296 297 298 299 300 301 302 303 293 { 294 s="ring nr = ",charstr(r0),",x(0..n-d),dp;"; 295 execute(s); 296 ideal I; 297 I = imap(r1,I); 298 H=maxdeg1(minbase(quotient(I,maxideal(1))))+1; 299 time=rtimer-time; 300 // Additional information: 301 dbprint(printlevel-voice+2, 304 302 "// S/i is Cohen-Macaulay"); 305 303 dbprint(printlevel-voice+2, 306 304 "// Dimension of S/i ( = depth(S/i) ): "+string(d)); 307 305 dbprint(printlevel-voice+2, 308 306 "// Regularity attained at the last step of m.g.f.r. of i: YES"); 309 307 dbprint(printlevel-voice+2, 310 308 "// Regularity of the Hilbert function of S/i: " + string(H-d)); 311 309 dbprint(printlevel-voice+2, 312 310 "// Time for computing regularity: " + string(time) + " sec."); 313 311 dbprint(printlevel-voice+2, 314 312 "// The Castelnuovo-Mumford regularity of i is:"); 315 316 313 return(H); 314 } 317 315 //----- When d=1: 318 316 if ( d == 1 ) 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 317 { 318 H=maxdeg1(simplify(reduce(quotient(I,maxideal(1)),I),2))+1; 319 sat=H; 320 J=subst(I,x(n),1); 321 s = "ring nr = ",charstr(r0),",x(0..n-1),dp;"; 322 execute(s); 323 ideal J=imap(r1,J); 324 attrib(J,"isSB",1); 325 h=maxdeg1(minbase(quotient(J,maxideal(1))))+1; 326 time=rtimer-time; 327 if ( h > H ) 328 { 329 H=h; 330 } 331 // Additional information: 332 dbprint(printlevel-voice+2, 335 333 "// Dimension of S/i: 1"); 336 334 dbprint(printlevel-voice+2, 337 335 "// Depth of S/i: 0"); 338 336 dbprint(printlevel-voice+2, 339 337 "// Satiety of i: "+string(sat)); 340 338 dbprint(printlevel-voice+2, 341 339 "// Upper bound for the a-invariant of S/i: end(H^1(S/i)) <= "+ 342 340 string(h-2)); 343 344 345 341 if ( H == sat ) 342 { 343 dbprint(printlevel-voice+2, 346 344 "// Regularity attained at the last step of m.g.f.r. of i: YES"); 347 345 dbprint(printlevel-voice+2, 348 346 "// Regularity of the Hilbert function of S/i: "+string(H)); 349 350 351 352 347 } 348 else 349 { 350 dbprint(printlevel-voice+2, 353 351 "// Regularity attained at the last step of m.g.f.r. of i: NO"); 354 355 352 } 353 dbprint(printlevel-voice+2, 356 354 "// Time for computing regularity: "+ string(time) + " sec."); 357 355 dbprint(printlevel-voice+2, 358 356 "// The Castelnuovo-Mumford regularity of i is:"); 359 360 357 return(H); 358 } 361 359 //----- Now d>1 and S/i is not Cohen-Macaulay: 362 360 // 363 361 //----- First, determine the last variable really occuring 364 365 366 367 368 369 370 371 372 373 374 375 376 377 362 lastv=n-d; 363 h=n; 364 while ( lastv == n-d and h > n-d ) 365 { 366 K=select(I,h+1); 367 if ( size(K) == 0 ) 368 { 369 h=h-1; 370 } 371 else 372 { 373 lastv=h; 374 } 375 } 378 376 //----- and compute Castelnuovo-Mumford regularity: 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 377 s = "ring nr = ",charstr(r0),",x(0..lastv),dp;"; 378 execute(s); 379 ideal I,K,KK,LL; 380 I=imap(r1,I); 381 attrib(I,"isSB",1); 382 K=simplify(reduce(quotient(I,maxideal(1)),I),2); 383 H=maxdeg1(K)+1; 384 firstind=H; 385 KK=minbase(subst(I,x(lastv),1)); 386 for ( ii = n-lastv; ii<=d-2; ii++ ) 387 { 388 LL=minbase(subst(I,x(n-ii-1),1)); 389 attrib(LL,"isSB",1); 390 s = "ring mr = ",charstr(r0),",x(0..n-ii-1),dp;"; 391 execute(s); 392 ideal K,KK; 393 KK=imap(nr,KK); 394 attrib(KK,"isSB",1); 395 K=simplify(reduce(quotient(KK,maxideal(1)),KK),2); 396 h=maxdeg1(K)+1; 397 if ( h > H ) 398 { 399 H=h; 400 } 401 setring nr; 402 kill mr; 403 KK=LL; 404 } 405 // We must determine one more sat. index: 406 s = "ring mr = ",charstr(r0),",x(0..n-d),dp;"; 407 execute(s); 408 ideal KK,K; 409 KK=imap(nr,KK); 410 attrib(KK,"isSB",1); 411 K=simplify(reduce(quotient(KK,maxideal(1)),KK),2); 412 h=maxdeg1(K)+1; 413 lastind=h; 414 if ( h > H ) 415 { 416 H=h; 417 } 418 setring nr; 419 kill mr; 420 time=rtimer-time; 421 // Additional information: 422 dbprint(printlevel-voice+2, 425 423 "// Dimension of S/i: "+string(d)); 426 424 dbprint(printlevel-voice+2, 427 425 "// Depth of S/i: "+string(n-lastv)); 428 426 dbprint(printlevel-voice+2, 429 427 "// end(H^"+string(n-lastv)+"(S/i)) = " 430 428 +string(firstind-n+lastv-1)); 431 429 dbprint(printlevel-voice+2, 432 430 "// Upper bound for the a-invariant of S/i: end(H^" 433 431 +string(d)+"(S/i)) <= "+string(lastind-d-1)); 434 435 436 432 if ( H == firstind ) 433 { 434 dbprint(printlevel-voice+2, 437 435 "// Regularity attained at the last step of m.g.f.r. of i: YES"); 438 436 dbprint(printlevel-voice+2, 439 437 "// Regularity of the Hilbert function of S/i: " 440 438 +string(H-n+lastv)); 441 442 443 444 439 } 440 else 441 { 442 dbprint(printlevel-voice+2, 445 443 "// Regularity attained at the last step of m.g.f.r. of i: NO"); 446 447 444 } 445 dbprint(printlevel-voice+2, 448 446 "// Time for computing regularity: "+ string(time) + " sec."); 449 447 dbprint(printlevel-voice+2, 450 448 "// The Castelnuovo-Mumford regularity of i is:"); 451 449 return(H); 452 450 } 453 451 example … … 648 646 map phi; 649 647 i=imap(r1,i); 650 chcoord=select1(maxideal(1),1 ,(n-d+1));648 chcoord=select1(maxideal(1),1..(n-d+1)); 651 649 acc=0; 652 650 for ( ii = 1; ii<=d; ii++ ) 653 651 { 654 652 matrix trex[1][n-d+ii+1]=t((1+acc)..(n-d+ii+acc)),1; 655 m=select1(maxideal(1),1 ,(n-d+1+ii));653 m=select1(maxideal(1),1..(n-d+1+ii)); 656 654 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 657 655 { … … 680 678 map phi; 681 679 i=imap(r1,i); 682 chcoord=select1(maxideal(1),1 ,(n-d+2));680 chcoord=select1(maxideal(1),1..(n-d+2)); 683 681 acc=0; 684 682 for ( ii = 1; ii<=d-1; ii++ ) 685 683 { 686 684 matrix trex[1][ii+1]=t((1+acc)..(ii+acc)),1; 687 m=select1(maxideal(1),(n-d+2) ,(n-d+2+ii));685 m=select1(maxideal(1),(n-d+2)..(n-d+2+ii)); 688 686 for ( jj = 1; jj<=ii+1; jj++ ) 689 687 { … … 709 707 while ( nl < 30 ) 710 708 { 711 chcoord=select1(maxideal(1),1 ,(n-d+1));709 chcoord=select1(maxideal(1),1..(n-d+1)); 712 710 nl=nl+1; 713 711 for ( ii = 1; ii<=d; ii++ ) … … 716 714 ran=intmat(ran,1,n-d+ii+1); 717 715 ran[1,n-d+ii+1]=1; 718 m=select1(maxideal(1),1 ,(n-d+1+ii));716 m=select1(maxideal(1),1..(n-d+1+ii)); 719 717 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 720 718 { … … 750 748 while ( nl < 30 ) 751 749 { 752 chcoord=select1(maxideal(1),1 ,(n-d+2));750 chcoord=select1(maxideal(1),1..(n-d+2)); 753 751 nl=nl+1; 754 752 for ( ii = 1; ii<=d-1; ii++ ) … … 757 755 ran=intmat(ran,1,ii+1); 758 756 ran[1,ii+1]=1; 759 m=select1(maxideal(1),(n-d+2) ,(n-d+2+ii));757 m=select1(maxideal(1),(n-d+2)..(n-d+2+ii)); 760 758 for ( jj = 1; jj<=ii+1; jj++ ) 761 759 { … … 1030 1028 while ( nl < 30 ) 1031 1029 { 1032 chcoord=select1(maxideal(1),1 ,(n-d+1));1030 chcoord=select1(maxideal(1),1..(n-d+1)); 1033 1031 nl=nl+1; 1034 1032 for ( ii = 1; ii<=d; ii++ ) … … 1037 1035 ran=intmat(ran,1,n-d+ii+1); 1038 1036 ran[1,n-d+ii+1]=1; 1039 m=select1(maxideal(1),1 ,(n-d+1+ii));1037 m=select1(maxideal(1),1..(n-d+1+ii)); 1040 1038 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 1041 1039 { … … 1071 1069 while ( nl < 30 ) 1072 1070 { 1073 chcoord=select1(maxideal(1),1 ,(n-d+2));1071 chcoord=select1(maxideal(1),1..(n-d+2)); 1074 1072 nl=nl+1; 1075 1073 for ( ii = 1; ii<=d-1; ii++ ) … … 1078 1076 ran=intmat(ran,1,ii+1); 1079 1077 ran[1,ii+1]=1; 1080 m=select1(maxideal(1),(n-d+2) ,(n-d+2+ii));1078 m=select1(maxideal(1),(n-d+2)..(n-d+2+ii)); 1081 1079 for ( jj = 1; jj<=ii+1; jj++ ) 1082 1080 { … … 1536 1534 while ( nl < 30 ) 1537 1535 { 1538 chcoord=select1(maxideal(1),1 ,(n-d+1));1536 chcoord=select1(maxideal(1),1..(n-d+1)); 1539 1537 nl=nl+1; 1540 1538 for ( ii = 1; ii<=d; ii++ ) … … 1543 1541 ran=intmat(ran,1,n-d+ii+1); 1544 1542 ran[1,n-d+ii+1]=1; 1545 m=select1(maxideal(1),1 ,(n-d+1+ii));1543 m=select1(maxideal(1),1..(n-d+1+ii)); 1546 1544 for ( jj = 1; jj<=n-d+ii+1; jj++ ) 1547 1545 { -
Singular/LIB/noether.lib
r100025 rc99fd4 1 1 // AH last modified: 01.07.2007 2 2 ////////////////////////////////////////////////////////////////////////////// 3 version = "$Id: noether.lib,v 1.1 0 2008-04-11 14:04:40Singular Exp $";3 version = "$Id: noether.lib,v 1.11 2008-10-06 17:04:28 Singular Exp $"; 4 4 category="Commutative Algebra"; 5 5 info=" … … 199 199 for ( ii = n; ii>=0; ii-- ) 200 200 { 201 chcoord=select1(maxideal(1),1 ,(ii));201 chcoord=select1(maxideal(1),1..ii); 202 202 ran=random(100,1,ii); 203 203 ran=intmat(ran,1,ii+1); 204 204 ran[1,ii+1]=1; 205 m=select1(maxideal(1),1 ,(ii+1));205 m=select1(maxideal(1),1..(ii+1)); 206 206 for ( jj = 1; jj<=ii+1; jj++ ) 207 207 { … … 279 279 for ( ii = n; ii>=0; ii-- ) 280 280 { 281 chcoord=select1(maxideal(1),1 ,(ii));281 chcoord=select1(maxideal(1),1..ii); 282 282 ran=random(100,1,ii); 283 283 ran=intmat(ran,1,ii+1); 284 284 ran[1,ii+1]=1; 285 m=select1(maxideal(1),1 ,(ii+1));285 m=select1(maxideal(1),1..(ii+1)); 286 286 for ( jj = 1; jj<=ii+1; jj++ ) 287 287 { … … 384 384 { 385 385 nl=nl+1; 386 chcoord=select1(maxideal(1),1 ,(n));386 chcoord=select1(maxideal(1),1..n); 387 387 ran=random(100,1,n); 388 388 ran=intmat(ran,1,n+1); 389 389 ran[1,n+1]=1; 390 m=select1(maxideal(1),1 ,(n+1));390 m=select1(maxideal(1),1..(n+1)); 391 391 for ( jj = 1; jj<=n+1; jj++ ) 392 392 { … … 479 479 { 480 480 nl=nl+1; 481 chcoord=select1(maxideal(1),1 ,(n));481 chcoord=select1(maxideal(1),1..n); 482 482 ran=random(100,1,n); 483 483 ran=intmat(ran,1,n+1); 484 484 ran[1,n+1]=1; 485 m=select1(maxideal(1),1 ,(n+1));485 m=select1(maxideal(1),1..(n+1)); 486 486 for ( jj = 1; jj<=n+1; jj++ ) 487 487 { -
Singular/LIB/reszeta.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: reszeta.lib,v 1.1 1 2007-02-24 15:15:26Singular Exp $";2 version="$Id: reszeta.lib,v 1.12 2008-10-06 17:04:28 Singular Exp $"; 3 3 category="Commutative Algebra"; 4 4 info=" … … 3542 3542 //--- refine the comparison by passing to each of the numerical zeros 3543 3543 //--- of the two minpolys 3544 ideal stid=nselect(interId,1 ,nvars(R));3544 ideal stid=nselect(interId,1..nvars(R)); 3545 3545 ring compl_st=complex,(s,t),dp; 3546 3546 def stid=imap(S,stid); -
Singular/LIB/rinvar.lib
r100025 rc99fd4 1 1 // Last change 10.12.2000 (TB) 2 2 /////////////////////////////////////////////////////////////////////////////// 3 version="$Id: rinvar.lib,v 1.1 6 2006-07-18 15:22:15Singular Exp $";3 version="$Id: rinvar.lib,v 1.17 2008-10-06 17:04:28 Singular Exp $"; 4 4 category="Invariant theory"; 5 5 info=" … … 146 146 I2 = G, I1; 147 147 I2 = std(I2); 148 Gn = nselect(I2, 1 ,nvars(RIGB));148 Gn = nselect(I2, 1.. nvars(RIGB)); 149 149 imageSize = ncols(Gn); 150 150 … … 329 329 // forget all elements which contain other than the slack variables 330 330 331 J2 = nselect(J1, 1 ,nvars(RARB));331 J2 = nselect(J1, 1.. nvars(RARB)); 332 332 333 333 execute(ringSTR2); … … 904 904 // eliminate 905 905 906 N = nselect(J, 1 ,groupVars);906 N = nselect(J, 1.. groupVars); 907 907 908 908 // substitute -
Singular/LIB/sagbi.lib
r100025 rc99fd4 1 1 ////////////////////////////////////////////////////////////////////////////// 2 version="$Id: sagbi.lib,v 1.1 1 2007-07-13 12:31:06Singular Exp $";2 version="$Id: sagbi.lib,v 1.12 2008-10-06 17:04:28 Singular Exp $"; 3 3 category="Commutative Algebra"; 4 4 info=" … … 83 83 84 84 A=groebner(A); 85 ideal kern=nselect(A,1 ,n);// "kern" is the kernel of the ring map:85 ideal kern=nselect(A,1..n);// "kern" is the kernel of the ring map: 86 86 // R1----->bsr ;y(z)----> lead(id[z]). 87 87 //"kern" is the ideal of algebraic relations between … … 216 216 // to A to get std(A1). 217 217 A=A+@Res; 218 kern1=nselect(@Res,1 ,n);218 kern1=nselect(@Res,1..n); 219 219 kern=kern+kern1; 220 220 export kern,kern1,A; … … 342 342 if(choose==2) 343 343 { 344 ideal kern= nselect(groebner(dom),1 ,n);//"nselect" is combinatorial command344 ideal kern= nselect(groebner(dom),1..n);//"nselect" is combinatorial command 345 345 //which uses the internal command 346 346 // "simplify" -
Singular/LIB/standard.lib
r100025 rc99fd4 3 3 //groebner mit Optionen versehen 4 4 ////////////////////////////////////////////////////////////////////////////// 5 version="$Id: standard.lib,v 1.10 1 2008-01-28 11:42:30Singular Exp $";5 version="$Id: standard.lib,v 1.102 2008-10-06 17:04:28 Singular Exp $"; 6 6 category="Miscellaneous"; 7 7 info=" … … 824 824 825 825 def P=basering; 826 if ((typeof(i_par)=="vector")||(typeof(i_par)=="module") ) {module i=i_par;}827 else {ideal i=i_par; } 826 if ((typeof(i_par)=="vector")||(typeof(i_par)=="module")||(typeof(i_par)=="matrix")) {module i=i_par;} 827 else {ideal i=i_par; } // int, poly, number, ideal 828 828 kill i_par; 829 829 … … 1346 1346 string ri= "ring Phelp =" 1347 1347 +string(char(P))+",("+varstr_P+"),(dp,C);"; 1348 ri = ri + "minpoly = "+string(minpoly) + ";"; 1348 1349 execute(ri); 1349 1350 def m=imap(P,m); … … 1361 1362 string ri= "ring Phelp =" 1362 1363 +string(char(P))+",("+varstr_P+"),(ls,c);"; 1364 ri = ri + "minpoly = "+string(minpoly) + ";"; 1363 1365 execute(ri); 1364 1366 def m=imap(P,m); … … 1374 1376 string ri= "ring Phelp =" 1375 1377 +string(char(P))+",("+varstr_P+"),(ls,C);"; 1378 ri = ri + "minpoly = "+string(minpoly) + ";"; 1376 1379 execute(ri); 1377 1380 def m=imap(P,m);
Note: See TracChangeset
for help on using the changeset viewer.