Skip to content

Commit

Permalink
To #20
Browse files Browse the repository at this point in the history
  • Loading branch information
PoslavskySV committed Dec 2, 2017
1 parent b376a38 commit a56dca6
Showing 1 changed file with 21 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@

import cc.redberry.rings.*;
import cc.redberry.rings.bigint.BigInteger;
import cc.redberry.rings.poly.FiniteField;
import cc.redberry.rings.poly.IPolynomial;
import cc.redberry.rings.poly.MultivariateRing;
import cc.redberry.rings.poly.UnivariateRing;
import cc.redberry.rings.poly.*;
import cc.redberry.rings.poly.test.APolynomialTest;
import cc.redberry.rings.poly.univar.UnivariatePolynomial;
import cc.redberry.rings.poly.univar.UnivariatePolynomialZ64;
Expand Down Expand Up @@ -2143,6 +2140,26 @@ public void testEEZGCD_random4() throws Exception {
);
}

@Ignore("issue #20")
@Test
public void testSmallDomain6() throws Exception {
IntegersZp64 ring = Rings.Zp64(3);
MultivariatePolynomialZp64
a = MultivariatePolynomialZp64.parse("1 + a + 5*b + 7*c + d + 11*e + 13*f + g", ring),
b = MultivariatePolynomialZp64.parse("1 - a + 5*b - 7*c + d - 11*e + 13*f - g", ring),
g = MultivariatePolynomialZp64.parse("1 + a - 5*b + 7*c - d + 11*e - 13*f + g", ring);

int exp = 7;
a = PolynomialMethods.polyPow(a, exp);
b = PolynomialMethods.polyPow(b, exp);
g = PolynomialMethods.polyPow(g, exp);

MultivariatePolynomialZp64 ag = a.clone().multiply(g);
MultivariatePolynomialZp64 bg = b.clone().multiply(g);

System.out.println(PolynomialGCD(ag, bg));
}

/* =============================================== Test data =============================================== */

/** sample data for test of GCD */
Expand Down

0 comments on commit a56dca6

Please sign in to comment.