Changeset 1c809c1 in git
- Timestamp:
- Aug 10, 2011, 9:39:25 AM (12 years ago)
- Branches:
- (u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'a800fe4b3e9d37a38c5a10cc0ae9dfa0c15a4ee6')
- Children:
- 04c8f285a16186a0886f05ff3b5b783ab679bf7e
- Parents:
- e3085c0d4bdb7123d79c22514ef9c099d8b71594
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/surfacesignature.lib
re3085c r1c809c1 49 49 PROCEDURES: 50 50 signatureBrieskorn(a1,a2,a3); signature of singularity x^a1+y^a2+z^a3 51 signatureNemethi(N,f); signature of singularity z^N+f(x,y)=0, f irred. 51 signaturePuiseux(N,f); signature of singularity z^N+f(x,y)=0, f irred. 52 signatureNemethi(N,f); signature of singularity z^N+f(x,y)=0 52 53 "; 53 54 … … 97 98 /////////////////////////////////////////////////////////////////////////////// 98 99 99 proc signatureBrieskorn( a1,a2,a3)100 proc signatureBrieskorn(int a1, int a2, int a3) 100 101 "USAGE: signatureBrieskorn(a1,a2,a3); a1,a2,a3 = integers 101 102 RETURN: signature of Brieskorn singularity x^a1+y^a2+z^a3 … … 148 149 /////////////////////////////////////////////////////////////////////////////// 149 150 150 static proc signatureP(int N,poly f)151 "USAGE: signatureP (N,f); N = integer, f = irreducible poly in 2 variables151 proc signaturePuiseux(int N, poly f) 152 "USAGE: signaturePuiseux(N,f); N = int, f = irreducible poly in 2 variables 152 153 RETURN: signature of surface singularity defined by z^N + f(x,y) = 0 153 EXAMPLE: example signatureP ; shows an example154 EXAMPLE: example signaturePuiseux; shows an example 154 155 " 155 156 { … … 180 181 poly f = x15-21x14+8x13y-6x13-16x12y+20x11y2-x12+8x11y-36x10y2 181 182 +24x9y3+4x9y2-16x8y3+26x7y4-6x6y4+8x5y5+4x3y6-y8; 182 signatureP (N,f);183 signaturePuiseux(N,f); 183 184 } 184 185 … … 296 297 { 297 298 v=N[i,1..n]; 298 if(isRupture(v)) // the divisor intersects more then two others299 if(isRupture(v)) // the divisor intersects more then two others 299 300 { 300 301 for(j=1;j<=n;j++) … … 313 314 } 314 315 return(a-1+4*e+sumEdges(N,M,K,n)-sumExcepDiv(N,M,K,n)); 316 } 317 318 /////////////////////////////////////////////////////////////////////////////// 319 320 static proc signatureRes(int N, poly f) 321 //=== computes signature of surface singularity defined by z^N + f(x,y) = 0 322 //=== in terms of the imbedded resolution graph of f 323 { 324 list L = totalmultiplicities(f); 325 return(etaRes(L,N) - N*etaRes(L,1)); 315 326 } 316 327 … … 385 396 386 397 /////////////////////////////////////////////////////////////////////////////// 387 //---------------- Consolidation of the three former variants ----------------- 398 399 static proc signatureSpec(int N, poly f) 400 //=== computes signature of surface singularity defined by z^N + f(x,y) = 0 401 //=== in terms of the spectral pairs of f 402 { 403 def R = basering; 404 def Rds = changeord("ds"); 405 setring Rds; 406 poly f = imap(R,f); 407 list L = sppairs(f); 408 setring R; 409 list L = imap(Rds,L); 410 return(etaSpec(L,N) - N*etaSpec(L,1)); 411 } 412 413 /////////////////////////////////////////////////////////////////////////////// 414 //----------------- Consolidation of the two recent variants ------------------ 388 415 389 416 proc signatureNemethi(int N, poly f, list #) 390 417 "USAGE: signatureNemethi(N,f); N = integer, f = reduced poly in 2 variables, 391 418 # empty or 1,2,3 392 @* - if # is empty or #[1] = 2 then resolution of singularitiesis used393 @* - if #[1] = 1 then f has to be analytically irreducible and Puiseux394 expansions are used 395 @* - if #[1] = 3 then spectral pairs are used419 @* - if #[1] = 1 then resolution of singularity is used 420 @* - if #[1] = 2 then spectral pairs are used 421 @* - if # is empty then both upper variants are used in parallel and the 422 @* fastest returns the result 396 423 RETURN: signature of surface singularity defined by z^N + f(x,y) = 0 397 424 REMARK: computes the signature of some special surface singularities … … 401 428 if(size(#) == 0) 402 429 { 403 list L = totalmultiplicities(f); 404 return(etaRes(L,N) - N*etaRes(L,1)); 430 link l(1) = "ssi:fork"; open(l(1)); 431 link l(2) = "ssi:fork"; open(l(2)); 432 list l = list(l(1),l(2)); 433 write(l(1), quote(signatureRes(N,f))); 434 write(l(2), quote(signatureSpec(N,f))); 435 int winner = waitfirst(l); 436 number sigma = read(l(winner)); 437 close(l(1)); 438 close(l(2)); 439 if(printlevel >= 1) 440 { 441 if(winner == 1) { "Resolution of singularity has been used."; } 442 if(winner == 2) { "Spectral pairs have been used."; } 443 } 444 return(sigma); 405 445 } 406 446 407 447 if(#[1] == 1) 408 448 { 409 return(signature P(N,f));449 return(signatureRes(N,f)); 410 450 } 411 451 412 452 if(#[1] == 2) 413 453 { 414 list L = totalmultiplicities(f); 415 return(etaRes(L,N) - N*etaRes(L,1)); 416 } 417 418 if(#[1] == 3) 419 { 420 def R = basering; 421 def Rds = changeord("ds"); 422 setring Rds; 423 poly f = imap(R,f); 424 list L = sppairs(f); 425 setring R; 426 list L = imap(Rds,L); 427 return(etaSpec(L,N) - N*etaSpec(L,1)); 454 return(signatureSpec(N,f)); 428 455 } 429 456 } … … 435 462 +24x9y3+4x9y2-16x8y3+26x7y4-6x6y4+8x5y5+4x3y6-y8; 436 463 signatureNemethi(N,f,1); 437 signatureNemethi(N,f,2); 464 printlevel = 1; 465 signatureNemethi(N,f); 438 466 } 439 467
Note: See TracChangeset
for help on using the changeset viewer.