Changeset 4dafdf in git for factory/facFqBivar.cc


Ignore:
Timestamp:
Mar 13, 2013, 4:26:54 PM (11 years ago)
Author:
Martin Lee <martinlee84@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
20203120e3f743bc2648a192a556dec455772b76
Parents:
9614bba86831fbfed42ec2f8c377ccc1ec4d9582
git-author:
Martin Lee <martinlee84@web.de>2013-03-13 16:26:54+01:00
git-committer:
Martin Lee <martinlee84@web.de>2013-03-22 15:51:50+01:00
Message:
chg: use dense modular multiplication
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/facFqBivar.cc

    r9614bb r4dafdf  
    14821482    tmp1= factors.getFirst();
    14831483    tmp2= factors.getLast();
    1484     tmp1 *= LC (F, x);
    1485     tmp1= mod (tmp1, yToL);
     1484    tmp1= mulMod2 (tmp1, LC (F,x), yToL);
    14861485    tmp1 /= content (tmp1, x);
    1487     tmp2 *= LC (F, x);
    1488     tmp2= mod (tmp2, yToL);
     1486    tmp2= mulMod2 (tmp2, LC (F,x), yToL);
    14891487    tmp2 /= content (tmp2, x);
    14901488    tmp3 = tmp1*tmp2;
     
    15241522      }
    15251523    }
    1526     buf *= LC (F, x);
    1527     buf= mod (buf, yToL);
     1524    buf= mulMod2 (buf, LC (F,x), yToL);
    15281525    buf /= content (buf, x);
    15291526    if (fdivides (buf, F, quot))
     
    15591556    tmp1= factors.getFirst();
    15601557    tmp2= factors.getLast();
    1561     tmp1 *= LC (F, x);
    1562     tmp1= mod (tmp1, yToL);
     1558    tmp1= mulMod2 (tmp1, LC (F,x), yToL);
    15631559    tmp1 /= content (tmp1, x);
    1564     tmp2 *= LC (F, x);
    1565     tmp2= mod (tmp2, yToL);
     1560    tmp2= mulMod2 (tmp2, LC (F,x), yToL);
    15661561    tmp2 /= content (tmp2, x);
    15671562    tmp3 = tmp1*tmp2;
     
    16011596      }
    16021597    }
    1603     buf *= LC (F, x);
    1604     buf= mod (buf, yToL);
     1598    buf= mulMod2 (buf, LC (F,x), yToL);
    16051599    buf /= content (buf, x);
    16061600    if (fdivides (buf, F, quot))
     
    16371631    tmp1= factors.getFirst();
    16381632    tmp2= factors.getLast();
    1639     tmp1 *= LC (F, x);
    1640     tmp1= mod (tmp1, yToL);
     1633    tmp1= mulMod2 (tmp1, LC (F,x), yToL);
    16411634    tmp1 /= content (tmp1, x);
    1642     tmp2 *= LC (F, x);
    1643     tmp2= mod (tmp2, yToL);
     1635    tmp2= mulMod2 (tmp2, LC (F,x), yToL);
    16441636    tmp2 /= content (tmp2, x);
    16451637    tmp3 = tmp1*tmp2;
     
    16791671      }
    16801672    }
    1681     buf *= LC (F, x);
    1682     buf= mod (buf, yToL);
     1673    buf= mulMod2 (buf, LC (F,x), yToL);
    16831674    buf /= content (buf, x);
    16841675    if (fdivides (buf, F, quot))
     
    17291720      }
    17301721    }
    1731     buf *= LC (F, x);
    1732     buf= mod (buf, yToL);
     1722    buf= mulMod2 (buf, LC (F,x), yToL);
    17331723    buf /= content (buf, x);
    17341724    if (fdivides (buf, F, quot))
     
    17811771    }
    17821772    buf2= buf;
    1783     buf *= LC (F, x);
    1784     buf= mod (buf, yToL);
     1773    buf= mulMod2 (buf, LC (F,x), yToL);
    17851774    buf /= content (buf, x);
    17861775    if (fdivides (buf, F, quot))
     
    18381827      }
    18391828    }
    1840     buf *= LC (F, x);
    1841     buf= mod (buf, yToL);
     1829    buf= mulMod2 (buf, LC (F,x), yToL);
    18421830    buf /= content (buf, x);
    18431831    buf2= buf (y-evaluation, y);
     
    19191907      }
    19201908    }
    1921     buf *= LC (F, x);
    1922     buf= mod (buf, yToL);
     1909    buf= mulMod2 (buf, LC (F,x), yToL);
    19231910    buf /= content (buf, x);
    19241911    buf2= buf (y-evaluation, y);
     
    19931980      }
    19941981    }
    1995     buf *= LC (F, x);
    1996     buf= mod (buf, yToL);
     1982    buf= mulMod2 (buf, LC (F,x), yToL);
    19971983    buf /= content (buf, x);
    19981984    if (fdivides (buf, F, quot))
     
    20442030      }
    20452031    }
    2046     buf *= LC (F, x);
    2047     buf= mod (buf, yToL);
     2032    buf= mulMod2 (buf, LC (F,x), yToL);
    20482033    buf /= content (buf, x);
    20492034    if (fdivides (buf, F, quot))
     
    20882073    tmp1= factors.getFirst();
    20892074    tmp2= factors.getLast();
    2090     tmp1 *= LC (F, x);
    2091     tmp1= mod (tmp1, yToL);
     2075    tmp1= mulMod2 (tmp1, LC (F,x), yToL);
    20922076    tmp1 /= content (tmp1, x);
    2093     tmp2 *= LC (F, x);
    2094     tmp2= mod (tmp2, yToL);
     2077    tmp2= mulMod2 (tmp2, LC (F,x), yToL);
    20952078    tmp2 /= content (tmp2, x);
    20962079    tmp3 = tmp1*tmp2;
     
    21512134      }
    21522135    }
    2153     buf *= LC (F, x);
    2154     buf= mod (buf, yToL);
     2136    buf= mulMod2 (buf, LC (F,x), yToL);
    21552137    buf /= content (buf, x);
    21562138    buf2= buf (y - evaluation, y);
     
    22202202    tmp1= factors.getFirst();
    22212203    tmp2= factors.getLast();
    2222     tmp1 *= LC (F, x);
    2223     tmp1= mod (tmp1, yToL);
     2204    tmp1= mulMod2 (tmp1, LC (F,x), yToL);
    22242205    tmp1 /= content (tmp1, x);
    2225     tmp2 *= LC (F, x);
    2226     tmp2= mod (tmp2, yToL);
     2206    tmp2= mulMod2 (tmp2, LC (F,x), yToL);
    22272207    tmp2 /= content (tmp2, x);
    22282208    tmp3 = tmp1*tmp2;
     
    22832263      }
    22842264    }
    2285     buf *= LC (F, x);
    2286     buf= mod (buf, yToL);
     2265    buf= mulMod2 (buf, LC (F,x), yToL);
    22872266    buf /= content (buf, x);
    22882267    buf2= buf (y - evaluation, y);
Note: See TracChangeset for help on using the changeset viewer.