TernaryPolynomial with a "high" number of nonzero coefficients.
| Access | Constructor and Description |
|---|---|
| pack-priv | DenseTernaryPolynomial(int
the number of coefficients N)Constructs a new |
| public | DenseTernaryPolynomial(IntegerPolynomial
the original polynomial intPoly)Constructs a |
| public | DenseTernaryPolynomial(int[]
the coefficients coeffs)Constructs a new |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| public static DenseTernaryPolynomial | generateRandom(int
number of coefficients N, int number of 1's numOnes, int number of -1's numNegOnes, SecureRandom random)Generates a random polynomial with |
| public static DenseTernaryPolynomial | generateRandom(int
number of coefficients N, SecureRandom random)Generates a polynomial with coefficients randomly selected from |
| public int[] | |
| public int[] | |
| public IntegerPolynomial | mult(IntegerPolynomial
a polynomial poly2, int a modulus to apply modulus)Overrides org. Implements org. Multiplies the polynomial by an |
| public int | size()
Implements org. Returns the maximum number of coefficients the polynomial can have |
| DenseTernaryPolynomial | back to summary |
|---|---|
| pack-priv DenseTernaryPolynomial(int N) Constructs a new
| |
| DenseTernaryPolynomial | back to summary |
|---|---|
| public DenseTernaryPolynomial(IntegerPolynomial intPoly) Constructs a
| |
| DenseTernaryPolynomial | back to summary |
|---|---|
| public DenseTernaryPolynomial(int[] coeffs) Constructs a new
| |
| checkTernarity | back to summary |
|---|---|
| private void checkTernarity() | |
| generateRandom | back to summary |
|---|---|
| public static DenseTernaryPolynomial generateRandom(int N, int numOnes, int numNegOnes, SecureRandom random) Generates a random polynomial with
| |
| generateRandom | back to summary |
|---|---|
| public static DenseTernaryPolynomial generateRandom(int N, SecureRandom random) Generates a polynomial with coefficients randomly selected from
| |
| getNegOnes | back to summary |
|---|---|
| public int[] getNegOnes() Implements org. | |
| getOnes | back to summary |
|---|---|
| public int[] getOnes() Implements org. | |
| mult | back to summary |
|---|---|
| public IntegerPolynomial mult(IntegerPolynomial poly2, int modulus) Overrides org. Implements org. Doc from org. Multiplies the polynomial by an
| |
| size | back to summary |
|---|---|
| public int size() Implements org. Doc from org. Returns the maximum number of coefficients the polynomial can have | |