Changeset 0291940 in git
- Timestamp:
- Oct 8, 2010, 12:14:28 PM (14 years ago)
- Branches:
- (u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', '38077648e7239f98078663eb941c3c979511150a')
- Children:
- 87ee9b164257c151ff65e88084e1964ad3138011
- Parents:
- 6e45c119f7dae5d56d3bdbc0441f758aef1380a0
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/LIB/resbin.lib
r6e45c1 r0291940 2 2 //////////////////////////////////////////////////////////////////////////// 3 3 version="$Id: resbin.lib$"; 4 category=" Commutative algebra";4 category="Resolution of singularities"; 5 5 info=" 6 6 LIBRARY: resbin.lib Combinatorial algorithm of resolution of singularities … … 11 11 @* G. Pfister, pfister@mathematik.uni-kl.de 12 12 13 SEE ALSO: resolve_lib14 15 13 PROCEDURES: 16 14 BINresol(J); computes a E-resolution of singularities of (J) (THE SECOND PART IS NOT IMPLEMENTED YET) 15 17 16 Eresol(J); computes a E-resolution of singularities of (J) in char 0 18 17 determinecenter(L1,L2,c,n,Y,a,mb,flag,control3); computes the next blowing-up center 19 18 Blowupcenter(L1,id,m,L2,c,n,h); makes the blowing-up 20 19 Nonhyp(Coef,expJ,sJ,n,flag,sums); computes the ideal generated by the non hyperbolic generators of expJ 20 21 21 inidata(K,k); verifies input data, a binomial ideal K of k generators 22 22 identifyvar(); identifies status of variables … … 35 35 Maxord(L,n); computes the maximum exponent of an exceptional monomial ideal 36 36 Gamma(L,c,n); computes the Gamma function for an exceptional monomial ideal given by L 37 37 38 convertdata(C,L,n,flag); computes the ideal corresponding to C,L 38 tradblwup(blwhist,n,Y,a,num); composes the blowing up at this chart39 39 lcmofall(nchart,mobile); computes the lcm of the denominators of the E-orders for all the charts 40 40 computemcm(Eolist); computes the lcm of the denominators of the E-orders for one chart 41 41 42 constructH(Hhist,n,flag); construct the list of exceptional divisors accumulated at this chart 42 43 constructblwup(blwhist,n,chy,flag); construct the ideal defining the map K[W] --> K[Wi], 43 44 which gives the composition map of all the blowing up leading to this chart 44 45 constructlastblwup(blwhist,n,chy,flag); construct the ideal defining the last blowup leading to this chart 46 45 47 genoutput(chart,mobile,nchart,nsons,n,q,p); generates the output for visualization 46 48 salida(idchart,chart,mobile,numson,previousa,n,q); generates the output for one chart 49 47 50 iniD(n); creates a list of lists of zeros of size n 48 51 sumlist(L1,L2); sums two lists component to component … … 52 55 createlist(L1,L2); creates a list of lists of two elements 53 56 list0(n); creates a list of zeros of size n 54 55 57 "; 56 58 … … 2391 2393 " 2392 2394 { 2393 int idchart,parent;2394 list auxlist,solvedrings,totalringlist,previousa;2395 list auxlistenp,solvedringsenp,totalringenp;2395 int idchart,parent; 2396 list auxlist,solvedrings,totalringlist,previousa; 2397 list auxlistenp,solvedringsenp,totalringenp; 2396 2398 2397 2399 // chart gives: parent,Y,a,expJ,Coef,flag,Hhist,blwhist,path,hipercoef,hiperexp 2398 2400 // mobile gives: tip,oldOlist,oldC,oldt,oldD,oldH,allH,infobo7; NOTE: Eolist=mobile[2]; 2399 2401 2400 idchart=1;2402 idchart=1; 2401 2403 2402 2404 // first loop, construct list previousa 2403 2405 2404 while (idchart<=nchart) 2405 { 2406 if (idchart==1){previousa[1]=chart[2][3];} 2407 2408 else{ 2409 2406 while (idchart<=nchart) 2407 { 2408 if (idchart==1){previousa[1]=chart[2][3];} 2409 else 2410 { 2410 2411 // if there are no sons, the next center is nothing 2411 2412 if (nsons[idchart]==0){previousa[idchart]=0;} 2413 2412 if (nsons[idchart]==0){previousa[idchart]=0;} 2414 2413 // always fill the parent 2415 2416 parent=chart[idchart][1]; 2417 previousa[parent]=chart[idchart][3]; 2418 } 2419 idchart=idchart+1; 2420 } 2421 2414 parent=chart[idchart][1]; 2415 previousa[parent]=chart[idchart][3]; 2416 } 2417 idchart=idchart+1; 2418 } 2422 2419 // HERE BEGIN THE LOOP 2423 2424 idchart=1; 2425 2426 while (idchart<=nchart) 2427 { 2428 2429 def auxexit=salida(idchart,chart[idchart],mobile[idchart+1],nsons[idchart],previousa[idchart],n,q,p); 2430 2431 if (p>0){ // we need the computations in char 0 too 2432 def auxexitenp=salida(idchart,chart[idchart],mobile[idchart+1],nsons[idchart],previousa[idchart],n,q,0); 2433 } 2434 else{def auxexitenp=auxexit;} 2435 2420 idchart=1; 2421 while (idchart<=nchart) 2422 { 2423 def auxexit=salida(idchart,chart[idchart],mobile[idchart+1],nsons[idchart],previousa[idchart],n,q,p); 2424 if (p>0) 2425 { // we need the computations in char 0 too 2426 def auxexitenp=salida(idchart,chart[idchart],mobile[idchart+1],nsons[idchart],previousa[idchart],n,q,0); 2427 } 2428 else{def auxexitenp=auxexit;} 2436 2429 // we add the ring to the list of all rings 2437 2438 auxlist[1]=auxexit; 2439 totalringlist=totalringlist+auxlist; 2440 2441 auxlistenp[1]=auxexitenp; 2442 totalringenp=totalringenp+auxlistenp; 2443 2430 auxlist[1]=auxexit; 2431 totalringlist=totalringlist+auxlist; 2432 auxlistenp[1]=auxexitenp; 2433 totalringenp=totalringenp+auxlistenp; 2444 2434 // if the chart has no sons, add it to the list of final charts 2445 2446 if (nsons[idchart]==0){solvedrings=solvedrings+auxlist; 2447 solvedringsenp=solvedringsenp+auxlistenp; 2448 } 2449 2450 auxlist=list(); 2451 auxlistenp=list(); 2452 kill auxexit; 2453 kill auxexitenp; 2454 2455 idchart=idchart+1; 2456 2457 } // EXIT WHILE 2458 2459 return(solvedrings,totalringlist,solvedringsenp,totalringenp); 2435 if (nsons[idchart]==0) 2436 { 2437 solvedrings=solvedrings+auxlist; 2438 solvedringsenp=solvedringsenp+auxlistenp; 2439 } 2440 auxlist=list(); 2441 auxlistenp=list(); 2442 kill auxexit; 2443 kill auxexitenp; 2444 idchart=idchart+1; 2445 } // EXIT WHILE 2446 return(solvedrings,totalringlist,solvedringsenp,totalringenp); 2460 2447 } 2461 2448 example … … 2484 2471 " 2485 2472 { 2486 int m,i,aux,mcmchart; 2487 intvec num; 2488 2489 m=size(Eolist); 2490 2491 if (m==1){mcmchart=int(denominator(Eolist[1])); return(mcmchart);} 2492 2493 if (m>1){num=int(denominator(Eolist[1])); 2494 for (i=2;i<=m;i++){aux=int(denominator(Eolist[i])); 2495 num=num,aux; }} 2496 2497 mcmchart=lcm(num); 2498 2499 return(mcmchart); 2473 int m,i,aux,mcmchart; 2474 intvec num; 2475 m=size(Eolist); 2476 if (m==1){mcmchart=int(denominator(Eolist[1])); return(mcmchart);} 2477 if (m>1) 2478 { 2479 num=int(denominator(Eolist[1])); 2480 for (i=2;i<=m;i++) 2481 {aux=int(denominator(Eolist[i])); num=num,aux; } 2482 } 2483 mcmchart=lcm(num); 2484 return(mcmchart); 2500 2485 } 2501 2486 example … … 2517 2502 " 2518 2503 { 2519 int i,j,m,l;2520 list exceplist;2521 ideal aux;2522 2523 m=size(Hhist); 2524 if (Hhist[1]==0 and m>1){Hhist=Hhist[2..m]; m=m-1; 2525 2526 for (i=1;i<=m;i++){2527 l=Hhist[i];2528 if (flag[l]==0){aux=ideal(poly(x(l))); }2529 else {aux=ideal(poly(y(l))); }2530 2531 2532 2504 int i,j,m,l; 2505 list exceplist; 2506 ideal aux; 2507 m=size(Hhist); 2508 if (Hhist[1]==0 and m>1) 2509 { 2510 Hhist=Hhist[2..m]; m=m-1; 2511 for (i=1;i<=m;i++) 2512 { 2513 l=Hhist[i]; 2514 if (flag[l]==0){aux=ideal(poly(x(l))); } 2515 else {aux=ideal(poly(y(l))); } 2516 exceplist[i]=aux; 2517 } 2533 2518 // eliminate repeated variables 2534 for (i=1;i<=m;i++){for (j=1;j<=m;j++){ 2535 if (Hhist[i]==Hhist[j] and i!=j){ 2536 if (i<j){exceplist[i]=ideal(1);} 2537 if (i>j){exceplist[j]=ideal(1);} 2538 } 2539 } 2540 } 2541 2542 } 2543 else {exceplist=list();} 2544 2519 for (i=1;i<=m;i++) 2520 { 2521 for (j=1;j<=m;j++) 2522 { 2523 if (Hhist[i]==Hhist[j] and i!=j) 2524 { 2525 if (i<j){exceplist[i]=ideal(1);} 2526 if (i>j){exceplist[j]=ideal(1);} 2527 } 2528 } 2529 } 2530 } 2531 else {exceplist=list();} 2545 2532 // else {exceplist=list(ideal(0));} // IF IT FAILS USE THIS 2546 2547 return(exceplist); 2533 return(exceplist); 2548 2534 } 2549 2535 example … … 2556 2542 L[1][7][7]; // blow ups at x(3)-th, x(1)-th and x(1)-th charts 2557 2543 constructH(L[1][7][7],3,flag); 2558 2559 2544 } 2560 2545 ///////////////////////////////////////////////////////////////////// … … 2569 2554 " 2570 2555 { 2571 int i,j,m,m2; 2572 poly aux2; 2573 2574 m=size(blwhist[1]); 2575 2576 for (j=1;j<=m;j++){ 2577 for (i=1;i<=n;i++){ m2=blwhist[i][j]; 2578 2556 int i,j,m,m2; 2557 poly aux2; 2558 2559 m=size(blwhist[1]); 2560 2561 for (j=1;j<=m;j++) 2562 { 2563 for (i=1;i<=n;i++) 2564 { 2565 m2=blwhist[i][j]; 2579 2566 // If m2!=0 this variable changes. First decide if the variable to multiply is invertible or not 2580 2581 if (m2!=0){ 2582 if (flag[m2]==0){aux2=poly(x(m2));} 2583 else {aux2=poly(y(m2));} 2584 2567 if (m2!=0) 2568 { 2569 if (flag[m2]==0){aux2=poly(x(m2));} 2570 else {aux2=poly(y(m2));} 2585 2571 // And then substitute this variable for the corresponding product in the whole ideal 2586 2587 if (flag[i]==0){chy=subst(chy,x(i),x(i)*aux2);} 2588 else {chy=subst(chy,y(i),y(i)*aux2);} 2589 2590 } 2591 } 2592 2593 } 2594 2595 return(chy); 2572 if (flag[i]==0){chy=subst(chy,x(i),x(i)*aux2);} 2573 else {chy=subst(chy,y(i),y(i)*aux2);} 2574 } 2575 } 2576 } 2577 return(chy); 2596 2578 } 2597 2579 example … … 2616 2598 " 2617 2599 { 2618 int i,j,m,m2; 2619 poly aux2; 2620 2621 m=size(blwhist[1]); 2622 2623 if (m>0){ 2624 for (i=1;i<=n;i++){ m2=blwhist[i][m]; 2625 2626 // If m2!=0 this variable changes. First decide if the variable to multiply is invertible or not 2627 2628 if (m2!=0){ 2629 if (flag[m2]==0){aux2=poly(x(m2));} 2630 else {aux2=poly(y(m2));} 2600 int i,j,m,m2; 2601 poly aux2; 2602 m=size(blwhist[1]); 2603 2604 if (m>0) 2605 { 2606 for (i=1;i<=n;i++){ m2=blwhist[i][m]; 2607 2608 // If m2!=0 this variable changes. First decide if the variable to multiply is invertible or not 2609 2610 if (m2!=0) 2611 { 2612 if (flag[m2]==0){aux2=poly(x(m2));} 2613 else {aux2=poly(y(m2));} 2631 2614 2632 2615 // And then substitute this variable for the corresponding product in the whole ideal 2633 2616 2634 if (flag[i]==0){chy=subst(chy,x(i),x(i)*aux2);} 2635 else {chy=subst(chy,y(i),y(i)*aux2);} 2636 2637 } 2638 } 2617 if (flag[i]==0){chy=subst(chy,x(i),x(i)*aux2);} 2618 else {chy=subst(chy,y(i),y(i)*aux2);} 2619 } 2620 } 2639 2621 } 2640 2622 … … 2662 2644 " 2663 2645 { 2664 int i,m; 2665 ideal acenter,aux2; 2666 2667 if (a==0){acenter=J2;} 2668 else{ 2669 m=size(a); 2670 for (i=1;i<=m;i++){ 2671 if (flag[a[i]]==0){aux2=poly(x(a[i]));} 2672 else {aux2=poly(y(a[i]));} 2673 2674 acenter=acenter+aux2; 2675 } 2646 int i,m; 2647 ideal acenter,aux2; 2648 2649 if (a==0) 2650 {acenter=J2;} 2651 else 2652 { 2653 m=size(a); 2654 for (i=1;i<=m;i++) 2655 { 2656 if (flag[a[i]]==0){aux2=poly(x(a[i]));} 2657 else {aux2=poly(y(a[i]));} 2658 2659 acenter=acenter+aux2; 2676 2660 } 2661 } 2677 2662 return(acenter); 2678 2663 } … … 2689 2674 ////////////////////////////////////////////////////////////////////////////////////// 2690 2675 2691 2676 proc iniD(int n) 2692 2677 "USAGE: iniD(n); n integer 2693 2678 RETURN: list of lists of zeros of size n
Note: See TracChangeset
for help on using the changeset viewer.