public static class ECFieldElement.F2m extends ECFieldElement.AbstractF2m
ECFieldElement.AbstractF2m, ECFieldElement.AbstractFp, ECFieldElement.F2m, ECFieldElement.Fp| Modifier and Type | Field and Description |
|---|---|
static int |
GNB
Indicates gaussian normal basis representation (GNB).
|
static int |
PPB
Indicates pentanomial basis representation (PPB).
|
static int |
TPB
Indicates trinomial basis representation (TPB).
|
| Constructor and Description |
|---|
F2m(int m,
int k1,
int k2,
int k3,
java.math.BigInteger x)
Deprecated.
Use ECCurve.fromBigInteger to construct field elements
|
halfTrace, hasFastTrace, tracegetEncoded, toStringpublic static final int GNB
public static final int TPB
public static final int PPB
public F2m(int m,
int k1,
int k2,
int k3,
java.math.BigInteger x)
m - The exponent m of
F 2 m.k1 - The integer k1 where x m +
x k3 + x k2 + x k1 + 1
represents the reduction polynomial f(z).k2 - The integer k2 where x m +
x k3 + x k2 + x k1 + 1
represents the reduction polynomial f(z).k3 - The integer k3 where x m +
x k3 + x k2 + x k1 + 1
represents the reduction polynomial f(z).x - The BigInteger representing the value of the field element.public int bitLength()
bitLength in class ECFieldElementpublic boolean isOne()
isOne in class ECFieldElementpublic boolean isZero()
isZero in class ECFieldElementpublic boolean testBitZero()
testBitZero in class ECFieldElementpublic java.math.BigInteger toBigInteger()
toBigInteger in class ECFieldElementpublic java.lang.String getFieldName()
getFieldName in class ECFieldElementpublic int getFieldSize()
getFieldSize in class ECFieldElementpublic static void checkFieldElements(ECFieldElement a, ECFieldElement b)
a - field element.b - field element to be compared.java.lang.IllegalArgumentException - if a and b
are not elements of the same field
F 2 m (having the same
representation).public ECFieldElement add(ECFieldElement b)
add in class ECFieldElementpublic ECFieldElement addOne()
addOne in class ECFieldElementpublic ECFieldElement subtract(ECFieldElement b)
subtract in class ECFieldElementpublic ECFieldElement multiply(ECFieldElement b)
multiply in class ECFieldElementpublic ECFieldElement multiplyMinusProduct(ECFieldElement b, ECFieldElement x, ECFieldElement y)
multiplyMinusProduct in class ECFieldElementpublic ECFieldElement multiplyPlusProduct(ECFieldElement b, ECFieldElement x, ECFieldElement y)
multiplyPlusProduct in class ECFieldElementpublic ECFieldElement divide(ECFieldElement b)
divide in class ECFieldElementpublic ECFieldElement negate()
negate in class ECFieldElementpublic ECFieldElement square()
square in class ECFieldElementpublic ECFieldElement squareMinusProduct(ECFieldElement x, ECFieldElement y)
squareMinusProduct in class ECFieldElementpublic ECFieldElement squarePlusProduct(ECFieldElement x, ECFieldElement y)
squarePlusProduct in class ECFieldElementpublic ECFieldElement squarePow(int pow)
squarePow in class ECFieldElementpublic ECFieldElement invert()
invert in class ECFieldElementpublic ECFieldElement sqrt()
sqrt in class ECFieldElementpublic int getRepresentation()
public int getM()
public int getK1()
public int getK2()
public int getK3()
public boolean equals(java.lang.Object anObject)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Object