Type Definition ark_r1cs_std::fields::fp12::Fp12Var
source · pub type Fp12Var<P> = QuadExtVar<Fp6Var<<P as Fp12Config>::Fp6Config>, Fp12ConfigWrapper<P>>;
Expand description
A degree-12 extension field constructed as the tower of a
quadratic extension over a cubic extension over a quadratic extension field.
This is the R1CS equivalent of ark_ff::fp12_2over3over2::Fp12<P>
.
Implementations§
source§impl<P: Fp12Config> Fp12Var<P>
impl<P: Fp12Config> Fp12Var<P>
sourcepub fn mul_by_014(
&self,
c0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
c1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>
) -> Result<Self, SynthesisError>
pub fn mul_by_014(
&self,
c0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
c1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>
) -> Result<Self, SynthesisError>
Multiplies by a sparse element of the form (c0 = (c0, c1, 0), c1 = (0, d1, 0))
.
sourcepub fn mul_by_034(
&self,
c0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>
) -> Result<Self, SynthesisError>
pub fn mul_by_034(
&self,
c0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d0: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>,
d1: &Fp2Var<<<P as Fp12Config>::Fp6Config as Fp6Config>::Fp2Config>
) -> Result<Self, SynthesisError>
Multiplies by a sparse element of the form (c0 = (c0, 0, 0), c1 = (d0, d1, 0))
.
sourcepub fn cyclotomic_square(&self) -> Result<Self, SynthesisError>
pub fn cyclotomic_square(&self) -> Result<Self, SynthesisError>
Squares self
when self
is in the cyclotomic subgroup.
sourcepub fn optimized_cyclotomic_exp(
&self,
exponent: impl AsRef<[u64]>
) -> Result<Self, SynthesisError>
pub fn optimized_cyclotomic_exp(
&self,
exponent: impl AsRef<[u64]>
) -> Result<Self, SynthesisError>
Like Self::cyclotomic_exp
, but additionally uses cyclotomic squaring.