pub type QM31 = BinomialExtensionField<Complex<Mersenne31>, 2>;Expand description
The degree-4 extension of Mersenne31: Mersenne31[i][u] with i² = -1
and u² = 2 + i.
Aliased Type§
pub struct QM31 { /* private fields */ }Trait Implementations§
Source§impl Add<Mersenne31> for QM31
impl Add<Mersenne31> for QM31
Source§type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
The resulting type after applying the
+ operator.Source§fn add(self, rhs: Mersenne31) -> Self
fn add(self, rhs: Mersenne31) -> Self
Performs the
+ operation. Read moreSource§impl AddAssign<Mersenne31> for QM31
impl AddAssign<Mersenne31> for QM31
Source§fn add_assign(&mut self, rhs: Mersenne31)
fn add_assign(&mut self, rhs: Mersenne31)
Performs the
+= operation. Read moreSource§impl Algebra<Mersenne31> for QM31
impl Algebra<Mersenne31> for QM31
Source§fn mixed_dot_product<const N: usize>(a: &[Self; N], f: &[F; N]) -> Selfwhere
F: Dup,
fn mixed_dot_product<const N: usize>(a: &[Self; N], f: &[F; N]) -> Selfwhere
F: Dup,
Dot product between algebra elements and base field scalars. Read more
Source§const BATCHED_LC_CHUNK: usize = 8
const BATCHED_LC_CHUNK: usize = 8
Optimal chunk size for
batched_linear_combination. Read moreSource§impl BasedVectorSpace<Mersenne31> for QM31
impl BasedVectorSpace<Mersenne31> for QM31
Source§const DIMENSION: usize = 4
const DIMENSION: usize = 4
The dimension of the vector space, i.e. the number of elements in
its basis.
Source§fn as_basis_coefficients_slice(&self) -> &[Mersenne31]
fn as_basis_coefficients_slice(&self) -> &[Mersenne31]
Fixes a basis for the algebra
A and uses this to
map an element of A to a slice of DIMENSION F elements. Read moreSource§fn from_basis_coefficients_fn<Fn: FnMut(usize) -> Mersenne31>(f: Fn) -> Self
fn from_basis_coefficients_fn<Fn: FnMut(usize) -> Mersenne31>(f: Fn) -> Self
Fixes a basis for the algebra
A and uses this to
map DIMENSION F elements to an element of A. Similar
to core:array::from_fn, the DIMENSION F elements are
given by Fn(0), ..., Fn(DIMENSION - 1) called in that order. Read moreSource§fn from_basis_coefficients_iter<I: ExactSizeIterator<Item = Mersenne31>>(
iter: I,
) -> Option<Self>
fn from_basis_coefficients_iter<I: ExactSizeIterator<Item = Mersenne31>>( iter: I, ) -> Option<Self>
Fixes a basis for the algebra
A and uses this to
map DIMENSION F elements to an element of A. Read moreSource§fn flatten_to_base(vec: Vec<Self>) -> Vec<Mersenne31>
fn flatten_to_base(vec: Vec<Self>) -> Vec<Mersenne31>
Source§fn reconstitute_from_base(vec: Vec<Mersenne31>) -> Vec<Self>
fn reconstitute_from_base(vec: Vec<Mersenne31>) -> Vec<Self>
Source§impl ExtensionField<Mersenne31> for QM31
impl ExtensionField<Mersenne31> for QM31
type ExtensionPacking = PackedQM31
Source§fn is_in_basefield(&self) -> bool
fn is_in_basefield(&self) -> bool
Determine if the given element lies in the base field.
Source§fn as_base(&self) -> Option<Mersenne31>
fn as_base(&self) -> Option<Mersenne31>
If the element lies in the base field project it down.
Otherwise return None.
Source§fn from_ext_basis_coefficients(coeffs: &[Self]) -> Option<Self>
fn from_ext_basis_coefficients(coeffs: &[Self]) -> Option<Self>
Reassemble an element of
Self from D = DIMENSION coefficients in Self
via Σⱼ basisⱼ · coeffsⱼ. Returns None if coeffs.len() != Self::DIMENSION. Read moreSource§impl From<Mersenne31> for QM31
impl From<Mersenne31> for QM31
Source§fn from(x: Mersenne31) -> Self
fn from(x: Mersenne31) -> Self
Converts to this type from the input type.
Source§impl Mul<Mersenne31> for QM31
impl Mul<Mersenne31> for QM31
Source§type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
The resulting type after applying the
* operator.Source§fn mul(self, rhs: Mersenne31) -> Self
fn mul(self, rhs: Mersenne31) -> Self
Performs the
* operation. Read moreSource§impl MulAssign<Mersenne31> for QM31
impl MulAssign<Mersenne31> for QM31
Source§fn mul_assign(&mut self, rhs: Mersenne31)
fn mul_assign(&mut self, rhs: Mersenne31)
Performs the
*= operation. Read moreSource§impl Sub<Mersenne31> for QM31
impl Sub<Mersenne31> for QM31
Source§type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
type Output = ExtField<ExtField<Mersenne31, 2, Binomial<Mersenne31>>, 2, Binomial<ExtField<Mersenne31, 2, Binomial<Mersenne31>>>>
The resulting type after applying the
- operator.Source§fn sub(self, rhs: Mersenne31) -> Self
fn sub(self, rhs: Mersenne31) -> Self
Performs the
- operation. Read moreSource§impl SubAssign<Mersenne31> for QM31
impl SubAssign<Mersenne31> for QM31
Source§fn sub_assign(&mut self, rhs: Mersenne31)
fn sub_assign(&mut self, rhs: Mersenne31)
Performs the
-= operation. Read more