Changeset d5a330 in git


Ignore:
Timestamp:
Mar 6, 2013, 2:27:37 PM (10 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'jengelh-datetime', 'ceac47cbc86fe4a15902392bdbb9bd2ae0ea02c6')(u'spielwiese', '5a0dde71de01068fad5736a17555c993ecbbf495')
Children:
825fb7e9602cb5db3284b92d7dd82a01e88c9600
Parents:
803cb2d20d4037b513adf020767d48f6893fc9a2
Message:
fix: unify changes for HAVE_RING and HAVE_PLURAL
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpolys/polys/kbuckets.cc

    r803cb2d rd5a330  
    716716  i = pLogLength(l1);
    717717
    718   if ((i <= bucket->buckets_used) && (bucket->buckets[i] != NULL))
    719   {
    720     assume(pLength(bucket->buckets[i])==bucket->buckets_length[i]);
     718#if defined(HAVE_RINGS)||defined(HAVE_PLURAL)
     719  if ((rField_is_Ring(r) && !(rField_is_Domain(r)))
     720  ||(rIsPluralRing(r)))
     721  {
     722    pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
     723    p1=pp_Mult_mm(p,m,r);
     724    pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
     725    l1=pLength(p1);
     726    i = pLogLength(l1);
     727  }
     728  else
     729#endif
     730  {
     731    if ((i <= bucket->buckets_used) && (bucket->buckets[i] != NULL))
     732    {
     733      assume(pLength(bucket->buckets[i])==bucket->buckets_length[i]);
    721734//#ifdef USE_COEF_BUCKETS
    722735//     if(bucket->coef[i]!=NULL)
     
    730743//     else
    731744//#endif
    732     MULTIPLY_BUCKET(bucket,i);
    733     p1 = p_Minus_mm_Mult_qq(bucket->buckets[i], m, p1,
     745      MULTIPLY_BUCKET(bucket,i);
     746      p1 = p_Minus_mm_Mult_qq(bucket->buckets[i], m, p1,
    734747                            bucket->buckets_length[i], l1,
    735748                            spNoether, r);
    736     l1 = bucket->buckets_length[i];
    737     bucket->buckets[i] = NULL;
    738     bucket->buckets_length[i] = 0;
    739 #ifdef HAVE_RINGS
    740     if (rField_is_Ring(r) && !(rField_is_Domain(r)))
    741     {
    742       l1 = pLength(p1);
     749      l1 = bucket->buckets_length[i];
     750      bucket->buckets[i] = NULL;
     751      bucket->buckets_length[i] = 0;
    743752      i = pLogLength(l1);
    744753    }
    745 #endif
    746 #ifdef HAVE_PLURAL
    747     if (rIsPluralRing(r))
    748     {
    749       l1 = pLength(p1);
    750       i = pLogLength(l1);
    751     }
    752 #endif
    753   }
    754   else
    755   {
    756     pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
    757     if (spNoether != NULL)
    758     {
    759       l1 = -1;
    760       p1 = r->p_Procs->pp_Mult_mm_Noether(p1, m, spNoether, l1, r);
    761       i = pLogLength(l1);
    762     }
    763754    else
    764755    {
    765       p1 = r->p_Procs->pp_Mult_mm(p1, m, r);
    766 #ifdef HAVE_RINGS
    767       if (rField_is_Ring(r) && !(rField_is_Domain(r)))
     756      pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
     757      if (spNoether != NULL)
    768758      {
    769         l1 = pLength(p1);
     759        l1 = -1;
     760        p1 = r->p_Procs->pp_Mult_mm_Noether(p1, m, spNoether, l1, r);
    770761        i = pLogLength(l1);
    771762      }
    772 #endif
    773 #ifdef HAVE_PLURAL
    774       if (rIsPluralRing(r))
     763      else
    775764      {
    776         l1 = pLength(p1);
    777         i = pLogLength(l1);
     765        p1 = r->p_Procs->pp_Mult_mm(p1, m, r);
    778766      }
    779 #endif
    780     }
    781     pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
     767      pSetCoeff0(m, n_Neg(pGetCoeff(m),r->cf));
     768    }
    782769  }
    783770
Note: See TracChangeset for help on using the changeset viewer.