public interface FieldElement extends GenericFieldElement
Field,
BinaryFieldElement,
PrimeFieldElement| Modifier and Type | Method and Description |
|---|---|
FieldElement |
add(GenericFieldElement b)
Adds
b to this. |
FieldElement |
addBase(GenericFieldElement B)
Adds
b to this where b is an element
of the underlying base field. |
FieldElement |
clone()
Clones the value of this field element.
|
FieldElement |
divide(GenericFieldElement b)
Divides
this and another field elements. |
FieldElement |
exponentiate(BigInteger n)
Raises
this to the power n. |
int |
getBit(int index)
Returns the value of a certain bit of
this. |
FieldElement |
invert()
Sets
this to its inverse. |
FieldElement |
multiply(BigInteger n)
Multiples
this by n. |
FieldElement |
multiply(GenericFieldElement b)
Multiplies
this with b which is an element of the
same field. |
FieldElement |
multiplyByBase(GenericFieldElement b)
Multiplies
this with b which is an element of the
base field. |
FieldElement |
multiplyByBaseOutOfPlace(GenericFieldElement b)
Multiplies
this with b which is an element of the
base field, where a new object holding the result is created. |
FieldElement |
multiplyOutOfPlace(BigInteger n)
Multiples
this by n, where a new object holding
the result is created. |
FieldElement |
multiplyOutOfPlace(GenericFieldElement b)
Multiplies
this with b which is an element of the
same field, where a new object holding the result is created. |
FieldElement |
negate()
Returns the negative of
this. |
FieldElement |
square()
Computes the square of
this in-place. |
FieldElement |
squareOutOfPlace()
Computes the square of
this, where a new object holding the
result is created. |
FieldElement |
squareRoot()
Computes the square root of
this. |
FieldElement |
subtract(GenericFieldElement b)
Subtracts
b from this. |
boolean |
testBit(int index)
Tests whether a certain bit of
this is set. |
BigInteger |
toBigInteger()
Returns the
BigInteger-representation of this instance. |
addOutOfPlace, equals, exponentiate, exponentiateByPowerOf2, exponentiateOutOfPlace, exponentiateOutOfPlace, getField, hashCode, isOne, isZero, negateOutOfPlace, subtractOutOfPlace, toByteArray, toStringFieldElement negate()
GenericFieldElementthis. This functions works in-place.negate in interface GenericFieldElementthisFieldElement add(GenericFieldElement b)
GenericFieldElementb to this. This functions works in-place.add in interface GenericFieldElementb - the second addendthis and bFieldElement addBase(GenericFieldElement B)
GenericFieldElementb to this where b is an element
of the underlying base field.addBase in interface GenericFieldElementB - the second addendthis and bFieldElement subtract(GenericFieldElement b)
GenericFieldElementb from this. This functions works in-place.subtract in interface GenericFieldElementb - the subtrahendthis and bFieldElement invert()
GenericFieldElementthis to its inverse.invert in interface GenericFieldElementthisFieldElement multiply(GenericFieldElement b)
GenericFieldElementthis with b which is an element of the
same field.multiply in interface GenericFieldElementb - the second factorthis and bFieldElement multiplyOutOfPlace(GenericFieldElement b)
GenericFieldElementthis with b which is an element of the
same field, where a new object holding the result is created.multiplyOutOfPlace in interface GenericFieldElementb - the second factorthis and bFieldElement multiply(BigInteger n)
GenericFieldElementthis by n.multiply in interface GenericFieldElementn - the factorthis and nFieldElement multiplyOutOfPlace(BigInteger n)
GenericFieldElementthis by n, where a new object holding
the result is created.multiplyOutOfPlace in interface GenericFieldElementn - the factorthis and nFieldElement multiplyByBase(GenericFieldElement b)
GenericFieldElementthis with b which is an element of the
base field.multiplyByBase in interface GenericFieldElementb - the second factorthis and bFieldElement multiplyByBaseOutOfPlace(GenericFieldElement b)
GenericFieldElementthis with b which is an element of the
base field, where a new object holding the result is created.multiplyByBaseOutOfPlace in interface GenericFieldElementb - the second factorthis and bFieldElement divide(GenericFieldElement b)
GenericFieldElementthis and another field elements.divide in interface GenericFieldElementb - the divisorthis and bFieldElement square()
GenericFieldElementthis in-place.square in interface GenericFieldElementthisFieldElement squareOutOfPlace()
GenericFieldElementthis, where a new object holding the
result is created.squareOutOfPlace in interface GenericFieldElementthisFieldElement exponentiate(BigInteger n)
GenericFieldElementthis to the power n.
Works in-place.exponentiate in interface GenericFieldElementn - the exponentnth power of thisFieldElement squareRoot()
this.squareRoot in interface GenericFieldElementthisboolean testBit(int index)
this is set.index - the index of the bitint getBit(int index)
this.index - the index of the bitBigInteger toBigInteger()
BigInteger-representation of this instance.BigInteger-representationFieldElement clone()
clone in interface GenericFieldElementCopyright © 2011–2022 Stiftung SIC. All rights reserved.