1662{
1663
1664
1665 int i, gap, newgap, egap;
1666 int n = 0;
1667
1668 VECTOR(MonomialTableZZ::mon_term *) divisors;
1670
1671
1673
1674
1675 n +=
lookupZZ->find_term_divisors(-1, c, e,
x, &divisors);
1676
1677
1678 if (n == 0)
1679 {
1680 result_gap = 0;
1681 return -1;
1682 }
1683 int result = divisors[n - 1]->_val;
1685 gap = tg->gap - egap;
1686 if (gap <= 0)
1687 gap = 0;
1688 else
1689 for (i = n - 2; i >= 0; i--)
1690 {
1691 int new_val = divisors[i]->_val;
1693 newgap = tg->gap - egap;
1694 if (newgap <= 0)
1695 {
1696 gap = 0;
1698 break;
1699 }
1700 else if (newgap < gap)
1701 {
1703 gap = newgap;
1704 }
1705 }
1706 result_gap = gap;
1708}
MonomialTableZZ * lookupZZ
const GBWeight * weightInfo_
const MonomialTableZZ * ringtableZZ
void gb(IntermediateBasis &F, int n)
VALGRIND_MAKE_MEM_DEFINED & result(result)