Type Alias Fq12

Source
pub type Fq12 = QuadExtField<Fq6>;
Expand description

An element of Fq12, represented by c0 + c1 * w.

Aliased Type§

struct Fq12 { /* private fields */ }

Implementations§

Source§

impl Fq12

Source

pub fn cyclotomic_square(&mut self)

Source§

impl<F: Field> QuadExtField<F>

Source

pub const fn new(c0: F, c1: F) -> Self

Source

pub const fn zero() -> Self

Source

pub const fn one() -> Self

Source

pub fn c0(&self) -> &F

Source

pub fn c1(&self) -> &F

Source

pub fn double(&self) -> Self

Source

pub fn add(&self, other: &Self) -> Self

Source

pub fn sub(&self, other: &Self) -> Self

Source

pub fn neg(&self) -> Self

Source

pub fn conjugate(&mut self)

Source§

impl<F: ExtField> QuadExtField<F>
where Self: QuadExtFieldArith<Base = F>,

Source

pub fn mul(&self, rhs: &Self) -> Self

Source

pub fn mul_assign(&mut self, rhs: &Self)

Source

pub fn square(el: &Self) -> Self

Source

pub fn square_assign(&mut self)

Source

pub fn norm(&self) -> F

Trait Implementations§

Source§

impl<'a, 'b> Add<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'b Fq12) -> Fq12

Performs the + operation. Read more
Source§

impl<'b> Add<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'b Fq12) -> Fq12

Performs the + operation. Read more
Source§

impl<'a> Add<QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Fq12) -> Fq12

Performs the + operation. Read more
Source§

impl Add for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Fq12) -> Fq12

Performs the + operation. Read more
Source§

impl<'b> AddAssign<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

fn add_assign(&mut self, rhs: &'b Fq12)

Performs the += operation. Read more
Source§

impl AddAssign for Fq12

Source§

fn add_assign(&mut self, rhs: Fq12)

Performs the += operation. Read more
Source§

impl ExtField for Fq12

Source§

const NON_RESIDUE: Self

Source§

fn frobenius_map(&mut self, power: usize)

Source§

fn mul_by_nonresidue(&self) -> Self

Source§

impl MillerLoopResult for Fq12

Source§

type Gt = Gt

The extension field that hosts the target group of the pairing.
Source§

fn final_exponentiation(&self) -> Self::Gt

This performs a “final exponentiation” routine to convert the result of a Miller loop into an element of MillerLoopResult::Gt, so that it can be compared with other elements of Gt.
Source§

impl<'a, 'b> Mul<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'b Fq12) -> Fq12

Performs the * operation. Read more
Source§

impl<'b> Mul<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'b Fq12) -> Fq12

Performs the * operation. Read more
Source§

impl<'a> Mul<QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Fq12) -> Fq12

Performs the * operation. Read more
Source§

impl Mul for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Fq12) -> Fq12

Performs the * operation. Read more
Source§

impl<'b> MulAssign<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

fn mul_assign(&mut self, rhs: &'b Fq12)

Performs the *= operation. Read more
Source§

impl MulAssign for Fq12

Source§

fn mul_assign(&mut self, rhs: Fq12)

Performs the *= operation. Read more
Source§

impl<'a> Neg for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn neg(self) -> Fq12

Performs the unary - operation. Read more
Source§

impl Neg for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn neg(self) -> Fq12

Performs the unary - operation. Read more
Source§

impl<T: Borrow<Fq12>> Product<T> for Fq12

Source§

fn product<I: Iterator<Item = T>>(iter: I) -> Self

Takes an iterator and generates Self from the elements by multiplying the items.
Source§

impl QuadExtFieldArith for Fq12

Source§

type Base = CubicExtField<QuadExtField<Fq>>

Source§

const SQRT: SQRT<Self::Base> = SQRT::Unimplemented

Source§

fn mul_assign( lhs: &mut QuadExtField<Self::Base>, rhs: &QuadExtField<Self::Base>, )

Source§

fn square_assign(el: &mut QuadExtField<Self::Base>)

Source§

impl QuadSparseMul for Fq12

Source§

type Base = QuadExtField<Fq>

Source§

fn mul_by_014( lhs: &mut QuadExtField<CubicExtField<Self::Base>>, c0: &Self::Base, c1: &Self::Base, c4: &Self::Base, )
where CubicExtField<Self::Base>: CubicSparseMul<Base = Self::Base> + ExtField,

Source§

fn mul_by_034( lhs: &mut QuadExtField<CubicExtField<Self::Base>>, c0: &Self::Base, c3: &Self::Base, c4: &Self::Base, )
where CubicExtField<Self::Base>: CubicSparseMul<Base = Self::Base> + ExtField,

Source§

impl<'a, 'b> Sub<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'b Fq12) -> Fq12

Performs the - operation. Read more
Source§

impl<'b> Sub<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'b Fq12) -> Fq12

