Changeset 91d286 in git


Ignore:
Timestamp:
Dec 3, 2010, 11:44:43 AM (14 years ago)
Author:
Oliver Wienand <wienand@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', '8c6038b526213d378981739e978a9f7b485dab94')
Children:
b65d1d09372f184bc4cc01749c27188e17788097
Parents:
444cbf2e2b949ba94c0455a7275d7bc7e2c64949
Message:
 * Error in component check while creating gcd polys (fixed #300)
 * Further changed return value of nDivComp to match return values of pDivComp

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

Legend:

Unmodified
Added
Removed
  • kernel/kutil.cc

    r444cbf r91d286  
    163163    if (!a & !b) return pDivComp_EQUAL;
    164164  }
    165   return 0;
     165  return pDivComp_INCOMP;
    166166}
    167167#endif
     
    11351135    compare=pDivCompRing(strat->B[j].lcm,Lp.lcm);
    11361136    compareCoeff = nDivComp(pGetCoeff(strat->B[j].lcm), pGetCoeff(Lp.lcm));
    1137     if (compareCoeff == 0 || compare == compareCoeff)
     1137    if (compareCoeff == pDivComp_EQUAL || compare == compareCoeff)
    11381138    {
    11391139      if (compare == 1)
     
    29262926//      if (((unsigned long) pGetCoeff(h) % (unsigned long) pGetCoeff(strat->S[j]) != 0) &&
    29272927//         ((unsigned long) pGetCoeff(strat->S[j]) % (unsigned long) pGetCoeff(h) != 0))
    2928       if ( iCompH == pGetComp(strat->S[k]) )
     2928      if ( iCompH == pGetComp(strat->S[j]) )
    29292929      {
    29302930        {
  • kernel/numbers.cc

    r444cbf r91d286  
    118118#ifdef HAVE_RINGS
    119119BOOLEAN ndDivBy(number a, number b) { return TRUE; } // assume a,b !=0
    120 int ndDivComp(number a, number b) { return 0; }
     120int ndDivComp(number a, number b) { return 2; }
    121121BOOLEAN ndIsUnit(number a) { return !nIsZero(a); }
    122122number  ndExtGcd (number a, number b, number *s, number *t) { return nInit(1); }
  • kernel/rintegers.cc

    r444cbf r91d286  
    186186int nrzDivComp(number a, number b)
    187187{
    188   if (nrzEqual(a, b)) return 0;
    189   if (nrzDivBy(a, b)) return -1;
     188  if (nrzDivBy(a, b))
     189  {
     190    if (nrzDivBy(b, a)) return 2;
     191    return -1;
     192  }   
    190193  if (nrzDivBy(b, a)) return 1;
    191   return 2;
     194  return 0;
    192195}
    193196
  • kernel/rmodulo2m.cc

    r444cbf r91d286  
    253253    if (b % 2 == 1)
    254254    {
    255       return 0;
     255      return 2;
    256256    }
    257257    else
  • kernel/rmodulon.cc

    r444cbf r91d286  
    287287int nrnDivComp(number a, number b)
    288288{
    289   if (nrnEqual(a, b)) return 0;
     289  if (nrnEqual(a, b)) return 2;
    290290  if (mpz_divisible_p((int_number) a, (int_number) b)) return -1;
    291291  if (mpz_divisible_p((int_number) b, (int_number) a)) return 1;
    292   return 2;
     292  return 0;
    293293}
    294294
Note: See TracChangeset for help on using the changeset viewer.