public static class ECFieldElement.F2m extends ECFieldElement
F2m in polynomial basis (PB)
representation. Both trinomial (TPB) and pentanomial (PPB) polynomial
basis representations are supported. Gaussian normal basis (GNB)
representation is not supported.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 k,
BigInteger x)
Constructor for TPB.
|
F2m(int m,
int k1,
int k2,
int k3,
BigInteger x)
Constructor for PPB.
|
| Modifier and Type | Method and Description |
|---|---|
ECFieldElement |
add(ECFieldElement b) |
ECFieldElement |
divide(ECFieldElement b) |
boolean |
equals(Object anObject) |
String |
getFieldName() |
int |
getFieldSize() |
int |
getK1() |
int |
getK2() |
int |
getK3() |
int |
getM() |
int |
getRepresentation() |
int |
hashCode() |
static void |
checkFieldElements(ECFieldElement a,
ECFieldElement b)
Checks, if the ECFieldElements
a and b
are elements of the same field F2m
(having the same representation). |
ECFieldElement |
invert() |
ECFieldElement |
multiply(ECFieldElement b) |
ECFieldElement |
negate() |
ECFieldElement |
sqrt() |
ECFieldElement |
square() |
ECFieldElement |
subtract(ECFieldElement b) |
BigInteger |
toBigInteger() |
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,
BigInteger x)
m - The exponent m of
F2m.k1 - The integer k1 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).k2 - The integer k2 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).k3 - The integer k3 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).x - The BigInteger representing the value of the field element.public F2m(int m,
int k,
BigInteger x)
m - The exponent m of
F2m.k - The integer k where xm +
xk + 1 represents the reduction
polynomial f(z).x - The BigInteger representing the value of the field element.public BigInteger toBigInteger()
toBigInteger in class ECFieldElementpublic String getFieldName()
getFieldName in class ECFieldElementpublic int getFieldSize()
getFieldSize in class ECFieldElementpublic static void checkFieldElements(ECFieldElement a, ECFieldElement b)
a and b
are elements of the same field F2m
(having the same representation).a - field element.b - field element to be compared.IllegalArgumentException - if a and b
are not elements of the same field
F2m (having the same
representation).public ECFieldElement add(ECFieldElement b)
add in class ECFieldElementpublic ECFieldElement subtract(ECFieldElement b)
subtract in class ECFieldElementpublic ECFieldElement multiply(ECFieldElement b)
multiply in class ECFieldElementpublic ECFieldElement divide(ECFieldElement b)
divide in class ECFieldElementpublic ECFieldElement negate()
negate in class ECFieldElementpublic ECFieldElement square()
square in class ECFieldElementpublic ECFieldElement invert()
invert in class ECFieldElementpublic ECFieldElement sqrt()
sqrt in class ECFieldElementpublic int getRepresentation()
F2m, either of
TPB (trinomial
basis representation) or
PPB (pentanomial
basis representation).public int getM()
m of the reduction polynomial
f(z).public int getK1()
k where xm +
xk + 1 represents the reduction polynomial
f(z).k1 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).public int getK2()
0k2 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).public int getK3()
0k3 where xm +
xk3 + xk2 + xk1 + 1
represents the reduction polynomial f(z).Copyright © 2015. All rights reserved.