public interface PrimeCharacteristicField extends GenericField
PrimeCharacteristicFieldElement,
PrimeFieldequals, exponentiate, getBaseField, getCardinality, getFieldType, hashCode, invertElements, multiplyOutOfPlace, multiplyOutOfPlace, negateOutOfPlace, squareOutOfPlacegetFieldSizePrimeCharacteristicFieldElement divideBy2(PrimeCharacteristicFieldElement a)
a by 2.a - the dividenda and 2.PrimeCharacteristicFieldElement multiplyBy2(PrimeCharacteristicFieldElement a)
a by 2, which is a left-shift. Works in-place.a - the element to be shifteda holding the resultPrimeCharacteristicFieldElement multiplyBy2OutOfPlace(PrimeCharacteristicFieldElement a)
a by 2, which is a left-shift and
returns a new object holding the result.a - the element to be shifteda holding the resultPrimeCharacteristicFieldElement multiplyBy3(PrimeCharacteristicFieldElement a)
a by 3, which is a left-shift plus an
addition. Works in-place.a - the element to multiplieda holding the resultPrimeCharacteristicFieldElement multiplyBy3OutOfPlace(PrimeCharacteristicFieldElement a)
a by 3, which is a left-shift plus an
addition and returns a new object holding the result.a - the element to multiplieda holding the resultPrimeCharacteristicFieldElement multiplyByPowerOf2(PrimeCharacteristicFieldElement a, int exponent)
a by a power of 2, which is a
left-shift. Works in-place.a - the element to be shiftedexponent - the power of 2a holding the resultPrimeCharacteristicFieldElement multiplyByPowerOf2OutOfPlace(PrimeCharacteristicFieldElement a, int exponent)
a by a power of 2, which is a
left-shift and returns a new object holding the result.a - the element to be shiftedexponent - the power of 2a holding the resultPrimeCharacteristicFieldElement getZero()
GenericFieldgetZero in interface GenericFieldPrimeCharacteristicFieldElement getOne()
GenericFieldgetOne in interface GenericFieldPrimeCharacteristicFieldElement add(GenericFieldElement a, GenericFieldElement b)
GenericFieldb to a, i.e. performs the operation
a += b.add in interface GenericFielda - the first addendb - the second addenda and bPrimeCharacteristicFieldElement addOutOfPlace(PrimeCharacteristicFieldElement a, PrimeCharacteristicFieldElement b)
a - first summandb - second summandPrimeCharacteristicFieldElement subtract(GenericFieldElement a, GenericFieldElement b)
GenericFieldb from a, i.e. performs the operation
a -= b.subtract in interface GenericFielda - the minuendb - the subtrahenda and bPrimeCharacteristicFieldElement subtractOutOfPlace(GenericFieldElement a, GenericFieldElement b)
b from this and returns a new object
holding the result.a - the minuendb - the subtrahenda and bPrimeCharacteristicFieldElement negate(GenericFieldElement a)
GenericFielda, i.e. performs the operation b = -b.negate in interface GenericFielda - the field elementaPrimeCharacteristicFieldElement multiply(GenericFieldElement a, BigInteger n)
GenericFielda by n, i.e. performs the operation
a *= n.multiply in interface GenericFielda - the first factorn - the second factora and nPrimeCharacteristicFieldElement multiply(GenericFieldElement a, GenericFieldElement b)
GenericFielda by b, i.e. performs the operation
a *= b.multiply in interface GenericFielda - the first factorb - the second factora and bPrimeCharacteristicFieldElement square(GenericFieldElement a)
GenericFielda, i.e. performs the operation a *= a.square in interface GenericFielda - the field elementaPrimeCharacteristicFieldElement exponentiate(GenericFieldElement a, BigInteger n)
GenericFielda to the power n, i.e. performs the
operation a = a^n.exponentiate in interface GenericFielda - the field elementn - the exponentnth power of
aPrimeCharacteristicFieldElement divide(GenericFieldElement a, GenericFieldElement b)
GenericFielda by b, i.e. performs the operation
a /= b.divide in interface GenericFielda - the dividendb - the divisora and bPrimeCharacteristicFieldElement exponentiateByPowerOf2(GenericFieldElement a, int n)
GenericFielda to the power 2n.exponentiateByPowerOf2 in interface GenericFielda - the field elementn - the exponentPrimeCharacteristicFieldElement invert(GenericFieldElement a)
GenericFielda, i.e. performs the operation
a = a^(-1).invert in interface GenericFielda - the field elementaPrimeCharacteristicFieldElement newElement(byte[] bytes)
GenericFieldbyte-array representation.newElement in interface GenericFieldbytes - the byte[] in little-endian orderPrimeCharacteristicFieldElement toElement(byte[] bytes)
GenericFieldbyte-array. Unlike
GenericField.newElement(byte[]), this method does not assume the
input to be a valid encoding of a field element.toElement in interface GenericFieldbytes - a byte[] in little-endian orderint getQuadraticCharacter(PrimeCharacteristicFieldElement a)
ais a quadratic non-residue, a multiple of the
modulus, or a quadratic residue.a - a field element(a/p)PrimeCharacteristicFieldElement getUniformlyRandomElement()
PrimeCharacteristicFieldElement getUniformlyRandomNonZeroElement()
Copyright © 2011–2022 Stiftung SIC. All rights reserved.