Trait snarkvm_fields::SquareRootField [−][src]
pub trait SquareRootField: Field { fn legendre(&self) -> LegendreSymbol; #[must_use] fn sqrt(&self) -> Option<Self>; fn sqrt_in_place(&mut self) -> Option<&mut Self>; }
Expand description
The interface for a field that supports an efficient square-root operation.
Required methods
fn legendre(&self) -> LegendreSymbol
[src]
fn legendre(&self) -> LegendreSymbol
[src]Returns the Legendre symbol.
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]Sets self
to be the square root of self
, if it exists.
Implementors
impl<'a, P: Fp2Parameters> SquareRootField for Fp2<P> where
P::Fp: SquareRootField,
[src]
impl<'a, P: Fp2Parameters> SquareRootField for Fp2<P> where
P::Fp: SquareRootField,
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn sqrt(&self) -> Option<Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
impl<P: Fp3Parameters> SquareRootField for Fp3<P>
[src]
impl<P: Fp3Parameters> SquareRootField for Fp3<P>
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn legendre(&self) -> LegendreSymbol
[src]Returns the Legendre symbol.
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]Sets self
to be the square root of self
, if it exists.
impl<P: Fp256Parameters> SquareRootField for Fp256<P>
[src]
impl<P: Fp256Parameters> SquareRootField for Fp256<P>
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn sqrt(&self) -> Option<Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
impl<P: Fp320Parameters> SquareRootField for Fp320<P>
[src]
impl<P: Fp320Parameters> SquareRootField for Fp320<P>
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn sqrt(&self) -> Option<Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
impl<P: Fp384Parameters> SquareRootField for Fp384<P>
[src]
impl<P: Fp384Parameters> SquareRootField for Fp384<P>
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn sqrt(&self) -> Option<Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
impl<P: Fp768Parameters> SquareRootField for Fp768<P>
[src]
impl<P: Fp768Parameters> SquareRootField for Fp768<P>
[src]fn legendre(&self) -> LegendreSymbol
[src]
fn sqrt(&self) -> Option<Self>
[src]
fn sqrt_in_place(&mut self) -> Option<&mut Self>
[src]
impl<P: Fp832Parameters> SquareRootField for Fp832<P>
[src]
impl<P: Fp832Parameters> SquareRootField for Fp832<P>
[src]