public interface ExtensionFieldElement extends PrimeCharacteristicFieldElement
Modifier and Type | Method and Description |
---|---|
ExtensionFieldElement |
add(GenericFieldElement b)
Adds
b to this . |
ExtensionFieldElement |
addBase(GenericFieldElement b)
Adds
b to this where b is an element
of the underlying base field. |
ExtensionFieldElement |
addOutOfPlace(ExtensionFieldElement b)
Adds two elements and returns a new object holding the result.
|
ExtensionFieldElement |
addOutOfPlace(GenericFieldElement b)
Adds two elements and returns a new object holding the result.
|
ExtensionFieldElement |
applyFrobenius(int i)
Compute the
i -th Frobenius of this . |
ExtensionFieldElement |
clone()
Clones the value of this field element.
|
ExtensionFieldElement |
conjugate()
Conjugate this element.
|
ExtensionFieldElement |
conjugate(int i)
Conjugate this element
i times. |
ExtensionFieldElement |
divide(GenericFieldElement b)
Divides
this and another field elements. |
ExtensionFieldElement |
divideBy2()
Divides
this by 2. |
ExtensionFieldElement |
exponentiate(BigInteger n)
Raises
this to the power n . |
ExtensionFieldElement |
exponentiate(int n)
Raises
this to the power n . |
ExtensionFieldElement |
exponentiateByPowerOf2(int n)
Raise
this to the power of 2^n . |
ExtensionFieldElement |
exponentiateOutOfPlace(BigInteger n)
Raises
this to the power n . |
ExtensionFieldElement |
exponentiateOutOfPlace(int n)
Raises
this to the power n . |
PrimeFieldElement |
getNorm()
Computes the norm of
this , which is an element of the base
field. |
PrimeCharacteristicFieldElement |
getValue(int index)
Get
index -th subfield element used to represent
this . |
GenericFieldElement[] |
getValues()
Get subfield elements used to represent
this . |
PrimeFieldElement[] |
getValuesRecursive()
Get prime field elements used to represent
this . |
ExtensionFieldElement |
invert()
Sets
this to its inverse. |
ExtensionFieldElement |
multiply(BigInteger n)
Multiples
this by n . |
ExtensionFieldElement |
multiply(GenericFieldElement b)
Multiplies
this with b which is an element of the
same field. |
ExtensionFieldElement |
multiplyBy2()
Multiplies
this with 2. |
ExtensionFieldElement |
multiplyBy3()
Multiplies
this with 3. |
ExtensionFieldElement |
multiplyByAdjointRoot()
Multiply
this by the root used to obtain the extension field. |
ExtensionFieldElement |
multiplyByBase(GenericFieldElement b)
Multiplies
this with b which is an element of the
base field. |
ExtensionFieldElement |
multiplyByPowerOf2(int exponent)
Multiplies
this by 2^n . |
ExtensionFieldElement |
multiplyOutOfPlace(GenericFieldElement b)
Multiplies
this with b which is an element of the
same field, where a new object holding the result is created. |
ExtensionFieldElement |
negate()
Returns the negative of
this . |
ExtensionFieldElement |
square()
Computes the square of
this in-place. |
ExtensionFieldElement |
squareOutOfPlace()
Computes the square of
this , where a new object holding the
result is created. |
ExtensionFieldElement |
squareRoot()
Computes the square root of
this in-place. |
ExtensionFieldElement |
subtract(GenericFieldElement b)
Subtracts
b from this . |
ExtensionFieldElement |
subtractOutOfPlace(ExtensionFieldElement b)
Subtract two elements and returns a new object holding the result.
|
ExtensionFieldElement |
subtractOutOfPlace(GenericFieldElement b)
Subtracts
b from this which is an element of the
base field, where a new object holding the result is created. |
Object |
toBigIntegers()
Returns the (multi-dimensional)
BigInteger -array representation of
this instance. |
byte[] |
toByteArray()
Returns
byte -array representation of this instance. |
addOutOfPlace, getQuadraticCharacter, multiplyBy2OutOfPlace, multiplyBy3OutOfPlace, multiplyByBaseOutOfPlace, multiplyByPowerOf2OutOfPlace, multiplyOutOfPlace, negateOutOfPlace, squareRoot, subtractOutOfPlace
ExtensionFieldElement negate()
GenericFieldElement
this
. This functions works in-place.negate
in interface GenericFieldElement
negate
in interface PrimeCharacteristicFieldElement
this
ExtensionFieldElement add(GenericFieldElement b)
GenericFieldElement
b
to this
. This functions works in-place.add
in interface GenericFieldElement
add
in interface PrimeCharacteristicFieldElement
b
- the second addendthis
and b
ExtensionFieldElement addOutOfPlace(GenericFieldElement b)
PrimeCharacteristicFieldElement
addOutOfPlace
in interface GenericFieldElement
addOutOfPlace
in interface PrimeCharacteristicFieldElement
b
- the other valueExtensionFieldElement addOutOfPlace(ExtensionFieldElement b)
b
- the other valueExtensionFieldElement addBase(GenericFieldElement b)
GenericFieldElement
b
to this
where b
is an element
of the underlying base field.addBase
in interface GenericFieldElement
addBase
in interface PrimeCharacteristicFieldElement
b
- the second addendthis
and b
ExtensionFieldElement subtract(GenericFieldElement b)
GenericFieldElement
b
from this
. This functions works in-place.subtract
in interface GenericFieldElement
subtract
in interface PrimeCharacteristicFieldElement
b
- the subtrahendthis
and b
ExtensionFieldElement subtractOutOfPlace(GenericFieldElement b)
GenericFieldElement
b
from this
which is an element of the
base field, where a new object holding the result is created.subtractOutOfPlace
in interface GenericFieldElement
subtractOutOfPlace
in interface PrimeCharacteristicFieldElement
b
- the second factorthis
and b
ExtensionFieldElement subtractOutOfPlace(ExtensionFieldElement b)
b
- the other valueExtensionFieldElement invert()
GenericFieldElement
this
to its inverse.invert
in interface GenericFieldElement
invert
in interface PrimeCharacteristicFieldElement
this
ExtensionFieldElement multiply(GenericFieldElement b)
GenericFieldElement
this
with b
which is an element of the
same field.multiply
in interface GenericFieldElement
multiply
in interface PrimeCharacteristicFieldElement
b
- the second factorthis
and b
ExtensionFieldElement multiplyOutOfPlace(GenericFieldElement b)
GenericFieldElement
this
with b
which is an element of the
same field, where a new object holding the result is created.multiplyOutOfPlace
in interface GenericFieldElement
multiplyOutOfPlace
in interface PrimeCharacteristicFieldElement
b
- the second factorthis
and b
ExtensionFieldElement multiplyByBase(GenericFieldElement b)
GenericFieldElement
this
with b
which is an element of the
base field.multiplyByBase
in interface GenericFieldElement
multiplyByBase
in interface PrimeCharacteristicFieldElement
b
- the second factorthis
and b
ExtensionFieldElement multiply(BigInteger n)
GenericFieldElement
this
by n
.multiply
in interface GenericFieldElement
multiply
in interface PrimeCharacteristicFieldElement
n
- the factorthis
and n
ExtensionFieldElement multiplyBy2()
PrimeCharacteristicFieldElement
this
with 2.multiplyBy2
in interface PrimeCharacteristicFieldElement
this
and 2ExtensionFieldElement multiplyBy3()
PrimeCharacteristicFieldElement
this
with 3.multiplyBy3
in interface PrimeCharacteristicFieldElement
this
and 3ExtensionFieldElement multiplyByPowerOf2(int exponent)
PrimeCharacteristicFieldElement
this
by 2^n
.multiplyByPowerOf2
in interface PrimeCharacteristicFieldElement
exponent
- the exponentthis
and 2^nExtensionFieldElement multiplyByAdjointRoot()
this
by the root used to obtain the extension field.this
multiplied by the adjoint root.ExtensionFieldElement divide(GenericFieldElement b)
this
and another field elements.
You have no guarantee that b
remains unchanged.
divide
in interface GenericFieldElement
divide
in interface PrimeCharacteristicFieldElement
b
- the divisorthis
and b
ExtensionFieldElement divideBy2()
PrimeCharacteristicFieldElement
this
by 2.divideBy2
in interface PrimeCharacteristicFieldElement
this
divided by 2.GenericFieldElement[] getValues()
this
.this
PrimeFieldElement[] getValuesRecursive()
this
. This calls
getValues()
recursively.
They values are sorted from the coefficients of the lowest power to the the
highest power.this
.PrimeCharacteristicFieldElement getValue(int index)
index
-th subfield element used to represent
this
.index
- index of the desired subfield elementindex
-th subfield element used to represent
this
PrimeFieldElement getNorm()
this
, which is an element of the base
field.a
ExtensionFieldElement conjugate()
this
ExtensionFieldElement conjugate(int i)
i
times.i
- number of times this
should be conjugatedthis
ExtensionFieldElement square()
GenericFieldElement
this
in-place.square
in interface GenericFieldElement
square
in interface PrimeCharacteristicFieldElement
this
ExtensionFieldElement squareOutOfPlace()
GenericFieldElement
this
, where a new object holding the
result is created.squareOutOfPlace
in interface GenericFieldElement
squareOutOfPlace
in interface PrimeCharacteristicFieldElement
this
ExtensionFieldElement squareRoot()
GenericFieldElement
this
in-place.squareRoot
in interface GenericFieldElement
squareRoot
in interface PrimeCharacteristicFieldElement
this
or null
if the
square root does not exist.ExtensionFieldElement exponentiate(int n)
GenericFieldElement
this
to the power n
.
Works in-place.exponentiate
in interface GenericFieldElement
exponentiate
in interface PrimeCharacteristicFieldElement
n
- the exponentn
th power of this
ExtensionFieldElement exponentiate(BigInteger n)
GenericFieldElement
this
to the power n
.
Works in-place.exponentiate
in interface GenericFieldElement
exponentiate
in interface PrimeCharacteristicFieldElement
n
- the exponentn
th power of this
ExtensionFieldElement exponentiateOutOfPlace(int n)
GenericFieldElement
this
to the power n
.exponentiateOutOfPlace
in interface GenericFieldElement
n
- the exponentn
th power of this
ExtensionFieldElement exponentiateOutOfPlace(BigInteger n)
GenericFieldElement
this
to the power n
.exponentiateOutOfPlace
in interface GenericFieldElement
n
- the exponentn
th power of this
ExtensionFieldElement exponentiateByPowerOf2(int n)
GenericFieldElement
this
to the power of 2^n
.exponentiateByPowerOf2
in interface GenericFieldElement
exponentiateByPowerOf2
in interface PrimeCharacteristicFieldElement
n
- the exponentn
-th power of this
.ExtensionFieldElement applyFrobenius(int i)
i
-th Frobenius of this
.i
- number of times the Frobenius map should be appliedi
-times to this
..Object toBigIntegers()
BigInteger
-array representation of
this instance.BigInteger
-array representationbyte[] toByteArray()
byte
-array representation of this instance.toByteArray
in interface GenericFieldElement
byte
-array representationExtensionFieldElement clone()
clone
in interface GenericFieldElement
clone
in interface PrimeCharacteristicFieldElement
Copyright © 2011–2022 Stiftung SIC. All rights reserved.