Changeset 4c4979 in git


Ignore:
Timestamp:
Jun 19, 2009, 5:31:48 PM (14 years ago)
Author:
Viktor Levandovskyy <levandov@…>
Branches:
(u'spielwiese', '0d6b7fcd9813a1ca1ed4220cfa2b104b97a0a003')
Children:
03057341d897afb7daf5d8d5346c88a961df4184
Parents:
ca02ab01da5c28f679d205662ca93d894d1719eb
Message:
*levandov: redSB and redTail for non-homogeneous shift gb


git-svn-id: file:///usr/local/Singular/svn/trunk@11912 2c84dea3-7e68-4137-9b89-c4e89433aadc
Location:
kernel
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • kernel/kstd2.cc

    rca02ab r4c4979  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: kstd2.cc,v 1.93 2009-06-19 10:05:45 Singular Exp $ */
     4/* $Id: kstd2.cc,v 1.94 2009-06-19 15:31:48 levandov Exp $ */
    55/*
    66*  ABSTRACT -  Kernel: alg. of Buchberger
     
    16321632#endif
    16331633  /* complete reduction of the standard basis--------- */
    1634   if (TEST_OPT_SB_1)
    1635   {
    1636     int k=1;
    1637     int j;
     1634  /*  shift case: look for elt's in S such that they are divisible by elt in T */
     1635  //  if (TEST_OPT_SB_1)
     1636  if (TEST_OPT_REDSB)
     1637  {
     1638    int k=0;
     1639    int j=-1;
    16381640    while(k<=strat->sl)
    16391641    {
    1640       j=0;
    1641       loop
    1642       {
    1643         if (j>=k) break;
    1644         clearS(strat->S[j],strat->sevS[j],&k,&j,strat);
    1645         j++;
    1646       }
    1647       k++;
     1642//       loop
     1643//       {
     1644//         if (j>=k) break;
     1645//         clearS(strat->S[j],strat->sevS[j],&k,&j,strat);
     1646//         j++;
     1647//       }
     1648      LObject Ln (strat->S[k],currRing, strat->tailRing);
     1649      Ln.SetShortExpVector();
     1650      j = kFindDivisibleByInT(strat->T, strat->sevT, strat->tl, &Ln, j+1);
     1651      if (j<0) {  k++; j=-1;}
     1652      else
     1653      {
     1654        if ( pLmCmp(strat->S[k],strat->T[j].p) == 0)
     1655        {
     1656          j = kFindDivisibleByInT(strat->T, strat->sevT, strat->tl, &Ln, j+1);
     1657          if (j<0) {  k++; j=-1;}
     1658          else
     1659          {
     1660            deleteInS(k,strat);
     1661          }
     1662        }
     1663        else
     1664        {
     1665          deleteInS(k,strat);
     1666        }
     1667      }
    16481668    }
    16491669  }
    16501670
    16511671  if (TEST_OPT_REDSB)
    1652   {
    1653     completeReduce(strat, TRUE); //shift: withT = TRUE
     1672  {    completeReduce(strat, TRUE); //shift: withT = TRUE
    16541673    if (strat->completeReduce_retry)
    16551674    {
  • kernel/shiftgb.cc

    rca02ab r4c4979  
    22*  Computer Algebra System SINGULAR     *
    33****************************************/
    4 /* $Id: shiftgb.cc,v 1.11 2009-02-23 13:50:52 Singular Exp $ */
     4/* $Id: shiftgb.cc,v 1.12 2009-06-19 15:31:48 levandov Exp $ */
    55/*
    66* ABSTRACT: kernel: utils for shift GB and free GB
     
    578578
    579579
     580/*2
     581 *if the leading term of p
     582 *divides the leading term of some T[i] it will be canceled
     583 */
     584// static inline void clearSShift (poly p, unsigned long p_sev,int l, int* at, int* k,
     585//                            kStrategy strat)
     586// {
     587//   assume(p_sev == pGetShortExpVector(p));
     588//   if (!pLmShortDivisibleBy(p,p_sev, strat->T[*at].p, ~ strat->sevT[*at])) return;
     589//   //  if (l>=strat->lenS[*at]) return;
     590//   if (TEST_OPT_PROT)
     591//     PrintS("!");
     592//   mflush();
     593//   //pDelete(&strat->S[*at]);
     594//   deleteInS((*at),strat);
     595//   (*at)--;
     596//   (*k)--;
     597// //  assume(lenS_correct(strat));
     598// }
     599
    580600/* remarks: cleanT : just deletion
    581601enlargeT: just reallocation */
Note: See TracChangeset for help on using the changeset viewer.