Trait snarkvm_wasm::PrimeField [−][src]
The interface for a prime field.
Associated Types
type Parameters: FpParameters
[src]
type BigInteger: BigInteger
[src]
Required methods
pub fn from_repr(repr: Self::BigInteger) -> Option<Self>
[src]
Returns a prime field element from its underlying representation.
pub fn into_repr(&self) -> Self::BigInteger
[src]
Returns the underlying representation of the prime field element.
pub fn from_repr_raw(repr: Self::BigInteger) -> Self
[src]
Returns a prime field element from its underlying raw representation.
pub fn into_repr_raw(&self) -> Self::BigInteger
[src]
Returns the underlying raw representation of the prime field element.
pub fn multiplicative_generator() -> Self
[src]
Returns the multiplicative generator of char()
- 1 order.
pub fn root_of_unity() -> Self
[src]
Returns the 2^s root of unity.
Provided methods
pub fn qnr_to_t() -> Self
[src]
Return the a QNR^T
pub fn size_in_bits() -> usize
[src]
Returns the field size in bits.
pub fn trace() -> Self::BigInteger
[src]
Returns the trace.
pub fn trace_minus_one_div_two() -> Self::BigInteger
[src]
Returns the trace minus one divided by two.
pub fn modulus_minus_one_div_two() -> Self::BigInteger
[src]
Returns the modulus minus one divided by two.
Implementors
impl<P> PrimeField for Fp256<P> where
P: Fp256Parameters,
[src]
P: Fp256Parameters,
type BigInteger = BigInteger256
type Parameters = P
pub fn from_repr(r: BigInteger256) -> Option<Fp256<P>>
[src]
pub fn into_repr(&self) -> BigInteger256
[src]
pub fn from_repr_raw(r: BigInteger256) -> Fp256<P>
[src]
pub fn into_repr_raw(&self) -> BigInteger256
[src]
pub fn multiplicative_generator() -> Fp256<P>
[src]
pub fn root_of_unity() -> Fp256<P>
[src]
impl<P> PrimeField for Fp320<P> where
P: Fp320Parameters,
[src]
P: Fp320Parameters,
type BigInteger = BigInteger320
type Parameters = P
pub fn from_repr(r: BigInteger320) -> Option<Fp320<P>>
[src]
pub fn into_repr(&self) -> BigInteger320
[src]
pub fn from_repr_raw(r: BigInteger320) -> Fp320<P>
[src]
pub fn into_repr_raw(&self) -> BigInteger320
[src]
pub fn multiplicative_generator() -> Fp320<P>
[src]
pub fn root_of_unity() -> Fp320<P>
[src]
impl<P> PrimeField for Fp384<P> where
P: Fp384Parameters,
[src]
P: Fp384Parameters,
type BigInteger = BigInteger384
type Parameters = P
pub fn from_repr(r: BigInteger384) -> Option<Fp384<P>>
[src]
pub fn into_repr(&self) -> BigInteger384
[src]
pub fn from_repr_raw(r: BigInteger384) -> Fp384<P>
[src]
pub fn into_repr_raw(&self) -> BigInteger384
[src]
pub fn multiplicative_generator() -> Fp384<P>
[src]
pub fn root_of_unity() -> Fp384<P>
[src]
impl<P> PrimeField for Fp768<P> where
P: Fp768Parameters,
[src]
P: Fp768Parameters,
type BigInteger = BigInteger768
type Parameters = P
pub fn from_repr(r: BigInteger768) -> Option<Fp768<P>>
[src]
pub fn into_repr(&self) -> BigInteger768
[src]
pub fn from_repr_raw(r: BigInteger768) -> Fp768<P>
[src]
pub fn into_repr_raw(&self) -> BigInteger768
[src]
pub fn multiplicative_generator() -> Fp768<P>
[src]
pub fn root_of_unity() -> Fp768<P>
[src]
pub fn size_in_bits() -> usize
[src]
pub fn trace() -> BigInteger768
[src]
pub fn trace_minus_one_div_two() -> BigInteger768
[src]
pub fn modulus_minus_one_div_two() -> BigInteger768
[src]
impl<P> PrimeField for Fp832<P> where
P: Fp832Parameters,
[src]
P: Fp832Parameters,