Ignore:
Timestamp:
Feb 1, 2021, 1:48:48 PM (3 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
311d0993aaf7a37ae5134ab3b58a01291ecdfb59
Parents:
19ee5eb33e0ea7b7b2733aee435dc677eb23f478
Message:
fix: p_InitContent only for (some) internal coeffs
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpolys/polys/monomials/p_polys.cc

    r19ee5eb r4218c1  
    22882288    p_SetCoeff(ph,n_Init(1,cf),r);
    22892289  }
    2290   if (cf->cfSubringGcd==ndGcd) /* trivial gcd*/ return;
    2291   number h=p_InitContent(ph,r); /* first guess of a gcd of all coeffs */
     2290  if ((cf->cfSubringGcd==ndGcd)
     2291  || (cf->cfGcd==ndGcd)) /* trivial gcd*/
     2292    return;
     2293  number h;
     2294  if ((rField_is_Q(r))
     2295  || (rField_is_Q_a(r))
     2296  || (rField_is_Zp_a)(r)
     2297  || (rField_is_Z(r))
     2298  )
     2299  {
     2300    h=p_InitContent(ph,r); /* first guess of a gcd of all coeffs */
     2301  }
     2302  else
     2303  {
     2304    h=n_Copy(pGetCoeff(ph),cf);
     2305  }
    22922306  poly p;
    22932307  if(n_IsOne(h,cf))
Note: See TracChangeset for help on using the changeset viewer.