- Timestamp:
- Mar 15, 2011, 7:17:44 PM (13 years ago)
- Branches:
- (u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', '38077648e7239f98078663eb941c3c979511150a')
- Children:
- 273fed0aea0c3cb00dc08f02c5d5340a2a781f23
- Parents:
- 91b031a4e88cb480f4ba993bf5904694c62d9b34
- Location:
- Singular
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/iparith.cc
r91b031 r22579cf 2983 2983 } 2984 2984 } 2985 2986 // test the La Scala case' output 2987 assume( (iiOp == LRES_CMD) == (r->syRing != NULL) ); 2988 assume( (iiOp == LRES_CMD) == (r->resPairs != NULL) ); 2989 assume( (r->minres != NULL) || (r->fullres != NULL) ); 2990 2985 2991 return FALSE; 2986 2992 } … … 4190 4196 { 4191 4197 intvec *weights=(intvec*)atGet(v,"isHomog",INTVEC_CMD); 4192 res->data=(char *)syMinimize((syStrategy)v->Data()); 4198 4199 syStrategy tmp=(syStrategy)v->Data(); 4200 tmp = syMinimize(tmp); // enrich itself! 4201 4202 res->data=(char *)tmp; 4203 4193 4204 if (weights!=NULL) 4194 4205 atSet(res, omStrDup("isHomog"),ivCopy(weights),INTVEC_CMD); 4206 4195 4207 return FALSE; 4196 4208 } -
Singular/ipconv.cc
r91b031 r22579cf 236 236 237 237 syStrategy tmp=(syStrategy)in->CopyD(); 238 238 239 out->data=(void *)syConvRes(tmp,TRUE,add_row_shift); 239 240 } -
Singular/ipshell.cc
r91b031 r22579cf 2110 2110 } 2111 2111 R->order[j]=rOrderName(omStrDup((char*)vv->m[0].Data())); // assume STRING 2112 2112 2113 if (j==0) R->block0[0]=1; 2113 2114 else … … 2511 2512 { 2512 2513 syStrategy syzstr=(syStrategy)u->Data(); 2514 2513 2515 BOOLEAN minim=(int)(long)w->Data(); 2514 2516 int row_shift=0; … … 2522 2524 (*weights) -= add_row_shift; 2523 2525 } 2526 2524 2527 res->data=(void *)syBettiOfComputation(syzstr,minim,&row_shift,weights); 2525 2528 //row_shift += add_row_shift; 2526 2529 //Print("row_shift=%d, add_row_shift=%d\n",row_shift,add_row_shift); 2527 2530 atSet(res,omStrDup("rowShift"),(void*)add_row_shift,INT_CMD); 2531 2528 2532 return FALSE; 2529 2533 } … … 2542 2546 lists syConvRes(syStrategy syzstr,BOOLEAN toDel,int add_row_shift) 2543 2547 { 2544 if ((syzstr->fullres==NULL) && (syzstr->minres==NULL)) 2548 resolvente fullres = syzstr->fullres; 2549 resolvente minres = syzstr->minres; 2550 2551 const int length = syzstr->length; 2552 2553 if ((fullres==NULL) && (minres==NULL)) 2545 2554 { 2546 2555 if (syzstr->hilb_coeffs==NULL) 2547 2556 { 2548 syzstr->fullres = syReorder(syzstr->res,syzstr->length,syzstr);2557 fullres = syReorder(syzstr->res, length, syzstr); 2549 2558 } 2550 2559 else 2551 2560 { 2552 syzstr->minres = syReorder(syzstr->orderedRes,syzstr->length,syzstr); 2553 syKillEmptyEntres(syzstr->minres,syzstr->length); 2554 } 2555 } 2561 minres = syReorder(syzstr->orderedRes, length, syzstr); 2562 syKillEmptyEntres(minres, length); 2563 } 2564 } 2565 2556 2566 resolvente tr; 2557 2567 int typ0=IDEAL_CMD; 2558 if (syzstr->minres!=NULL) 2559 tr = syzstr->minres; 2568 2569 if (minres!=NULL) 2570 tr = minres; 2560 2571 else 2561 tr = syzstr->fullres; 2562 resolvente trueres=NULL; 2563 intvec ** w=NULL; 2564 if (syzstr->length>0) 2565 { 2566 trueres=(resolvente)omAlloc0((syzstr->length)*sizeof(ideal)); 2567 for (int i=(syzstr->length)-1;i>=0;i--) 2572 tr = fullres; 2573 2574 resolvente trueres=NULL; intvec ** w=NULL; 2575 2576 if (length>0) 2577 { 2578 trueres = (resolvente)omAlloc0((length)*sizeof(ideal)); 2579 for (int i=(length)-1;i>=0;i--) 2568 2580 { 2569 2581 if (tr[i]!=NULL) … … 2576 2588 if (syzstr->weights!=NULL) 2577 2589 { 2578 w = (intvec**)omAlloc0( (syzstr->length)*sizeof(intvec*));2579 for (int i= (syzstr->length)-1;i>=0;i--)2590 w = (intvec**)omAlloc0(length*sizeof(intvec*)); 2591 for (int i=length-1;i>=0;i--) 2580 2592 { 2581 2593 if (syzstr->weights[i]!=NULL) w[i] = ivCopy(syzstr->weights[i]); … … 2583 2595 } 2584 2596 } 2585 lists li = liMakeResolv(trueres,syzstr->length,syzstr->list_length,typ0, 2586 w,add_row_shift); 2587 if (w != NULL) omFreeSize(w, (syzstr->length)*sizeof(intvec*)); 2588 if (toDel) syKillComputation(syzstr); 2597 2598 lists li = liMakeResolv(trueres, length, syzstr->list_length,typ0, 2599 w, add_row_shift); 2600 2601 if (w != NULL) omFreeSize(w, length*sizeof(intvec*)); 2602 2603 if (toDel) 2604 syKillComputation(syzstr); 2605 else 2606 { 2607 if( fullres != NULL && syzstr->fullres == NULL ) 2608 syzstr->fullres = fullres; 2609 2610 if( minres != NULL && syzstr->minres == NULL ) 2611 syzstr->minres = minres; 2612 } 2613 2589 2614 return li; 2615 2616 2590 2617 } 2591 2618 -
Singular/subexpr.cc
r91b031 r22579cf 144 144 break; 145 145 case RESOLUTION_CMD: 146 syPrint((syStrategy)d); 146 { 147 syStrategy tmp=(syStrategy)d; 148 syPrint(tmp); 147 149 break; 150 } 148 151 case STRING_CMD: 149 152 PrintNSpaces(spaces);
Note: See TracChangeset
for help on using the changeset viewer.