Performs the - operation. Read more
Source§

impl<'a> Sub<QuadExtField<CubicExtField<QuadExtField<Fq>>>> for &'a Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Fq12) -> Fq12

Performs the - operation. Read more
Source§

impl Sub for Fq12

Source§

type Output = QuadExtField<CubicExtField<QuadExtField<Fq>>>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Fq12) -> Fq12

Performs the - operation. Read more
Source§

impl<'b> SubAssign<&'b QuadExtField<CubicExtField<QuadExtField<Fq>>>> for Fq12

Source§

fn sub_assign(&mut self, rhs: &'b Fq12)

Performs the -= operation. Read more
Source§

impl SubAssign for Fq12

Source§

fn sub_assign(&mut self, rhs: Fq12)

Performs the -= operation. Read more
Source§

impl<T: Borrow<Fq12>> Sum<T> for Fq12

Source§

fn sum<I: Iterator<Item = T>>(iter: I) -> Self

Takes an iterator and generates Self from the elements by “summing up” the items.
Source§

impl<F: Clone + Field> Clone for QuadExtField<F>

Source§

fn clone(&self) -> QuadExtField<F>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<F: Field> ConditionallySelectable for QuadExtField<F>

Source§

fn conditional_select(a: &Self, b: &Self, choice: Choice) -> Self

Select a or b according to choice. Read more
Source§

fn conditional_assign(&mut self, other: &Self, choice: Choice)

Conditionally assign other to self, according to choice. Read more
Source§

fn conditional_swap(a: &mut Self, b: &mut Self, choice: Choice)

Conditionally swap self and other if choice == 1; otherwise, reassign both unto themselves. Read more
Source§

impl<F: Field> ConstantTimeEq for QuadExtField<F>

Source§

fn ct_eq(&self, other: &Self) -> Choice

Determine if two items are equal. Read more
Source§

fn ct_ne(&self, other: &Self) -> Choice

Determine if two items are NOT equal. Read more
Source§

impl<F: Debug + Field> Debug for QuadExtField<F>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<F: Default + Field> Default for QuadExtField<F>

Source§

fn default() -> QuadExtField<F>

Returns the “default value” for a type. Read more
Source§

impl<'de, F> Deserialize<'de> for QuadExtField<F>
where F: Deserialize<'de> + Field,

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl<F: ExtField> Field for QuadExtField<F>
where QuadExtField<F>: QuadExtFieldArith<Base = F> + ExtField,

Source§

const ZERO: Self

The zero element of the field, the additive identity.
Source§

const ONE: Self

The one element of the field, the multiplicative identity.
Source§

fn random(rng: impl RngCore) -> Self

Returns an element chosen uniformly at random using a user-provided RNG.
Source§

fn is_zero(&self) -> Choice

Returns true iff this element is zero.
Source§

fn square(&self) -> Self

Squares this element.
Source§

fn double(&self) -> Self

Doubles this element.
Source§

fn sqrt(&self) -> CtOption<Self>

Returns the square root of the field element, if it is quadratic residue. Read more
Source§

fn sqrt_ratio(_: &Self, _: &Self) -> (Choice, Self)

Computes: Read more
Source§

fn invert(&self) -> CtOption<Self>

Computes the multiplicative inverse of this element, failing if the element is zero.
Source§

fn is_zero_vartime(&self) -> bool

Returns true iff this element is zero. Read more
Source§

fn cube(&self) -> Self

Cubes this element.
Source§

fn sqrt_alt(&self) -> (Choice, Self)

Equivalent to Self::sqrt_ratio(self, one()). Read more
Source§

fn pow<S>(&self, exp: S) -> Self
where S: AsRef<[u64]>,

Exponentiates self by exp, where exp is a little-endian order integer exponent. Read more
Source§

fn pow_vartime<S>(&self, exp: S) -> Self
where S: AsRef<[u64]>,

Exponentiates self by exp, where exp is a little-endian order integer exponent. Read more
Source§

impl<F: PartialEq + Field> PartialEq for QuadExtField<F>

Source§

fn eq(&self, other: &QuadExtField<F>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<F> Serialize for QuadExtField<F>
where F: Serialize + Field,

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<F: Copy + Field> Copy for QuadExtField<F>

Source§

impl<F: Eq + Field> Eq for QuadExtField<F>

Source§

impl<F: Field> StructuralPartialEq for QuadExtField<F>