Changeset 5079887 in git for factory/facFqFactorize.cc
 Timestamp:
 Aug 8, 2012, 5:08:59 PM (11 years ago)
 Branches:
 (u'jengelhdatetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', 'c987db42cd2ec943b97ac5746c99892ceddf909c')
 Children:
 79592ac0413bc31f4675cd016eba92870cff9765
 Parents:
 464b18c0e995f211723d02ba1f0e3764e16f8c67
 gitauthor:
 Martin Lee <martinlee84@web.de>20120808 17:08:59+02:00
 gitcommitter:
 Martin Lee <martinlee84@web.de>20120904 18:01:17+02:00
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

factory/facFqFactorize.cc
r464b18 r5079887 2663 2663 A /= hh; 2664 2664 2665 if (size (A)/getNumVars (A) < 500 && 2666 LucksWangSparseHeuristic (A, biFactors, 2, leadingCoeffs2 [A.level()  3], 2667 factors)) 2668 { 2669 int check= factors.length(); 2670 factors= recoverFactors (A, factors); 2665 CFList bufFactors= CFList(); 2666 if (LucksWangSparseHeuristic (A, biFactors, 2, leadingCoeffs2 [A.level()  3], 2667 factors)) 2668 { 2669 int check= biFactors.length(); 2670 int * index= new int [factors.length()]; 2671 CFList oldFactors= factors; 2672 factors= recoverFactors (A, factors, index); 2671 2673 2672 2674 if (check == factors.length()) … … 2677 2679 if (v.level() != 1) 2678 2680 { 2679 for ( CFListIteratoriter= factors; iter.hasItem(); iter++)2681 for (iter= factors; iter.hasItem(); iter++) 2680 2682 iter.getItem()= swapvar (iter.getItem(), v, y); 2681 2683 } 2684 2682 2685 appendSwapDecompress (factors, contentAFactors, N, swapLevel, 2683 2686 swapLevel2, x); 2684 2687 normalize (factors); 2688 delete [] index; 2685 2689 delete [] Aeval2; 2686 2690 return factors; 2687 2691 } 2692 else if (factors.length() > 0) 2693 { 2694 int oneCount= 0; 2695 CFList l; 2696 for (int i= 0; i < check; i++) 2697 { 2698 if (index[i] == 1) 2699 { 2700 iter=biFactors; 2701 for (int j=1; j <= ioneCount; j++) 2702 iter++; 2703 iter.remove (1); 2704 for (int j= 0; j < A.level() 2; j++) 2705 { 2706 l= leadingCoeffs2[j]; 2707 iter= l; 2708 for (int k=1; k <= ioneCount; k++) 2709 iter++; 2710 iter.remove (1); 2711 leadingCoeffs2[j]=l; 2712 } 2713 oneCount++; 2714 } 2715 } 2716 bufFactors= factors; 2717 factors= CFList(); 2718 } 2688 2719 else 2689 2720 factors= CFList(); 2690 //TODO handle this case2721 delete [] index; 2691 2722 } 2692 2723 … … 2729 2760 if (check != factors.length()) 2730 2761 noOneToOne= true; 2762 else 2763 factors= Union (factors, bufFactors); 2731 2764 2732 2765 if (extension && !noOneToOne)
Note: See TracChangeset
for help on using the changeset viewer.