Interface TernaryPolynomial
-
- All Superinterfaces:
Polynomial
- All Known Implementing Classes:
DenseTernaryPolynomial
,SparseTernaryPolynomial
public interface TernaryPolynomial extends Polynomial
A polynomial whose coefficients are all equal to -1, 0, or 1
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
clear()
int[]
getNegOnes()
int[]
getOnes()
IntegerPolynomial
mult(IntegerPolynomial poly2)
Multiplies the polynomial by anIntegerPolynomial
, taking the indices mod Nint
size()
Returns the maximum number of coefficients the polynomial can have-
Methods inherited from interface org.bouncycastle.pqc.math.ntru.polynomial.Polynomial
mult, mult, toIntegerPolynomial
-
-
-
-
Method Detail
-
mult
IntegerPolynomial mult(IntegerPolynomial poly2)
Multiplies the polynomial by anIntegerPolynomial
, taking the indices mod N- Specified by:
mult
in interfacePolynomial
- Parameters:
poly2
- a polynomial- Returns:
- the product of the two polynomials
-
getOnes
int[] getOnes()
-
getNegOnes
int[] getNegOnes()
-
size
int size()
Returns the maximum number of coefficients the polynomial can have
-
clear
void clear()
-
-